mintleaf/splatpong — pull request #3 by ericlathrop (2014-05-02 04:43:11+00:00)
Title: Remove globals

This converts all the global game variables (players, ball, scores, etc.) into variables on the scene object. This is a good practice because it makes a scene restartable. That is, when you switch back to a scene, everything is initialized in the init function, and starts exactly the same each time.