Replace ternary for selecting next player with more generic logic.
Move rest of canvas aware logic into the renderer.
Refactor names for clarity.
Add documentation for all functions and properties.