Adds basic collision detection.