From daa0b9a49705c00a72b3b585ef859d4c65a330ca Mon Sep 17 00:00:00 2001 From: Eugenio Favalli Date: Mon, 11 Apr 2005 13:05:29 +0000 Subject: Temp: avoid playing sample when sound is disabled --- src/game.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/game.cpp b/src/game.cpp index 30eb5f29..4ec83d5d 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -533,10 +533,12 @@ void do_input() player_node->direction); player_node->walk_time = tick_time; - ResourceManager *resman = ResourceManager::getInstance(); - SoundEffect *sample = resman->getSoundEffect( - "sfx/fist-swish.ogg"); - sample->play(0, 120); + if (config.getValue("sound", 0) == 1) { // Temp fix + ResourceManager *resman = ResourceManager::getInstance(); + SoundEffect *sample = resman->getSoundEffect( + "sfx/fist-swish.ogg"); + sample->play(0, 120); + } } } -- cgit v1.2.3-70-g09d2