quick optimization in collide.c