Game settings Quit menu now delegates to F10 quit; bug #462
git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3174 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
Changes towards version 0.7:
|
||||
- Game settings Quit menu now delegates to F10 quit (bug #462) - Alex
|
||||
- Do not pause the game in places where not relevant (bug #984) - Alex
|
||||
- Fixed crashes and potential weirdness when loading savegames from
|
||||
a Homeworld encounter screen (bug #997) - Alex
|
||||
|
||||
@@ -1862,14 +1862,6 @@ Yes
|
||||
No
|
||||
|
||||
|
||||
#(Don't Quit)
|
||||
Don't Quit
|
||||
|
||||
|
||||
#(Quit Game)
|
||||
Quit Game
|
||||
|
||||
|
||||
#(Cr)
|
||||
Cr
|
||||
|
||||
@@ -2178,14 +2170,6 @@ exit menu
|
||||
|
||||
|
||||
|
||||
#(no, play!)
|
||||
no, play!
|
||||
|
||||
|
||||
#(yes, quit!)
|
||||
yes, quit!
|
||||
|
||||
|
||||
#(scan)
|
||||
scan
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 1.8 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.3 KiB |
@@ -37,8 +37,6 @@ playmenu-034.png 0 0 0 10
|
||||
playmenu-035.png 0 0 0 10
|
||||
playmenu-036.png 0 0 0 10
|
||||
playmenu-037.png 0 0 1 10
|
||||
playmenu-065.png 0 0 1 10
|
||||
playmenu-066.png 0 0 1 10
|
||||
playmenu-058.png 0 0 -1 -12
|
||||
playmenu-059.png 0 0 -138 -93
|
||||
playmenu-060.png 0 0 0 0
|
||||
|
||||
@@ -123,12 +123,6 @@ enum
|
||||
EXIT_MENU_SETTING
|
||||
};
|
||||
|
||||
enum
|
||||
{
|
||||
NO_QUIT_MENU,
|
||||
YES_QUIT_MENU
|
||||
};
|
||||
|
||||
static void
|
||||
FeedbackSetting (BYTE which_setting)
|
||||
{
|
||||
@@ -190,26 +184,6 @@ FeedbackSetting (BYTE which_setting)
|
||||
UnlockMutex (GraphicsLock);
|
||||
}
|
||||
|
||||
static void
|
||||
FeedbackQuit (BYTE which_setting)
|
||||
{
|
||||
const UNICODE *buf = "";
|
||||
|
||||
switch (which_setting)
|
||||
{
|
||||
case NO_QUIT_MENU:
|
||||
buf = GAME_STRING (QUITMENU_STRING_BASE + 3); // "Don't Quit"
|
||||
break;
|
||||
case YES_QUIT_MENU:
|
||||
buf = GAME_STRING (QUITMENU_STRING_BASE + 4); // "Quit Game"
|
||||
break;
|
||||
}
|
||||
|
||||
LockMutex (GraphicsLock);
|
||||
DrawStatusMessage (buf);
|
||||
UnlockMutex (GraphicsLock);
|
||||
}
|
||||
|
||||
#define DDSHS_NORMAL 0
|
||||
#define DDSHS_EDIT 1
|
||||
#define DDSHS_BLOCKCUR 2
|
||||
@@ -499,52 +473,6 @@ DoSettings (MENU_STATE *pMS)
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
static BOOLEAN
|
||||
DoQuitMenu (MENU_STATE *pMS)
|
||||
{
|
||||
if (GLOBAL (CurrentActivity) & CHECK_ABORT)
|
||||
return (FALSE);
|
||||
|
||||
SetMenuSounds (MENU_SOUND_ARROWS, MENU_SOUND_SELECT);
|
||||
|
||||
if (!pMS->Initialized)
|
||||
{
|
||||
DrawMenuStateStrings (PM_NO_QUIT, pMS->CurState);
|
||||
FeedbackQuit (pMS->CurState);
|
||||
pMS->Initialized = TRUE;
|
||||
pMS->InputFunc = DoQuitMenu;
|
||||
}
|
||||
else if (PulsedInputState.menu[KEY_MENU_CANCEL]
|
||||
|| (PulsedInputState.menu[KEY_MENU_SELECT]
|
||||
&& pMS->CurState == NO_QUIT_MENU))
|
||||
{
|
||||
LockMutex (GraphicsLock);
|
||||
DrawStatusMessage (NULL);
|
||||
UnlockMutex (GraphicsLock);
|
||||
|
||||
pMS->CurState = QUIT_GAME;
|
||||
pMS->InputFunc = DoGameOptions;
|
||||
pMS->Initialized = 0;
|
||||
}
|
||||
else if (PulsedInputState.menu[KEY_MENU_SELECT])
|
||||
{
|
||||
switch (pMS->CurState)
|
||||
{
|
||||
case NO_QUIT_MENU:
|
||||
break;
|
||||
case YES_QUIT_MENU:
|
||||
GLOBAL (CurrentActivity) |= CHECK_ABORT;
|
||||
ExitRequested = FALSE;
|
||||
break;
|
||||
}
|
||||
FeedbackQuit (pMS->CurState);
|
||||
}
|
||||
else if (DoMenuChooser (pMS, PM_NO_QUIT))
|
||||
FeedbackQuit (pMS->CurState);
|
||||
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
static void
|
||||
DrawCargo (COUNT redraw_state)
|
||||
{
|
||||
@@ -778,8 +706,7 @@ ShowSummary (SUMMARY_DESC *pSD)
|
||||
{
|
||||
s.origin.x = SUMMARY_X_OFFS - SUMMARY_SIDE_OFFS + 6;
|
||||
s.origin.y = 0;
|
||||
s.frame = SetRelFrameIndex (
|
||||
pLocMenuState->ModuleFrame, 0);
|
||||
s.frame = SetRelFrameIndex (pLocMenuState->ModuleFrame, 0);
|
||||
DrawStamp (&s);
|
||||
s.origin.x = SUMMARY_X_OFFS + SUMMARY_SIDE_OFFS;
|
||||
s.frame = IncFrameIndex (s.frame);
|
||||
@@ -940,7 +867,7 @@ DoPickGame (MENU_STATE *pMS)
|
||||
{
|
||||
extern FRAME PlayFrame;
|
||||
|
||||
pMS->ModuleFrame = SetAbsFrameIndex (PlayFrame, 41);
|
||||
pMS->ModuleFrame = SetAbsFrameIndex (PlayFrame, 39);
|
||||
}
|
||||
|
||||
LockMutex (GraphicsLock);
|
||||
@@ -1330,9 +1257,8 @@ DoGameOptions (MENU_STATE *pMS)
|
||||
// to a FRAME.
|
||||
return PickGame (pMS);
|
||||
case QUIT_GAME:
|
||||
pMS->Initialized = FALSE;
|
||||
pMS->CurState = NO_QUIT_MENU;
|
||||
pMS->InputFunc = DoQuitMenu;
|
||||
if (ConfirmExit ())
|
||||
return FALSE;
|
||||
break;
|
||||
case SETTINGS:
|
||||
pMS->Initialized = FALSE;
|
||||
|
||||
@@ -41,11 +41,11 @@
|
||||
#define MELEE_STRING_COUNT 9
|
||||
#define SAVEGAME_STRING_COUNT 5
|
||||
#define OPTION_STRING_COUNT 5
|
||||
#define QUITMENU_STRING_COUNT 5
|
||||
#define QUITMENU_STRING_COUNT 3
|
||||
#define STATUS_STRING_COUNT 6
|
||||
#define FLAGSHIP_STRING_COUNT 13
|
||||
#define ORBITSCAN_STRING_COUNT 19
|
||||
#define MAINMENU_STRING_COUNT 57
|
||||
#define MAINMENU_STRING_COUNT 55
|
||||
#define NETMELEE_STRING_COUNT 19
|
||||
|
||||
enum {
|
||||
|
||||
@@ -150,9 +150,6 @@ GetEndMenuState (BYTE BaseState)
|
||||
case PM_SOUND_ON:
|
||||
return PM_EXIT_MENU4;
|
||||
break;
|
||||
case PM_NO_QUIT:
|
||||
return PM_YES_QUIT;
|
||||
break;
|
||||
case PM_ALT_SCAN:
|
||||
case PM_ALT_STARMAP:
|
||||
return PM_ALT_NAVIGATE;
|
||||
@@ -533,19 +530,6 @@ DrawMenuStateStrings (BYTE beg_index, SWORD NewState)
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (beg_index == PM_NO_QUIT)
|
||||
{
|
||||
end_index = beg_index + 1;
|
||||
switch (beg_index + NewState)
|
||||
{
|
||||
case PM_NO_QUIT:
|
||||
NewState = 0;
|
||||
break;
|
||||
case PM_YES_QUIT:
|
||||
NewState = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
r.extent.height = RADAR_HEIGHT + 11;
|
||||
DrawPCMenu (beg_index, end_index, (BYTE)NewState, hilite, &r);
|
||||
s.frame = 0;
|
||||
|
||||
@@ -20,5 +20,5 @@
|
||||
void
|
||||
MouseError (void)
|
||||
{
|
||||
DoPopupWindow (GAME_STRING (MAINMENU_STRING_BASE + 56));
|
||||
DoPopupWindow (GAME_STRING (MAINMENU_STRING_BASE + 54));
|
||||
}
|
||||
|
||||
@@ -245,7 +245,7 @@ DoRestart (MENU_STATE *pMS)
|
||||
LockMutex (GraphicsLock);
|
||||
SetFlashRect (NULL, (FRAME)0);
|
||||
UnlockMutex (GraphicsLock);
|
||||
DoPopupWindow (GAME_STRING (MAINMENU_STRING_BASE + 56));
|
||||
DoPopupWindow (GAME_STRING (MAINMENU_STRING_BASE + 54));
|
||||
// Mouse not supported message
|
||||
SetMenuSounds (MENU_SOUND_UP | MENU_SOUND_DOWN, MENU_SOUND_SELECT);
|
||||
SetTransitionSource (NULL);
|
||||
|
||||
@@ -51,9 +51,6 @@ enum
|
||||
PM_CHANGE_SHIP,
|
||||
PM_EXIT_MENU4,
|
||||
|
||||
PM_NO_QUIT,
|
||||
PM_YES_QUIT,
|
||||
|
||||
PM_ALT_SCAN,
|
||||
PM_ALT_STARMAP,
|
||||
PM_ALT_MANIFEST,
|
||||
|
||||
Reference in New Issue
Block a user