moved savelevel() code to level.h/c where it belongs to. :)
[supertux.git] / src / sound.c
index 4cca05b..8750dcd 100644 (file)
@@ -207,6 +207,25 @@ void free_music(Mix_Music *music)
     }
 }
 
+void play_current_music(void)
+{
+          switch (current_music)
+            {
+            case LEVEL_MUSIC:
+              play_music(level_song, 1);
+              break;
+            case HERRING_MUSIC:
+              play_music(herring_song, 1);
+              break;
+            case HURRYUP_MUSIC: // keep the compiler happy
+              play_music(level_song_fast, 1);
+              break;
+            case NO_MUSIC:      // keep the compiler happy for the moment :-)
+            {}
+              /*default:*/
+            }
+}
+
 #else
 
 int open_audio (int frequency, int format, int channels, int chunksize)
@@ -258,4 +277,7 @@ void free_music(void *music)
 void free_chunk(void *chunk)
 {}
 
+void play_current_music(void)
+{}
+
 #endif