added collision detection
documentation edits