X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fscreens.c;h=8499f619bda35cd748456f3241a29c4c82f5e5e5;hb=467fb3a191a20318590ac5681e21bcfefb0eb2ad;hp=a04d75dc3e6b204e7538d9c384ccd323ea8a62fe;hpb=b81f28710057e7d84528b65b92e9b4d1aaadab6c;p=rocksndiamonds.git diff --git a/src/screens.c b/src/screens.c index a04d75dc..8499f619 100644 --- a/src/screens.c +++ b/src/screens.c @@ -1,7 +1,7 @@ /*********************************************************** * Rocks'n'Diamonds -- McDuffin Strikes Back! * *----------------------------------------------------------* -* (c) 1995-2001 Artsoft Entertainment * +* (c) 1995-2002 Artsoft Entertainment * * Holger Schemel * * Detmolder Strasse 189 * * 33604 Bielefeld * @@ -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;iname; - 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->identifier; + setup.sounds_set = artwork.snd_current->identifier; + setup.music_set = artwork.mus_current->identifier; + + /* needed for displaying artwork name instead of artwork identifier */ + graphics_set_name = artwork.gfx_current->name; + sounds_set_name = artwork.snd_current->name; + music_set_name = artwork.mus_current->name; + setup_mode = SETUP_MODE_ARTWORK; DrawSetupScreen(); } @@ -1489,11 +1506,11 @@ static struct TokenInfo setup_info_sound[] = static struct TokenInfo setup_info_artwork[] = { { TYPE_ENTER_MENU, execSetupChooseGraphics,"Custom Graphics" }, - { TYPE_STRING, &setup.graphics_set, "" }, + { TYPE_STRING, &graphics_set_name, "" }, { TYPE_ENTER_MENU, execSetupChooseSounds, "Custom Sounds" }, - { TYPE_STRING, &setup.sounds_set, "" }, + { TYPE_STRING, &sounds_set_name, "" }, { TYPE_ENTER_MENU, execSetupChooseMusic, "Custom Music" }, - { TYPE_STRING, &setup.music_set, "" }, + { TYPE_STRING, &music_set_name, "" }, { TYPE_EMPTY, NULL, "" }, { TYPE_STRING, NULL, "Override Level Artwork:"}, { TYPE_YES_NO, &setup.override_level_graphics, "Graphics:" }, @@ -1661,7 +1678,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) { @@ -2089,7 +2106,7 @@ void CustomizeKeyboard(int player_nr) { case EVENT_KEYPRESS: { - Key key = GetEventKey((KeyEvent *)&event, TRUE); + Key key = GetEventKey((KeyEvent *)&event, FALSE); if (key == KSYM_Escape || (key == KSYM_Return && step_nr == 6)) {