diff --git a/21g30t1e75.js b/21g30t1e75.js index 9a1b4f6..4d52ef6 100644 --- a/21g30t1e75.js +++ b/21g30t1e75.js @@ -913,14 +913,30 @@ GameLib.CustomCode.prototype.createFood = function(delta) { GameLib.CustomCode.prototype.gameOver = function(won) { this.state.gameOver = true; - + if (won) { + + GameLib.Event.Emit( + GameLib.Event.PLAY_AUDIO, + { + name : 'Audio - Game Over Won' + } + ); + this.state.message = { text: "YOU WON!", x: 152, y: 256 }; } else { + + GameLib.Event.Emit( + GameLib.Event.PLAY_AUDIO, + { + name : 'Audio - Game Over Lost' + } + ); + this.state.message = { text: "GAME OVER", x: 127,