ID:167448
 
Code:


Problem description:

I need a good beam code, but i am pretty much a noob coder, so i need it as simple as possible. TY !
umm... This belongs in the Developer How-To forum. If you have code you wish to be fixed, that goes here. Also, very few coders here will give free code. What you'll get is an algorithm (step by step noncode procedure) for accomplishing your goal.



On topic: I guess you could do it with two icon states: one for the head of the beam and one for the tail segments. When the beam spell is cast, the head starts moving and creates a tail segment for each square it moves through. When the beam hits something, you can have a cool pyrotechnic effect, then delete all the beam elements.

Although that works, I prefer the look of a "fireball" - that beam algorithm minus the beam tail.


--Vito