collision detection part 1