summaryrefslogtreecommitdiff
path: root/src/sound.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/sound.c')
-rw-r--r--src/sound.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/sound.c b/src/sound.c
index 10f11d4..4d574b8 100644
--- a/src/sound.c
+++ b/src/sound.c
@@ -26,18 +26,19 @@ void initSound()
if( isAudioInicialized() == FALSE )
{
isSoundInit = FALSE;
+ return;
}
listSound = newList();
isSoundInit = TRUE;
var_isSoundActive = TRUE;
- if( isParamFlag("--nomusic") )
+ if( isParamFlag("--nosound") )
{
setSoundActive(FALSE);
}
- if( isParamFlag("--music") )
+ if( isParamFlag("--sound") )
{
setSoundActive(TRUE);
}
@@ -93,6 +94,11 @@ static void destroySound(sound_t *p)
void addSound(char *file, char *name, int group)
{
+ if( isSoundInit == FALSE )
+ {
+ return;
+ }
+
addList( listSound, newSound(file, name, group) );
}