summary refs log tree commit diff stats
path: root/src/character_system.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/character_system.cpp')
-rw-r--r--src/character_system.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/character_system.cpp b/src/character_system.cpp index a0572b0..d0c416e 100644 --- a/src/character_system.cpp +++ b/src/character_system.cpp
@@ -260,6 +260,13 @@ void CharacterSystem::halt(int spriteId) {
260 } 260 }
261} 261}
262 262
263void CharacterSystem::destroySprite(int spriteId) {
264 Sprite& sprite = game_.getSprite(spriteId);
265 if (sprite.runningSfxChannel != -1) {
266 stopRunningSound(sprite);
267 }
268}
269
263void CharacterSystem::clearSpriteCache() { 270void CharacterSystem::clearSpriteCache() {
264 for (Sprite& sprite : game_.getSprites() | game_.spriteView()) { 271 for (Sprite& sprite : game_.getSprites() | game_.spriteView()) {
265 if (sprite.runningSfxChannel != -1) { 272 if (sprite.runningSfxChannel != -1) {