mirror of
https://github.com/1dot13/source.git
synced 2026-09-02 14:36:06 +02:00
- Fix: messagebox flagmask is UINT32, not UINT16 or UINT8
- added flag to display messagebox buttons horizontally instead of vertically git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8661 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+4
-4
@@ -5270,19 +5270,19 @@ BOOLEAN DoLapTopMessageBox( UINT8 ubStyle, const STR16 zString, UINT32 uiExitSc
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOLEAN DoLapTopSystemMessageBoxWithRect( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
BOOLEAN DoLapTopSystemMessageBoxWithRect( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
||||||
{
|
{
|
||||||
// reset exit mode
|
// reset exit mode
|
||||||
fExitDueToMessageBox = TRUE;
|
fExitDueToMessageBox = TRUE;
|
||||||
|
|
||||||
// do message box and return
|
// do message box and return
|
||||||
iLaptopMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( UINT16 ) ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, pCenteringRect );
|
iLaptopMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, pCenteringRect );
|
||||||
|
|
||||||
// send back return state
|
// send back return state
|
||||||
return( ( iLaptopMessageBox != -1 ) );
|
return( ( iLaptopMessageBox != -1 ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOLEAN DoLapTopSystemMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
BOOLEAN DoLapTopSystemMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
||||||
{
|
{
|
||||||
SGPRect CenteringRect= {iScreenWidthOffset, iScreenHeightOffset,
|
SGPRect CenteringRect= {iScreenWidthOffset, iScreenHeightOffset,
|
||||||
iScreenWidthOffset + 640, INV_INTERFACE_START_Y };
|
iScreenWidthOffset + 640, INV_INTERFACE_START_Y };
|
||||||
@@ -5292,7 +5292,7 @@ BOOLEAN DoLapTopSystemMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScr
|
|||||||
fExitDueToMessageBox = TRUE;
|
fExitDueToMessageBox = TRUE;
|
||||||
|
|
||||||
// do message box and return
|
// do message box and return
|
||||||
iLaptopMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( UINT16 ) ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, &CenteringRect );
|
iLaptopMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, &CenteringRect );
|
||||||
|
|
||||||
// send back return state
|
// send back return state
|
||||||
return( ( iLaptopMessageBox != -1 ) );
|
return( ( iLaptopMessageBox != -1 ) );
|
||||||
|
|||||||
+1
-1
@@ -37,7 +37,7 @@ void BlitTitleBarIcons( void );
|
|||||||
void HandleKeyBoardShortCutsForLapTop( UINT16 usEvent, UINT32 usParam, UINT16 usKeyState );
|
void HandleKeyBoardShortCutsForLapTop( UINT16 usEvent, UINT32 usParam, UINT16 usKeyState );
|
||||||
BOOLEAN RenderWWWProgramTitleBar( void );
|
BOOLEAN RenderWWWProgramTitleBar( void );
|
||||||
void DisplayProgramBoundingBox( BOOLEAN fMarkButtons );
|
void DisplayProgramBoundingBox( BOOLEAN fMarkButtons );
|
||||||
BOOLEAN DoLapTopSystemMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
BOOLEAN DoLapTopSystemMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
||||||
BOOLEAN RemoveBookMark( INT32 iBookId );
|
BOOLEAN RemoveBookMark( INT32 iBookId );
|
||||||
void CreateFileAndNewEmailIconFastHelpText( UINT32 uiHelpTextID, BOOLEAN fClearHelpText );
|
void CreateFileAndNewEmailIconFastHelpText( UINT32 uiHelpTextID, BOOLEAN fClearHelpText );
|
||||||
BOOLEAN InitLaptopAndLaptopScreens();
|
BOOLEAN InitLaptopAndLaptopScreens();
|
||||||
|
|||||||
+20
-6
@@ -465,12 +465,26 @@ INT32 DoMessageBox( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UIN
|
|||||||
// Create four numbered buttons
|
// Create four numbered buttons
|
||||||
else if ( usFlags & MSG_BOX_FLAG_GENERIC_FOUR_BUTTONS )
|
else if ( usFlags & MSG_BOX_FLAG_GENERIC_FOUR_BUTTONS )
|
||||||
{
|
{
|
||||||
sButtonX = (usTextBoxWidth - 115)/ 2;
|
|
||||||
sButtonY = usTextBoxHeight - MSGBOX_BUTTON_HEIGHT - 130 - MSGBOX_SMALL_BUTTON_WIDTH - MSGBOX_SMALL_BUTTON_X_SEP;
|
sButtonY = usTextBoxHeight - MSGBOX_BUTTON_HEIGHT - 130 - MSGBOX_SMALL_BUTTON_WIDTH - MSGBOX_SMALL_BUTTON_X_SEP;
|
||||||
|
|
||||||
|
if ( usFlags & MSG_BOX_BUTTONS_HORIZONTAL_ORIENTATION )
|
||||||
|
{
|
||||||
|
sBlankSpace = usTextBoxWidth - (MSGBOX_BUTTON_WIDTH + MSGBOX_SMALL_BUTTON_X_SEP) * 4;
|
||||||
|
sButtonX = MSGBOX_SMALL_BUTTON_X_SEP;
|
||||||
|
sButtonY += 60;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sButtonX = ( usTextBoxWidth - 115 ) / 2;
|
||||||
|
}
|
||||||
|
|
||||||
for ( INT8 j = 0; j < 4; ++j)
|
for ( INT8 j = 0; j < 4; ++j)
|
||||||
{
|
{
|
||||||
sButtonY += 35;
|
if ( usFlags & MSG_BOX_BUTTONS_HORIZONTAL_ORIENTATION )
|
||||||
|
sButtonX += 60;
|
||||||
|
else
|
||||||
|
sButtonY += 35;
|
||||||
|
|
||||||
gMsgBox.uiButton[j] = CreateIconAndTextButton( gMsgBox.iButtonImages, gzUserDefinedButton[j], FONT12ARIAL,
|
gMsgBox.uiButton[j] = CreateIconAndTextButton( gMsgBox.iButtonImages, gzUserDefinedButton[j], FONT12ARIAL,
|
||||||
ubFontColor, ubFontShadowColor,
|
ubFontColor, ubFontShadowColor,
|
||||||
ubFontColor, ubFontShadowColor,
|
ubFontColor, ubFontShadowColor,
|
||||||
@@ -1703,28 +1717,28 @@ UINT32 MessageBoxScreenShutdown( )
|
|||||||
|
|
||||||
|
|
||||||
// a basic box that don't care what screen we came from
|
// a basic box that don't care what screen we came from
|
||||||
void DoScreenIndependantMessageBox( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
void DoScreenIndependantMessageBox( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
||||||
{
|
{
|
||||||
SGPRect CenteringRect= {0, 0, SCREEN_WIDTH, INV_INTERFACE_START_Y };
|
SGPRect CenteringRect= {0, 0, SCREEN_WIDTH, INV_INTERFACE_START_Y };
|
||||||
DoScreenIndependantMessageBoxWithRect( zString, usFlags, ReturnCallback, &CenteringRect );
|
DoScreenIndependantMessageBoxWithRect( zString, usFlags, ReturnCallback, &CenteringRect );
|
||||||
}
|
}
|
||||||
|
|
||||||
// a basic box that don't care what screen we came from
|
// a basic box that don't care what screen we came from
|
||||||
void DoUpperScreenIndependantMessageBox( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
void DoUpperScreenIndependantMessageBox( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
||||||
{
|
{
|
||||||
SGPRect CenteringRect= {0, 0, SCREEN_WIDTH, INV_INTERFACE_START_Y / 2 };
|
SGPRect CenteringRect= {0, 0, SCREEN_WIDTH, INV_INTERFACE_START_Y / 2 };
|
||||||
DoScreenIndependantMessageBoxWithRect( zString, usFlags, ReturnCallback, &CenteringRect );
|
DoScreenIndependantMessageBoxWithRect( zString, usFlags, ReturnCallback, &CenteringRect );
|
||||||
}
|
}
|
||||||
|
|
||||||
// a basic box that don't care what screen we came from
|
// a basic box that don't care what screen we came from
|
||||||
void DoLowerScreenIndependantMessageBox( STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
void DoLowerScreenIndependantMessageBox( STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
||||||
{
|
{
|
||||||
SGPRect CenteringRect= {0, INV_INTERFACE_START_Y / 2, SCREEN_WIDTH, INV_INTERFACE_START_Y };
|
SGPRect CenteringRect= {0, INV_INTERFACE_START_Y / 2, SCREEN_WIDTH, INV_INTERFACE_START_Y };
|
||||||
DoScreenIndependantMessageBoxWithRect( zString, usFlags, ReturnCallback, &CenteringRect );
|
DoScreenIndependantMessageBoxWithRect( zString, usFlags, ReturnCallback, &CenteringRect );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void DoScreenIndependantMessageBoxWithRect( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
void DoScreenIndependantMessageBoxWithRect( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
||||||
{
|
{
|
||||||
|
|
||||||
/// which screen are we in?
|
/// which screen are we in?
|
||||||
|
|||||||
+9
-8
@@ -26,6 +26,7 @@
|
|||||||
#define MSG_BOX_FLAG_DROPDOWN_1 0x00010000 // Displays an additional dropdown box
|
#define MSG_BOX_FLAG_DROPDOWN_1 0x00010000 // Displays an additional dropdown box
|
||||||
#define MSG_BOX_FLAG_DROPDOWN_2 0x00020000 // Displays another additional dropdown box
|
#define MSG_BOX_FLAG_DROPDOWN_2 0x00020000 // Displays another additional dropdown box
|
||||||
#define MSG_BOX_FLAG_IMAGE 0x00040000 // Displays an image
|
#define MSG_BOX_FLAG_IMAGE 0x00040000 // Displays an image
|
||||||
|
#define MSG_BOX_BUTTONS_HORIZONTAL_ORIENTATION 0x00080000 // MSG_BOX_FLAG_GENERIC_FOUR_BUTTONS sets the buttons horizontally
|
||||||
|
|
||||||
// message box return codes
|
// message box return codes
|
||||||
#define MSG_BOX_RETURN_OK 1 // ENTER or on OK button
|
#define MSG_BOX_RETURN_OK 1 // ENTER or on OK button
|
||||||
@@ -132,17 +133,17 @@ extern CHAR16 gszMsgBoxInputString[255];
|
|||||||
////////////////////////////////
|
////////////////////////////////
|
||||||
|
|
||||||
INT32 DoMessageBox( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect, UINT8 ubDefaultButton = MSG_BOX_DEFAULT_BUTTON_NONE );
|
INT32 DoMessageBox( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect, UINT8 ubDefaultButton = MSG_BOX_DEFAULT_BUTTON_NONE );
|
||||||
void DoScreenIndependantMessageBox( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
void DoScreenIndependantMessageBox( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
||||||
void DoUpperScreenIndependantMessageBox( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
void DoUpperScreenIndependantMessageBox( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
||||||
|
|
||||||
void DoLowerScreenIndependantMessageBox( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
void DoLowerScreenIndependantMessageBox( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
||||||
void DoScreenIndependantMessageBoxWithRect( const STR16 zString, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
void DoScreenIndependantMessageBoxWithRect( const STR16 zString, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
||||||
|
|
||||||
//wrappers for other screens
|
//wrappers for other screens
|
||||||
BOOLEAN DoLapTopSystemMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
BOOLEAN DoLapTopSystemMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
||||||
INT32 DoMapMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
INT32 DoMapMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
||||||
BOOLEAN DoOptionsMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
BOOLEAN DoOptionsMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
||||||
BOOLEAN DoSaveLoadMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
BOOLEAN DoSaveLoadMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect );
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
+2
-2
@@ -1544,14 +1544,14 @@ void MusicSliderChangeCallBack( INT32 iNewValue )
|
|||||||
MusicSetVolume( iNewValue );
|
MusicSetVolume( iNewValue );
|
||||||
}
|
}
|
||||||
|
|
||||||
BOOLEAN DoOptionsMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags,
|
BOOLEAN DoOptionsMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags,
|
||||||
MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
||||||
{
|
{
|
||||||
// reset exit mode
|
// reset exit mode
|
||||||
gfExitOptionsDueToMessageBox = TRUE;
|
gfExitOptionsDueToMessageBox = TRUE;
|
||||||
|
|
||||||
// do message box and return
|
// do message box and return
|
||||||
giOptionsMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( UINT16 ) ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ),
|
giOptionsMessageBox = DoMessageBox( ubStyle, zString, uiExitScreen, ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ),
|
||||||
ReturnCallback, pCenteringRect );
|
ReturnCallback, pCenteringRect );
|
||||||
|
|
||||||
// send back return state
|
// send back return state
|
||||||
|
|||||||
+1
-1
@@ -1305,7 +1305,7 @@ void SaveLoadGameNumber( INT32 bSaveGameID )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
BOOLEAN DoSaveLoadMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
BOOLEAN DoSaveLoadMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
||||||
{
|
{
|
||||||
// do message box and return
|
// do message box and return
|
||||||
giSaveLoadMessageBox = DoMessageBox(ubStyle,zString,uiExitScreen,( UINT8 )( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, pCenteringRect );
|
giSaveLoadMessageBox = DoMessageBox(ubStyle,zString,uiExitScreen,( UINT8 )( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, pCenteringRect );
|
||||||
|
|||||||
@@ -1211,15 +1211,15 @@ void ActivateSoldierPopup( SOLDIERTYPE *pSoldier, UINT8 ubPopupType, INT16 xp, I
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
INT32 DoMapMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
INT32 DoMapMessageBoxWithRect( UINT8 ubStyle, const STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback, SGPRect *pCenteringRect )
|
||||||
{
|
{
|
||||||
// reset the highlighted line
|
// reset the highlighted line
|
||||||
giHighLine = -1;
|
giHighLine = -1;
|
||||||
return DoMessageBox( ubStyle, zString, uiExitScreen, ( UINT16 ) ( usFlags | MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, pCenteringRect );
|
return DoMessageBox( ubStyle, zString, uiExitScreen, ( usFlags | MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, pCenteringRect );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
INT32 DoMapMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
INT32 DoMapMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
||||||
{
|
{
|
||||||
SGPRect CenteringRect= {0 + xResOffset, 0 + yResOffset, SCREEN_WIDTH - xResOffset, INV_INTERFACE_START_Y };
|
SGPRect CenteringRect= {0 + xResOffset, 0 + yResOffset, SCREEN_WIDTH - xResOffset, INV_INTERFACE_START_Y };
|
||||||
|
|
||||||
@@ -1227,7 +1227,7 @@ INT32 DoMapMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT16
|
|||||||
giHighLine = -1;
|
giHighLine = -1;
|
||||||
|
|
||||||
// do message box and return
|
// do message box and return
|
||||||
return DoMessageBox( ubStyle, zString, uiExitScreen, ( UINT16 ) ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, &CenteringRect );
|
return DoMessageBox( ubStyle, zString, uiExitScreen, ( usFlags| MSG_BOX_FLAG_USE_CENTERING_RECT ), ReturnCallback, &CenteringRect );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -489,7 +489,7 @@ void EnableTeamInfoPanels( void );
|
|||||||
void ActivateSoldierPopup( SOLDIERTYPE *pSoldier, UINT8 ubPopupType, INT16 xp, INT16 yp );
|
void ActivateSoldierPopup( SOLDIERTYPE *pSoldier, UINT8 ubPopupType, INT16 xp, INT16 yp );
|
||||||
|
|
||||||
// do mapscreen message box
|
// do mapscreen message box
|
||||||
INT32 DoMapMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
INT32 DoMapMessageBox( UINT8 ubStyle, STR16 zString, UINT32 uiExitScreen, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback );
|
||||||
|
|
||||||
// hop up one leve,l int he map screen level interface
|
// hop up one leve,l int he map screen level interface
|
||||||
void GoUpOneLevelInMap( void );
|
void GoUpOneLevelInMap( void );
|
||||||
|
|||||||
@@ -912,7 +912,7 @@ DebugMsg (TOPIC_JA2,DBG_LEVEL_3,"Militia2");
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void DoContinueMilitiaTrainingMessageBox( INT16 sSectorX, INT16 sSectorY, const STR16 str, UINT16 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
void DoContinueMilitiaTrainingMessageBox( INT16 sSectorX, INT16 sSectorY, const STR16 str, UINT32 usFlags, MSGBOX_CALLBACK ReturnCallback )
|
||||||
{
|
{
|
||||||
if( sSectorX <= 10 && sSectorY >= 6 && sSectorY <= 11 )
|
if( sSectorX <= 10 && sSectorY >= 6 && sSectorY <= 11 )
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -6362,7 +6362,7 @@ void ItemDescAttachmentsCallback( MOUSE_REGION * pRegion, INT32 iReason )
|
|||||||
{
|
{
|
||||||
iItemPosition = uiItemPos;
|
iItemPosition = uiItemPos;
|
||||||
gbMessageBoxSubObject = (UINT8)ubStatusIndex;
|
gbMessageBoxSubObject = (UINT8)ubStatusIndex;
|
||||||
DoScreenIndependantMessageBox( Message[ STR_PERMANENT_ATTACHMENT ], ( UINT8 )MSG_BOX_FLAG_YESNO, PermanantAttachmentMessageBoxCallBack );
|
DoScreenIndependantMessageBox( Message[ STR_PERMANENT_ATTACHMENT ], MSG_BOX_FLAG_YESNO, PermanantAttachmentMessageBoxCallBack );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4222,15 +4222,15 @@ void GetKeyboardInput( UINT32 *puiNewEvent )
|
|||||||
switch( gGameOptions.ubIronManMode )
|
switch( gGameOptions.ubIronManMode )
|
||||||
{
|
{
|
||||||
case 2:
|
case 2:
|
||||||
DoMapMessageBox( MSG_BOX_BASIC_STYLE, zNewTacticalMessages[ TCTL_MSG__SOFT_IRON_MAN_CANT_SAVE_NOW ], GAME_SCREEN, ( UINT8 )MSG_BOX_FLAG_OK, NULL );
|
DoMapMessageBox( MSG_BOX_BASIC_STYLE, zNewTacticalMessages[ TCTL_MSG__SOFT_IRON_MAN_CANT_SAVE_NOW ], GAME_SCREEN, MSG_BOX_FLAG_OK, NULL );
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
CHAR16 zTemp[320];
|
CHAR16 zTemp[320];
|
||||||
swprintf( zTemp, zNewTacticalMessages[ TCTL_MSG__EXTREME_IRON_MAN_CANT_SAVE_NOW ], gGameExternalOptions.ubExtremeIronManSavingHour);
|
swprintf( zTemp, zNewTacticalMessages[ TCTL_MSG__EXTREME_IRON_MAN_CANT_SAVE_NOW ], gGameExternalOptions.ubExtremeIronManSavingHour);
|
||||||
DoMapMessageBox( MSG_BOX_BASIC_STYLE, zTemp, GAME_SCREEN, ( UINT8 )MSG_BOX_FLAG_OK, NULL );
|
DoMapMessageBox( MSG_BOX_BASIC_STYLE, zTemp, GAME_SCREEN, MSG_BOX_FLAG_OK, NULL );
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
DoMessageBox( MSG_BOX_BASIC_STYLE, zNewTacticalMessages[ TCTL_MSG__IRON_MAN_CANT_SAVE_NOW ], GAME_SCREEN, ( UINT8 )MSG_BOX_FLAG_OK, NULL, NULL );
|
DoMessageBox( MSG_BOX_BASIC_STYLE, zNewTacticalMessages[ TCTL_MSG__IRON_MAN_CANT_SAVE_NOW ], GAME_SCREEN, MSG_BOX_FLAG_OK, NULL, NULL );
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -8722,7 +8722,7 @@ INT32 InvItemType( UINT16 usItem )
|
|||||||
return INV_ITEM_TYPE_FIRSTAID;
|
return INV_ITEM_TYPE_FIRSTAID;
|
||||||
if( Item[ usItem ].usItemClass == IC_BLADE )
|
if( Item[ usItem ].usItemClass == IC_BLADE )
|
||||||
return INV_ITEM_TYPE_MELEE;
|
return INV_ITEM_TYPE_MELEE;
|
||||||
if( Item[ usItem ].usItemClass == IC_PUNCH && !(Item[ usItem ].usItemFlag & TASER) )
|
if( Item[ usItem ].usItemClass == IC_PUNCH && !HasItemFlag( usItem, TASER ) )
|
||||||
return INV_ITEM_TYPE_HTH;
|
return INV_ITEM_TYPE_HTH;
|
||||||
if( HasItemFlag( usItem, HANDCUFFS ) )
|
if( HasItemFlag( usItem, HANDCUFFS ) )
|
||||||
//if( Item[ usItem ].usItemClass == IC_MISC && Item[ usItem ].usItemFlag & HANDCUFFS )
|
//if( Item[ usItem ].usItemClass == IC_MISC && Item[ usItem ].usItemFlag & HANDCUFFS )
|
||||||
@@ -8730,7 +8730,7 @@ INT32 InvItemType( UINT16 usItem )
|
|||||||
//Item[ uiItem ].usSpotting
|
//Item[ uiItem ].usSpotting
|
||||||
if( Item[ usItem ].usItemClass == IC_MISC && Item[ usItem ].dayvisionrangebonus )
|
if( Item[ usItem ].usItemClass == IC_MISC && Item[ usItem ].dayvisionrangebonus )
|
||||||
return INV_ITEM_TYPE_BINOCULARS;
|
return INV_ITEM_TYPE_BINOCULARS;
|
||||||
if( Item[ usItem ].usItemFlag & TASER )
|
if( HasItemFlag( usItem, TASER ) )
|
||||||
return INV_ITEM_TYPE_TASER;
|
return INV_ITEM_TYPE_TASER;
|
||||||
if( Item[ usItem ].usItemClass == IC_GUN && !Item[ usItem ].twohanded && Weapon[Item[ usItem ].ubClassIndex].ubWeaponType <= GUN_SMG )
|
if( Item[ usItem ].usItemClass == IC_GUN && !Item[ usItem ].twohanded && Weapon[Item[ usItem ].ubClassIndex].ubWeaponType <= GUN_SMG )
|
||||||
return INV_ITEM_TYPE_SIDEARM;
|
return INV_ITEM_TYPE_SIDEARM;
|
||||||
|
|||||||
@@ -416,6 +416,9 @@ INT32 PrepareMercPopupBox( INT32 iBoxId, UINT8 ubBackgroundIndex, UINT8 ubBorder
|
|||||||
if( usWidth >= MERC_BACKGROUND_WIDTH )
|
if( usWidth >= MERC_BACKGROUND_WIDTH )
|
||||||
usWidth = MERC_BACKGROUND_WIDTH-1;
|
usWidth = MERC_BACKGROUND_WIDTH-1;
|
||||||
|
|
||||||
|
if ( usHeight >= MERC_BACKGROUND_HEIGHT )
|
||||||
|
usHeight = MERC_BACKGROUND_HEIGHT - 1;
|
||||||
|
|
||||||
//make sure the area isnt bigger then the background texture
|
//make sure the area isnt bigger then the background texture
|
||||||
if( ( usWidth >= MERC_BACKGROUND_WIDTH ) || usHeight >= MERC_BACKGROUND_HEIGHT)
|
if( ( usWidth >= MERC_BACKGROUND_WIDTH ) || usHeight >= MERC_BACKGROUND_HEIGHT)
|
||||||
{
|
{
|
||||||
|
|||||||
+1
-1
@@ -550,7 +550,7 @@ void HandleShortCutExitState( void )
|
|||||||
|
|
||||||
if( guiCurrentScreen == AUTORESOLVE_SCREEN )
|
if( guiCurrentScreen == AUTORESOLVE_SCREEN )
|
||||||
{
|
{
|
||||||
DoMessageBox( MSG_BOX_BASIC_STYLE, pMessageStrings[ MSG_EXITGAME ], guiCurrentScreen, ( UINT8 ) ( MSG_BOX_FLAG_YESNO | MSG_BOX_FLAG_USE_CENTERING_RECT ), EndGameMessageBoxCallBack, &pCenteringRect );
|
DoMessageBox( MSG_BOX_BASIC_STYLE, pMessageStrings[ MSG_EXITGAME ], guiCurrentScreen, ( MSG_BOX_FLAG_YESNO | MSG_BOX_FLAG_USE_CENTERING_RECT ), EndGameMessageBoxCallBack, &pCenteringRect );
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user