Fixed repositioning of cursor when mouse leaves the window.
Greatly simplified the effects manager.

This is in preparation for the improved management (room-based) of
visual effects.
Minor code polish.