move emit of collisions to after done moving entities, so that callbacks can delete entities
removed debug code
Merge pull request #3933 from ZappoMan/entityCollisions

move emit of collisions to after done moving entities, so that callbacks can delete entities