ID:261179
 
I have an attack (Beam) that is 3 Squares wide , but the problem is, I dont have a clue on how to code it in, this is where I hope a programmer that is greater than I, that knows how to do this, who could actually help me out by possibly telling or teaching me how to do it.

This might occur to SonVegitto as he has done this before on one of his games, so if you will be kind enough to help me out, would you please do so?

Or if anyone knows how to do this I would be very grateful to the person/persons who actually help me out...
Lee
What do you mean by 3 squares wide? 3 squares in each direction? in 1 direction? please be more detailed!

Alathon
In response to Alathon
What I mean is this:

When you use the "Beam"...let me see if I can do an example:

{{{{{{{{{
P{{{{{{{{{
{{{{{{{{{



P = player

{ = beam

Is this a better explanation?
In response to Evil_SSJ4Vegeta
Evil_SSJ4Vegeta wrote:
Is this a better explanation?

More or less. You can do this a lot of ways. One, you can create the icon as a bmp, in another program, and enlarge it to that size. Then just have the icon of the object to that. That's probably the most simple thing to do for something like that unless u want it splitting in 24 or however many beams there were.

Alathon
In response to Alathon
Alathon wrote:
Evil_SSJ4Vegeta wrote:
Is this a better explanation?

More or less. You can do this a lot of ways. One, you can create the icon as a bmp, in another program, and enlarge it to that size. Then just have the icon of the object to that. That's probably the most simple thing to do for something like that unless u want it splitting in 24 or however many beams there were.

Actually, an object set to a bitmap, as you might be able to reveal in the mapper, is just a bunch of objects side-by-side.

If you were to make a mob with a bitmap icon, each portion of that mob would walk off independently unless you coded it to work together.
In response to Spuzzum
Spuzzum wrote:
Alathon wrote:
Evil_SSJ4Vegeta wrote:
Is this a better explanation?

More or less. You can do this a lot of ways. One, you can create the icon as a bmp, in another program, and enlarge it to that size. Then just have the icon of the object to that. That's probably the most simple thing to do for something like that unless u want it splitting in 24 or however many beams there were.

Actually, an object set to a bitmap, as you might be able to reveal in the mapper, is just a bunch of objects side-by-side.

If you were to make a mob with a bitmap icon, each portion of that mob would walk off independently unless you coded it to work together.


But "How" could I do this?

This is what I need to know how to do, if you could teach or even send me the code to do this to my email adress then I would be very grateful, so would this be possible?

My email is: [email protected]

To contact me using an IM:

Lebaria = my AIM screen name
[email protected] = My MSN contact
107458747 = My ICQ#
In response to Evil_SSJ4Vegeta
Come on guys, I really really need help with this one, so if you would be kind enough to help me please do so, as I dont know "how" to code the "beam" into the game, that is why I posted this topic because you answer all the questions possible, so pease help me.
In response to Evil_SSJ4Vegeta
Evil_SSJ4Vegeta wrote:
Come on guys, I really really need help with this one, so if you would be kind enough to help me please do so, as I dont know "how" to code the "beam" into the game, that is why I posted this topic because you answer all the questions possible, so pease help me.

As far as I can see, you'll have your best success by creating a loop in which new beam objects or images are added. Starting with get_step(src,dir), create a beam object in that square, and do the same for get_step(src,turn(dir,45)) and get_step(src,turn(dir,-45)). Now from each of those three, move forward using get_step(object,dir) and keep going for each, creating new objects all the while, until you hit an obstacle. To detect an obstacle, I suggest something like turf.Enter().

Now of course my suggestion treats the beams basically as 3 separate beams, not a single beam that will completely stop when any part of it hits a target. It may also be desirable for only the center part of the beam to stop when it hits a target, while the outer edges may do less damage to any targets in their path but not actually stop the beam. Or, you may want the beam to stop when any part of it hits an obstacle.

You may also want to consider making different icon states, each state being a movie that can have different directions, to correspond to whether a part of the beam is in the middle or at an edge, if it's at the firing point or hits an obstacle. Graphically you could make this look quite impressive, even animating the beam.

That's probably as detailed an answer as you're going to get. Aside from the fact that you haven't fully articulated what you want, there are few people willing to write code for you, especially when it's only going to be pasted into a DBZ game.

Lummox JR
In response to Lummox JR
Ok...point taken... :(
In response to Spuzzum
Spuzzum wrote:

Actually, an object set to a bitmap, as you might be able to reveal in the mapper, is just a bunch of objects side-by-side.

If you were to make a mob with a bitmap icon, each portion of that mob would walk off independently unless you coded it to work together.

Good point, evaded my mind at the point although I knew this (due to accidentally getting part of my login screen with a char, heh)

Alathon
In response to Alathon
If I actually had the code done would it look alittle like this:


var/x1 =usr.x+1
var/x2 =usr.x+2
mob/verb/Beam()
new/obj/beam(x1,x2,usr.z)

If "No" could someone at least correct me to the right path?
In response to Evil_SSJ4Vegeta
No.

Lummox Jr. Already pointed you in the right direction. If you don't understand the things he mentioned, look them up in the reference.
In response to Shadowdarke
Shadowdarke wrote:
No.

Lummox Jr. Already pointed you in the right direction. If you don't understand the things he mentioned, look them up in the reference.


That was my fault I was trying to explain it through AIM and it kinda got twisted in it.
In response to Shadowdarke
Shadowdarke wrote:
Lummox Jr. Already pointed you in the right direction. If you don't understand the things he mentioned, look them up in the reference.

*coughJRcough*
In response to Lummox JR
Lummox JR wrote:
Shadowdarke wrote:
Lummox Jr. Already pointed you in the right direction. If you don't understand the things he mentioned, look them up in the reference.

*coughJRcough*

Ooops... for some reason I thought of you as a younger Lummox ;)
In response to Shadowdarke
:(

I should have posted this in the "Newbie Central", at least I would have gotten a better answer, and an easier explanation from you lot, and it seems to me you dont want to help me anyway because it is a DBZ game, so as far as this goes, your only doing this because you either hate "me" or my "game" simple enough eh?

Well, I might aswell ask somewhere else then...coz you lot ait helping much :(
In response to Evil_SSJ4Vegeta
Evil_SSJ4Vegeta wrote:
:(

I should have posted this in the "Newbie Central", at least I would have gotten a better answer, and an easier explanation from you lot, and it seems to me you dont want to help me anyway because it is a DBZ game, so as far as this goes, your only doing this because you either hate "me" or my "game" simple enough eh?

Well, I might aswell ask somewhere else then...coz you lot ait helping much :(

What kinda ungreatful person are you? Christ. No one here has nagged on you because you've made a DBZ game, infact several people have tried to point you in the right direction yet you refuse to take the help, or acknowledge that you wont get a code snippet.

Alathon
In response to Alathon
Alathon wrote:
Evil_SSJ4Vegeta wrote:
:(

I should have posted this in the "Newbie Central", at least I would have gotten a better answer, and an easier explanation from you lot, and it seems to me you dont want to help me anyway because it is a DBZ game, so as far as this goes, your only doing this because you either hate "me" or my "game" simple enough eh?

Well, I might aswell ask somewhere else then...coz you lot ait helping much :(

What kinda ungreatful person are you? Christ. No one here has nagged on you because you've made a DBZ game, infact several people have tried to point you in the right direction yet you refuse to take the help, or acknowledge that you wont get a code snippet.

Alathon



I'm sorry Alathon its just I dont understand what JR and the rest of you mean by what you have said, its confusing, look I'm sorry for what I said, I just need the explanation of what JR said in more of an easier way to understand as I'm not as good a coder as anyone here, and I dont understand everything yet, so if it would be possible could you explain what JR said in a more "Less Intelligent Persons" way please?
In response to Evil_SSJ4Vegeta
Well, it depends on what you want as well. Do you want it as one big beam, or lots of small beams?

Alathon
In response to Alathon
Alathon wrote:
Well, it depends on what you want as well. Do you want it as one big beam, or lots of small beams?

Alathon


I would like it as one "Whole" Beam, I have 3 icons which is for the beam, two corners and a center, all form the beginning, then the center will make the rest of the beam:

IE,

[{{{{{
P{{{{{{
[{{{{{


P = player
[ = corners of beam
{ = center icon of beam

(Is this easy enough to understand?)
Page: 1 2 3