I’ve been trying to implement a very simple 2D top-down jumping mechanic, similar to the top down zelda games.
I’ve implemented objects that can be jumped over, by turning off collisions for specific layers when the
Jump event starts:
Physics2D.IgnoreLayerCollision(PlayerLayer, ObjectsLayer, True)
The problem I’m having is that when I re-enable the layer collision, collision events don’t fire until the PlayerObject moves. Which means that the player will safely land in a spike pit, but get hurt when they try to move out of it.
Is there any way I can force it to poll for collisions at a certain point? Or would it be better to handle collisions differently, seperate from the Unity physics engine?
I’m not very familliar with Unity, so I’d appriciate any help at all.