Worked a bit more on collision

Did not do as much as I hoped because I spent most of the time trying to
solve an annoying bug.