Stencyl 3.4.0 is now out. Get it now!

Maths Help, Please

JeffreyDriver

  • Posts: 759
Hi,

There's a couple of effects I'm struggling to achieve with the Image API. One is an explosion particle effect, and the other is a contrail effect. I could do this easily with actors, but obviously with images there's not the same blocks.

For the explosion, I'm trying to get them to spread out from a central point, with the contrails I'm trying to make them always draw from the tips of the wings of the planes.

See the image for an explanation.

Your help is gratefully received! Thanks
Current Project - www.stencyl.com/game/play/36346 (Retro Redux Dogfight).
I always appreciate useful feedback. Thank you.

www.jeffreydriver.co.uk

squeeb

  • Posts: 715
how are you doing the code for the contrail?  Can you do something like set pixel color at x, y of plane actor?  ive done something like that before but trying to see collisions with image api

JeffreyDriver

  • Posts: 759
Not too well is the short answer! Drawing at the XY value of the plane actor doesn't seem to take account of the actor rotation. So it doesn't rotate with the actor.  Am I missing something obvious?

EDIT: Is there another way around this? Could I attach an actor to the tips of the wings that would then rotate correctly, and spawn the contrails from them, rather than the plane directly?

« Last Edit: April 21, 2017, 03:53:58 pm by JeffreyDriver »
Current Project - www.stencyl.com/game/play/36346 (Retro Redux Dogfight).
I always appreciate useful feedback. Thank you.

www.jeffreydriver.co.uk

squeeb

  • Posts: 715
Ohh.. hmmm.. that may work... update the actor to stay at x and y of plane actor.. create contrails at those actors on the wing