I have the typical set up of player collision with enemy while on floor kills/shrinks player, and player collision with enemy while falling kills enemy. I have now added “jump through platforms” that have enemies on them, and when jumping up/through the platform if an enemy is in the way…the player jumps right through them.
Is there a way for the enemy to die only if the collision happens when the player is coming down, and not moving up? I have tried the “OldY” trick, but then that kills the player when colliding with enemy from above.
This is my code that works great (until you add jump through platforms):