spinend sound

This commit is contained in:
2026-03-27 08:29:13 +01:00
parent 06100377c9
commit cf2420d544
2 changed files with 3 additions and 2 deletions

View File

@@ -306,6 +306,7 @@
<audio id="move" src="snd/move.ogg" preload="auto" type="audio/ogg"></audio> <audio id="move" src="snd/move.ogg" preload="auto" type="audio/ogg"></audio>
<audio id="rotate" src="snd/rotate.ogg" preload="auto" type="audio/ogg"></audio> <audio id="rotate" src="snd/rotate.ogg" preload="auto" type="audio/ogg"></audio>
<audio id="spin" src="snd/spin.ogg" preload="auto" type="audio/ogg"></audio> <audio id="spin" src="snd/spin.ogg" preload="auto" type="audio/ogg"></audio>
<audio id="spinend" src="snd/spinend.mp3" preload="auto" type="audio/ogg"></audio>
</span> </span>
<script src="js/game_logic.js" language="Javascript" type="text/javascript"></script> <script src="js/game_logic.js" language="Javascript" type="text/javascript"></script>

View File

@@ -131,9 +131,9 @@ let playerActions = {
moveRight: () => matrix.piece.move(TRANSLATION.RIGHT)? playSound(move) : playSound(hit), moveRight: () => matrix.piece.move(TRANSLATION.RIGHT)? playSound(move) : playSound(hit),
rotateClockwise: () => matrix.piece.rotate(ROTATION.CW)? playSound(rotate) : playSound(hit), rotateClockwise: () => matrix.piece.rotate(ROTATION.CW)? playSound(rotate) : playSound(spinend),
rotateCounterclockwise: () => matrix.piece.rotate(ROTATION.CCW)? playSound(rotate) : playSound(hit), rotateCounterclockwise: () => matrix.piece.rotate(ROTATION.CCW)? playSound(rotate) : playSound(spinend),
softDrop: () => (matrix.piece.move(TRANSLATION.DOWN) && ++stats.score)? playSound(move) : playSound(floor), softDrop: () => (matrix.piece.move(TRANSLATION.DOWN) && ++stats.score)? playSound(move) : playSound(floor),