Tried to fix a problem with collision, but this still needs some work