Fixed collision handling

Fixes #9

Issue 9 fixed by chaning side detection to a line-line intersection
test. It might be necesearry to add test to find closes coliding tile
and maybe add more line-line intersection tests. Additional code cleanup
is also neded.

The issue might be reopened, but according to preliminary test, it works
OK
Improved compile-time by cleaning includes in header files
Added header and put 'make' in a if statement