[SOLVED]Particles don't spawn where you want; but MOVE there

This forum is currently in read-only mode.
From the Asset Store
Tap the ball, control it, avoid touching spikes and score higher!
  • [Solved] The first part was a bug which is being posted to the tracker. The second part was a problem with events which has been solved in chat.

    I was creating a simple magic attack test for my game and ran across a problem with the particles that move with a circle hitbox (invisible). The particles don't spawn from the player object like I tell them to. They spawn where the particles object was originally placed (destroyed on start) then move extremely quickly to the player's position. I tested it with a second instance of the particles object (also destroyed on start) but it seems to only move from the original instance. The problem with all of this is that some particles can be seen along the super quick movement path of the particles!

    I tested all of this out in an example .cap file which I'll upload and link to in an edit.

    Edit:

    Sneaking in another problem edit: I have another problem. Each magic attack's hitbox (which is the moving object with the particles being set to their locations) is supposed to have its own particles instance. Right now I'm using containers so that when a magic orb hits an enemy, the right particles object instance gets destroyed with the hitbox. The problem is that particles in the air disappear instantly when the particles object and hitbox object are destroyed simultaneously. It looks extremely weird. There must be a better way to do this so that the particles in the air get to fade out normally instead of being removed instantly.

    Addition to the above: It would help SO much if I could choose to pair up the right instances of particles (for ALL further events, not just those with the event each one was created in) without using Containers because Container destroys all objects when one is destroyed.

    Another addition: What I'm trying to do with pairing is this- When a magic attack is performed, an invisible circle-shaped hitbox with the bullet behavior is spawned from the player. Also spawned is a particles object which is the visible part of the magic attack. The particles should be set to the position of the proper hitbox each tick. Then, when the hitbox collides with an enemy, the hitbox is destroyed BUT the particles object is set to Spray not Enabled. Finally, after a timer (long enough so that particles already in the air are gone), the particles object is destroyed.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)