rotation fixed

rotation fixed -- now detects collisions after a rotation and prevents
the rotation if collision would occur after rotation