Added additional collision checks and prevented infinite loop of collision on player.