Skip to content

Commit a67e41a

Browse files
committed
Play sounds when game is over
1 parent a38d270 commit a67e41a

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

dist/duckhunt.js

Lines changed: 3 additions & 1 deletion
Large diffs are not rendered by default.

src/modules/Game.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -339,10 +339,12 @@ class Game {
339339
}
340340

341341
win() {
342+
sound.play('champ');
342343
this.gameStatus = 'You Win!';
343344
}
344345

345346
loss() {
347+
sound.play('loserSound');
346348
this.gameStatus = 'You Lose!';
347349
}
348350

0 commit comments

Comments
 (0)