trouble with destroying enemies with particle trails

0 favourites
  • 6 posts
From the Asset Store
Particles support animations, collisions, effects and etc.
  • Hi there,

    So I have this game where i'm spawning enemies that are basically bullets with a smoke particle trailing behind

    http://part12studios.com/temp/Games/SMoD/SMoD_05/

    but here's the thing.. i have a fade on the particles.. so when the enemy hits the player.. i can do anything i want with the bullet object (asteroid) but basically when i say "fade" all of the particles in the scene fade

    particles are troublesome too because they don't have collision.. i can't say "on collide" otherwise it would be no problem..

    so i think that's the main question.. any ideas on how i could manage particles individually.. ones that are partnered to multiple enemy bullet objects.

    Any insight would be helpful. I'm sure there is something elegant i'm missing out that's obvious.. but my brain's getting fried at this point..

    Thanks!

    Caleb

  • Try a Container, or just give the particles an instance variable set to the bullet.UID, then when the bullet is destroyed, pick all particles with that same stored UID, and destroy them.

  • i agree with Try the container thing and when the bullet is destroyed then destroy the particle that hitted the with bullet.

  • oh containter! omg, i forgot about those.. i was trying families.. and sprites / particles can't group in families.. thanks i'll try that!

  • The problem with containers and particles is that when the particle object is destroyed along with its parent object, so are all of its emissions.

    Making the Particle object one-shot has issues as well.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • thanks for the tip newt! i'll keep an eye out for that. maybe on destroy, spawn another particle effect to create the illusions..

    one thing i still notice is that they don't have a random rotation option.. i really need to put in a request for that.. so when the objects appear they are not all the same orientation.. looks more organic if each spawns randomly 0-359 degrees.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)