Limit sound repetition per process frame.

This commit is contained in:
2015-12-08 21:07:50 +01:00
parent 9202e1d51a
commit bdf1e844e3
2 changed files with 24 additions and 3 deletions

View File

@@ -453,7 +453,8 @@ CandyFucker.prototype = {
[
{
Name: "Explosion",
Url: "sfx/explosion1.wav"
Url: "sfx/explosion1.wav",
Limit: 1
},
{
Name: "PickCandy",
@@ -475,6 +476,7 @@ CandyFucker.prototype = {
this.UpdateInfoDisplay();
},
Proc: function () {
window.Sounds.ResetCounters();
if (this.Locked) {
if (this.Falling) {
if (!this.Board.CandyFall()) {