started working on collision detection