Fixes collision detection.
Merge pull request #5 from hybridgroup/collision-detection

Fixes collision detection.