B
Benattaous
Guest
Hey Hey! New programmer here! I'm making a reskinned version of the Space Rocks Tutorial project, and am currently working on a short invulnerability state for the player after respawn. I'm doing this by respawning a "ghost" object of the player that is only capable of moving, before transforming to the full player object after a few seconds, just in case there happened to be an asteroid on the respawn spot - which would cause an immediate game over regardless of life count.
The problem is; Whenever the "ghost" transforms into the full player object, the momentum and direction of the player is completely reset! It's extremely jarring, and can sometimes lead to an unfair death, so here's my question - How do I get it so that when the "ghost" object is destroyed and replaced by the full player object, the player object maintains the same speed and direction as the "ghost" when it was destroyed?
The problem is; Whenever the "ghost" transforms into the full player object, the momentum and direction of the player is completely reset! It's extremely jarring, and can sometimes lead to an unfair death, so here's my question - How do I get it so that when the "ghost" object is destroyed and replaced by the full player object, the player object maintains the same speed and direction as the "ghost" when it was destroyed?