Changed some of the collision functions