audio, etc

This commit is contained in:
PolicyChanges1@gmail.com 2021-02-09 22:33:25 -05:00
parent 9d793a45ca
commit 3a90d633e3
3 changed files with 4 additions and 0 deletions

BIN
dist/Tetris.ogg vendored Normal file

Binary file not shown.

2
dist/tetrion.js vendored
View File

@ -1055,6 +1055,8 @@ Tetris.prototype = {
_check: function() {
var rows = checkFullRows(this.matrix);
if (rows.length) {
if(rows.length >= 4)
new Audio('./dist/Tetris.ogg').play();
removeRows(this.matrix, rows);
var score = calcScore(rows);
var reward = calcRewards(rows);

View File

@ -463,6 +463,8 @@ Tetris.prototype = {
_check: function() {
var rows = checkFullRows(this.matrix);
if (rows.length) {
if(rows.length >= 4)
new Audio('./dist/Tetris.ogg').play();
removeRows(this.matrix, rows);
var score = calcScore(rows);
var reward = calcRewards(rows);