ACCESS: Fix cmdFreeSound, which fixes the sound played during the death animation

This commit is contained in:
Strangerke 2014-12-16 19:40:27 +01:00
parent 8120cbfde3
commit 64435ef25f

View file

@ -792,9 +792,11 @@ void Scripts::cmdFreeSound() {
_vm->_events->pollEvents();
} while (!_vm->shouldQuit() && sound._playingSound);
// Free the sound
delete sound._soundTable[0]._res;
sound._soundTable.remove_at(0);
// Free the sounds
while (sound._soundTable.size() > 0) {
delete sound._soundTable[0]._res;
sound._soundTable.remove_at(0);
}
}
}