My destruction platformer engine - movement issues.


My problem is that pea is moving in funky ways when inside destroyed terrain. E.g. moving upwards on its own or sinking down like in quicksand. I think the problem is with my collision detection method to check when to stop pea, but I can’t think of any other that would work better. Can you help me?