Fix bug in StateManager...

... where a state's update function might not get called if it has an empty preload function.

The change is in StateManager.js. Also added node_modules to the .gitignore. I included the build files but I'm not sure I should have :( (my first GitHub pull request woohoo)