Fix collision detection
Merge pull request #457 from MDCox/release-0.3.1

Fix collision detection