Fixes a bug with collisions and drawing of objects, where only 4 possible positions were considered instead of 9