Collision detection in docks