diff --git a/21g30t1e75.js b/21g30t1e75.js index 3cdab11..d953f3b 100644 --- a/21g30t1e75.js +++ b/21g30t1e75.js @@ -1273,16 +1273,7 @@ GameLib.CustomCode.prototype.advanceSnake = function(delta) { var backup = null; var temp = null; var advanced = false; - - if (this.state.overrideOrientation) { - this.backupPreviousOrientation = this.backupOrientation; - - this.backupOrientation = this.state.orientation; - - this.state.overrideOrientation = false; - } - this.snake.map( function(body, index) { @@ -1345,6 +1336,10 @@ GameLib.CustomCode.prototype.advanceSnake = function(delta) { } else { + if (this.state.overrideOrientation) { + this.backupPreviousOrientation = this.state.orientation; + } + var gameObject = this.grid[body.position.x][body.position.y]; switch (gameObject.objectType) {