Move to a state machine

This commit is contained in:
2014-06-14 12:12:38 -07:00
parent 20446e4e20
commit f5b2ec1fc9

View File

@@ -954,9 +954,9 @@ GameState.prototype.check_input = function()
if ( controls.up.isDown) {
if ( controls.up.shiftKey ) {
newstate = (STATE_FACE_LEFT | STATE_MOVING | STATE_RUNNING);
newstate = (STATE_FACE_UP | STATE_MOVING | STATE_RUNNING);
} else {
newstate = (STATE_FACE_LEFT | STATE_MOVING );
newstate = (STATE_FACE_UP | STATE_MOVING );
}
} else if ( controls.down.isDown ) {
if ( controls.down.shiftKey ) {