projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
replaced compile time with source date (optionally from SOURCE_DATE_EPOCH)
[rocksndiamonds.git]
/
src
/
screens.c
diff --git
a/src/screens.c
b/src/screens.c
index 6ece1110727fd797d8743884607b9a33c298c6d7..a2f63bcdb852779816a4ed9869e4029f25a18b3c 100644
(file)
--- a/
src/screens.c
+++ b/
src/screens.c
@@
-1408,7
+1408,7
@@
void DrawMainMenu()
/* do not fade out here -- function may continue and fade on editor screen */
UnmapAllGadgets();
/* do not fade out here -- function may continue and fade on editor screen */
UnmapAllGadgets();
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
ExpireSoundLoops(FALSE);
ExpireSoundLoops(FALSE);
@@
-1452,8
+1452,6
@@
void DrawMainMenu()
if (CheckTitleScreen(levelset_has_changed))
{
if (CheckTitleScreen(levelset_has_changed))
{
- game_status_last_screen = GAME_MODE_MAIN;
-
SetGameStatus(GAME_MODE_TITLE);
DrawTitleScreen();
SetGameStatus(GAME_MODE_TITLE);
DrawTitleScreen();
@@
-1506,8
+1504,7
@@
void DrawMainMenu()
LoadTape(level_nr);
DrawCompleteVideoDisplay();
LoadTape(level_nr);
DrawCompleteVideoDisplay();
- PlayMenuSound();
- PlayMenuMusic();
+ PlayMenuSoundsAndMusic();
/* create gadgets for main menu screen */
FreeScreenGadgets();
/* create gadgets for main menu screen */
FreeScreenGadgets();
@@
-1602,12
+1599,15
@@
void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
/* switch game mode from title screen mode back to info screen mode */
SetGameStatus(GAME_MODE_INFO);
/* switch game mode from title screen mode back to info screen mode */
SetGameStatus(GAME_MODE_INFO);
+ /* store that last screen was info screen, not main menu screen */
+ game_status_last_screen = GAME_MODE_INFO;
+
DrawInfoScreen_NotAvailable("Title screen information:",
"No title screen for this level set.");
return;
}
DrawInfoScreen_NotAvailable("Title screen information:",
"No title screen for this level set.");
return;
}
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
}
FadeOut(REDRAW_ALL);
}
FadeOut(REDRAW_ALL);
@@
-1705,7
+1705,7
@@
void HandleTitleScreen(int mx, int my, int dx, int dy, int button)
}
else
{
}
else
{
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
return_to_main_menu = TRUE;
}
return_to_main_menu = TRUE;
}
@@
-2160,7
+2160,7
@@
static void DrawInfoScreen_Main()
fade_mask = REDRAW_ALL;
UnmapAllGadgets();
fade_mask = REDRAW_ALL;
UnmapAllGadgets();
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
FreeScreenGadgets();
CreateScreenGadgets();
FreeScreenGadgets();
CreateScreenGadgets();
@@
-2199,8
+2199,7
@@
static void DrawInfoScreen_Main()
MapScreenGadgets(max_info_info);
MapScreenGadgets(max_info_info);
- PlayMenuSound();
- PlayMenuMusic();
+ PlayMenuSoundsAndMusic();
DrawMaskedBorder(fade_mask);
DrawMaskedBorder(fade_mask);
@@
-2678,8
+2677,6
@@
void DrawInfoScreen_HelpText(int element, int action, int direction, int ypos)
void DrawInfoScreen_TitleScreen()
{
void DrawInfoScreen_TitleScreen()
{
- game_status_last_screen = GAME_MODE_INFO;
-
SetGameStatus(GAME_MODE_TITLE);
DrawTitleScreen();
SetGameStatus(GAME_MODE_TITLE);
DrawTitleScreen();
@@
-2754,7
+2751,7
@@
void HandleInfoScreen_Elements(int button)
if (page >= num_pages)
{
if (page >= num_pages)
{
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-2813,7
+2810,7
@@
void HandleInfoScreen_Music(int button)
if (list == NULL)
{
if (list == NULL)
{
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
ClearField();
DrawHeadline();
ClearField();
DrawHeadline();
@@
-2832,7
+2829,7
@@
void HandleInfoScreen_Music(int button)
{
PlaySound(SND_MENU_ITEM_SELECTING);
{
PlaySound(SND_MENU_ITEM_SELECTING);
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-2853,7
+2850,7
@@
void HandleInfoScreen_Music(int button)
if (list == NULL)
{
if (list == NULL)
{
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-2861,7
+2858,7
@@
void HandleInfoScreen_Music(int button)
return;
}
return;
}
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
if (list != music_file_info)
FadeSetNextScreen();
if (list != music_file_info)
FadeSetNextScreen();
@@
-3116,7
+3113,7
@@
void DrawInfoScreen_Credits()
{
SetMainBackgroundImageIfDefined(IMG_BACKGROUND_INFO_CREDITS);
{
SetMainBackgroundImageIfDefined(IMG_BACKGROUND_INFO_CREDITS);
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
FadeOut(REDRAW_FIELD);
FadeOut(REDRAW_FIELD);
@@
-3157,7
+3154,7
@@
void HandleInfoScreen_Credits(int button)
if (screen_nr >= num_screens)
{
if (screen_nr >= num_screens)
{
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-3236,7
+3233,7
@@
void HandleInfoScreen_Program(int button)
{
PlaySound(SND_MENU_ITEM_SELECTING);
{
PlaySound(SND_MENU_ITEM_SELECTING);
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-3294,8
+3291,8
@@
void DrawInfoScreen_Version()
DrawTextF(xstart2, ystart2, font_text, TARGET_STRING);
ystart2 += ystep;
DrawTextF(xstart2, ystart2, font_text, TARGET_STRING);
ystart2 += ystep;
- DrawTextF(xstart1, ystart2, font_header, "
Compile tim
e");
- DrawTextF(xstart2, ystart2, font_text, get
Compil
eDateString());
+ DrawTextF(xstart1, ystart2, font_header, "
Source dat
e");
+ DrawTextF(xstart2, ystart2, font_text, get
Sourc
eDateString());
ystart2 += 3 * ystep;
DrawTextF(xstart1, ystart2, font_header, "Library");
ystart2 += 3 * ystep;
DrawTextF(xstart1, ystart2, font_header, "Library");
@@
-3411,7
+3408,7
@@
void HandleInfoScreen_Version(int button)
{
PlaySound(SND_MENU_ITEM_SELECTING);
{
PlaySound(SND_MENU_ITEM_SELECTING);
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-3499,7
+3496,7
@@
void HandleInfoScreen_LevelSet(int button)
{
PlaySound(SND_MENU_ITEM_SELECTING);
{
PlaySound(SND_MENU_ITEM_SELECTING);
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
info_mode = INFO_MODE_MAIN;
DrawInfoScreen();
@@
-3532,10
+3529,7
@@
static void DrawInfoScreen()
if (info_mode != INFO_MODE_MAIN &&
info_mode != INFO_MODE_TITLE &&
info_mode != INFO_MODE_MUSIC)
if (info_mode != INFO_MODE_MAIN &&
info_mode != INFO_MODE_TITLE &&
info_mode != INFO_MODE_MUSIC)
- {
- PlayMenuSound();
- PlayMenuMusic();
- }
+ PlayMenuSoundsAndMusic();
}
void HandleInfoScreen(int mx, int my, int dx, int dy, int button)
}
void HandleInfoScreen(int mx, int my, int dx, int dy, int button)
@@
-4065,12
+4059,11
@@
static void HandleChooseTree(int mx, int my, int dx, int dy, int button,
void DrawChooseLevelSet()
{
void DrawChooseLevelSet()
{
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
DrawChooseTree(&leveldir_current);
DrawChooseTree(&leveldir_current);
- PlayMenuSound();
- PlayMenuMusic();
+ PlayMenuSoundsAndMusic();
}
void HandleChooseLevelSet(int mx, int my, int dx, int dy, int button)
}
void HandleChooseLevelSet(int mx, int my, int dx, int dy, int button)
@@
-4082,7
+4075,7
@@
void DrawChooseLevelNr()
{
int i;
{
int i;
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
if (level_number != NULL)
{
if (level_number != NULL)
{
@@
-4130,8
+4123,7
@@
void DrawChooseLevelNr()
DrawChooseTree(&level_number_current);
DrawChooseTree(&level_number_current);
- PlayMenuSound();
- PlayMenuMusic();
+ PlayMenuSoundsAndMusic();
}
void HandleChooseLevelNr(int mx, int my, int dx, int dy, int button)
}
void HandleChooseLevelNr(int mx, int my, int dx, int dy, int button)
@@
-4147,7
+4139,7
@@
void DrawHallOfFame(int highlight_position)
fade_mask = REDRAW_ALL;
UnmapAllGadgets();
fade_mask = REDRAW_ALL;
UnmapAllGadgets();
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
/* (this is needed when called from GameEnd() after winning a game) */
KeyboardAutoRepeatOn();
/* (this is needed when called from GameEnd() after winning a game) */
KeyboardAutoRepeatOn();
@@
-4167,8
+4159,7
@@
void DrawHallOfFame(int highlight_position)
/* needed if different viewport properties defined for scores */
ChangeViewportPropertiesIfNeeded();
/* needed if different viewport properties defined for scores */
ChangeViewportPropertiesIfNeeded();
- PlayMenuSound();
- PlayMenuMusic();
+ PlayMenuSoundsAndMusic();
OpenDoor(GetDoorState() | DOOR_NO_DELAY | DOOR_FORCE_REDRAW);
OpenDoor(GetDoorState() | DOOR_NO_DELAY | DOOR_FORCE_REDRAW);
@@
-5782,7
+5773,7
@@
static void DrawSetupScreen_Generic()
fade_mask = REDRAW_ALL;
UnmapAllGadgets();
fade_mask = REDRAW_ALL;
UnmapAllGadgets();
- FadeSoundsAndMusic();
+ Fade
Menu
SoundsAndMusic();
FreeScreenGadgets();
CreateScreenGadgets();
FreeScreenGadgets();
CreateScreenGadgets();
@@
-6539,8
+6530,7
@@
void DrawSetupScreen()
else
DrawSetupScreen_Generic();
else
DrawSetupScreen_Generic();
- PlayMenuSound();
- PlayMenuMusic();
+ PlayMenuSoundsAndMusic();
}
void RedrawSetupScreenAfterFullscreenToggle()
}
void RedrawSetupScreenAfterFullscreenToggle()