I have a feature i am working on in my game where the enemy is destroyed, and a coin shoots out and homes in on the player for auto collection.
the problem is, I am using a dummy sprite on a bullet behaviour to rotate to the player object at a rapid speed of 400.
each enemy, before it is set to destroy, creates a dummy sprite with the bullet behaviour, then immediately after a coin sprite is spawned that takes the UID of that dummy and stores it as a private variable. and the matching coin variable is used to pair the coin with the dummy..
which I believe is the correct way of doing things..right?
problem is, a singular destroyed enemy is fine and works as it should, but if i destroy enemies in rapid succession, the parent dummies are moving as they should to the player, but are leaving some (not all) of the paired coin sprites behind...
I'm using:
(event)
Always
coin value = to dummy UID
(action)
coin sprite set x to dummy .x
coin sprite set y to dummy .y
can anyone help?