rnd-20020629-1-src
[rocksndiamonds.git] / src / screens.c
index a04d75dc3e6b204e7538d9c384ccd323ea8a62fe..a09d3ec02c73c4fcb2535b3ed4855d5966034bc8 100644 (file)
@@ -155,7 +155,7 @@ void DrawMainMenu()
   /* needed if last screen was the setup screen and fullscreen state changed */
   ToggleFullscreenIfNeeded();
 
-  /* needed if last screen (setup/level) changed graphics, sounds or music */
+  /* needed if last screen (level choice) changed graphics, sounds or music */
   ReloadCustomArtwork();
 
 #ifdef TARGET_SDL
@@ -837,8 +837,8 @@ void HandleHelpScreen(int button)
       for(i=0;i<MAX_HELPSCREEN_ELS;i++)
        helpscreen_step[i] = helpscreen_frame[i] = helpscreen_delay[i] = 0;
       helpscreen_state++;
-      DrawHelpScreenElText(helpscreen_state*MAX_HELPSCREEN_ELS);
-      DrawHelpScreenElAction(helpscreen_state*MAX_HELPSCREEN_ELS);
+      DrawHelpScreenElText(helpscreen_state * MAX_HELPSCREEN_ELS);
+      DrawHelpScreenElAction(helpscreen_state * MAX_HELPSCREEN_ELS);
     }
     else if (helpscreen_state <
             num_helpscreen_els_pages + num_helpscreen_music - 1)
@@ -869,9 +869,15 @@ void HandleHelpScreen(int button)
   {
     if (DelayReached(&hs_delay,GAME_FRAME_DELAY * 2))
     {
-      if (helpscreen_state<num_helpscreen_els_pages)
+      if (helpscreen_state < num_helpscreen_els_pages)
        DrawHelpScreenElAction(helpscreen_state*MAX_HELPSCREEN_ELS);
     }
+
+    /* !!! workaround for playing "music" that is really a sound loop (and
+       must therefore periodically be reactivated with the current sound
+       engine !!! */
+    PlaySoundLoop(SND_MENU_INFO_SCREEN);
+
     DoAnimation();
   }
 
@@ -1370,23 +1376,25 @@ static void execSetupGame()
 
 static void execSetupGraphics()
 {
-  setup.graphics_set = artwork.gfx_current->name;
-
   setup_mode = SETUP_MODE_GRAPHICS;
   DrawSetupScreen();
 }
 
 static void execSetupSound()
 {
-  setup.sounds_set = artwork.snd_current->name;
-  setup.music_set = artwork.mus_current->name;
-
   setup_mode = SETUP_MODE_SOUND;
   DrawSetupScreen();
 }
 
 static void execSetupArtwork()
 {
+  /* needed if last screen (setup choice) changed graphics, sounds or music */
+  ReloadCustomArtwork();
+
+  setup.graphics_set = artwork.gfx_current->name;
+  setup.sounds_set = artwork.snd_current->name;
+  setup.music_set = artwork.mus_current->name;
+
   setup_mode = SETUP_MODE_ARTWORK;
   DrawSetupScreen();
 }
@@ -1661,7 +1669,7 @@ static void DrawSetupScreen_Generic()
   else if (setup_mode == SETUP_MODE_ARTWORK)
   {
     setup_info = setup_info_artwork;
-    title_string = "Setup Sound";
+    title_string = "Custom Artwork";
   }
   else if (setup_mode == SETUP_MODE_SHORTCUT)
   {