Creates a new Canvas manager.
The game canvas element.
The effects canvas element.
The main game world HTML canvas element.
The 2D rendering context for the main canvas.
The overlay HTML canvas element for temporary visual effects (fog, etc.).
The height of the drawing area in CSS pixels.
Current zoom/scaling factor applied to the context. Used for window resizing.
The width of the drawing area in CSS pixels.
Clears all visual effects from the overlay canvas.
Zoom into the canvas.
The scale factor.
Update sizes of canvas and map for window.onresize.
Shakes the canvas visually using CSS animation.
Manages the game canvas and rendering loop.