From 68510dd26d435541161e92493975b7c727f526b7 Mon Sep 17 00:00:00 2001 From: lalien Date: Thu, 15 Jun 2006 11:48:10 +0000 Subject: [PATCH] - Added menu option to show/remove item shadow - fixed menu descriptions git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@233 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- GameSettings.cpp | 1 + GameSettings.h | 1 + GameVersion.cpp | 2 +- JA2.vcproj | 4 ++-- Laptop/AimMembers.cpp | 2 +- Laptop/BobbyRGuns.cpp | 2 +- Laptop/personnel.cpp | 2 +- Tactical/Interface Items.cpp | 6 +++--- Tactical/ShopKeeper Interface.cpp | 2 +- Utils/_EnglishText.cpp | 2 ++ Utils/_GermanText.cpp | 4 +++- Utils/_RussianText.cpp | 4 +++- 12 files changed, 20 insertions(+), 12 deletions(-) diff --git a/GameSettings.cpp b/GameSettings.cpp index 95edee5f..5175c7ca 100644 --- a/GameSettings.cpp +++ b/GameSettings.cpp @@ -252,6 +252,7 @@ void InitGameSettings() //lalien gGameSettings.fOptions[ TOPTION_SPACE_SELECTS_NEXT_SQUAD ] = TRUE; + gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ] = TRUE; gGameSettings.ubSizeOfDisplayCover = 4; gGameSettings.ubSizeOfLOS = 4; diff --git a/GameSettings.h b/GameSettings.h index c62673b5..c8d6f70a 100644 --- a/GameSettings.h +++ b/GameSettings.h @@ -46,6 +46,7 @@ enum TOPTION_GL_HIGH_ANGLE, TOPTION_AIM_LEVEL_RESTRICTION, TOPTION_SPACE_SELECTS_NEXT_SQUAD, + TOPTION_SHOW_ITEM_SHADOW, NUM_GAME_OPTIONS, //Toggle up this will be able to be Toggled by the player //These options will NOT be toggable by the Player diff --git a/GameVersion.cpp b/GameVersion.cpp index 45d0a80e..9833675b 100644 --- a/GameVersion.cpp +++ b/GameVersion.cpp @@ -23,7 +23,7 @@ INT16 zVersionLabel[256] = { L"Beta v. 0.98" }; #else //RELEASE BUILD VERSION - INT16 zVersionLabel[256] = { L"Release v1.13.231" }; + INT16 zVersionLabel[256] = { L"Release v1.13.233" }; #endif diff --git a/JA2.vcproj b/JA2.vcproj index da67f4eb..4d530bbb 100644 --- a/JA2.vcproj +++ b/JA2.vcproj @@ -43,7 +43,7 @@ sOffsetY; //blt the shadow of the item - BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX-2, sCenY+2); + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX-2, sCenY+2); //blt the item BltVideoObjectOutlineFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX, sCenY, 0, FALSE ); diff --git a/Laptop/BobbyRGuns.cpp b/Laptop/BobbyRGuns.cpp index eae1c66b..f146a48d 100644 --- a/Laptop/BobbyRGuns.cpp +++ b/Laptop/BobbyRGuns.cpp @@ -890,7 +890,7 @@ BOOLEAN DisplayBigItemImage(UINT16 usIndex, UINT16 PosY) //blt the shadow of the item - BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, uiImage, 0, sCenX-2, sCenY+2);//pItem->ubGraphicNum + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, uiImage, 0, sCenX-2, sCenY+2);//pItem->ubGraphicNum BltVideoObject(FRAME_BUFFER, hPixHandle, 0, sCenX, sCenY, VO_BLT_SRCTRANSPARENCY,NULL); DeleteVideoObjectFromIndex(uiImage); diff --git a/Laptop/personnel.cpp b/Laptop/personnel.cpp index f965dc2a..cc49e2c5 100644 --- a/Laptop/personnel.cpp +++ b/Laptop/personnel.cpp @@ -2508,7 +2508,7 @@ void RenderInventoryForCharacter( INT32 iId, INT32 iSlot ) sCenY = PosY + ( abs( 22 - usHeight ) / 2 ) - pTrav->sOffsetY; // shadow - //BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX-2, sCenY+2); + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX-2, sCenY+2); //blt the item BltVideoObjectOutlineFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX, sCenY, 0, FALSE ); diff --git a/Tactical/Interface Items.cpp b/Tactical/Interface Items.cpp index 1a4bb457..f830ef55 100644 --- a/Tactical/Interface Items.cpp +++ b/Tactical/Interface Items.cpp @@ -1994,7 +1994,7 @@ void INVRenderItem( UINT32 uiBuffer, SOLDIERTYPE * pSoldier, OBJECTTYPE *pObjec sCenY = sY + (INT16)( abs( sHeight - (double)usHeight ) / 2 ) - pTrav->sOffsetY; // Shadow area - BltVideoObjectOutlineShadowFromIndex( uiBuffer, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX - 2, sCenY + 2 ); + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( uiBuffer, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX - 2, sCenY + 2 ); BltVideoObjectOutlineFromIndex( uiBuffer, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX, sCenY, sOutlineColor, fOutline ); @@ -3054,7 +3054,7 @@ void RenderItemDescriptionBox( ) // Display item - BltVideoObjectOutlineShadowFromIndex( guiSAVEBUFFER, guiItemGraphic, 0, sCenX - 2, sCenY + 2 ); + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( guiSAVEBUFFER, guiItemGraphic, 0, sCenX - 2, sCenY + 2 ); BltVideoObjectFromIndex( guiSAVEBUFFER, guiItemGraphic, 0, sCenX, sCenY, VO_BLT_SRCTRANSPARENCY, NULL ); @@ -3542,7 +3542,7 @@ void RenderItemDescriptionBox( ) // Display item - BltVideoObjectOutlineShadowFromIndex( guiSAVEBUFFER, guiItemGraphic, 0, sCenX - 2, sCenY + 2 ); + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( guiSAVEBUFFER, guiItemGraphic, 0, sCenX - 2, sCenY + 2 ); BltVideoObjectFromIndex( guiSAVEBUFFER, guiItemGraphic, 0, sCenX, sCenY, VO_BLT_SRCTRANSPARENCY, NULL ); // Display status diff --git a/Tactical/ShopKeeper Interface.cpp b/Tactical/ShopKeeper Interface.cpp index d758eebe..d70156fd 100644 --- a/Tactical/ShopKeeper Interface.cpp +++ b/Tactical/ShopKeeper Interface.cpp @@ -2627,7 +2627,7 @@ UINT32 DisplayInvSlot( UINT8 ubSlotNum, UINT16 usItemIndex, UINT16 usPosX, UINT1 //blt the shadow of the item - BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX-2, sCenY+2); + if(gGameSettings.fOptions[ TOPTION_SHOW_ITEM_SHADOW ]) BltVideoObjectOutlineShadowFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX-2, sCenY+2); //blt the item BltVideoObjectOutlineFromIndex( FRAME_BUFFER, GetInterfaceGraphicForItem( pItem ), pItem->ubGraphicNum, sCenX, sCenY, Get16BPPColor( FROMRGB( 255, 255, 255 ) ), fHighlighted ); diff --git a/Utils/_EnglishText.cpp b/Utils/_EnglishText.cpp index f9cb4b92..1ba9b2a3 100644 --- a/Utils/_EnglishText.cpp +++ b/Utils/_EnglishText.cpp @@ -3417,6 +3417,7 @@ STR16 zOptionsToggleText[] = L"High Angle Grenade Launching", L"Restrict Extra Aim Levels to Rifles", L"Space selects next squad", + L"Show Item Shadow", }; //This is the help text associated with the above toggles. @@ -3488,6 +3489,7 @@ STR16 zOptionsScreenHelpText[] = L"Grenade launchers fire grenades at higher angles.", L"Aim levels beyond 4 are restricted to rifles and sniper rifles.", L"When enabled |S|p|a|c|e selects next squad automatically.", + L"When enabled item shadows will be shown.", }; diff --git a/Utils/_GermanText.cpp b/Utils/_GermanText.cpp index 466019b5..7565f5a1 100644 --- a/Utils/_GermanText.cpp +++ b/Utils/_GermanText.cpp @@ -3221,7 +3221,7 @@ STR16 zOptionsToggleText[] = L"High Angle Grenade Launching", L"Restrict Extra Aim Levels to Rifles", L"Space selects next squad", - L"When enabled |S|p|a|c|e selects next squad automatically.", + L"Show Item Shadow", }; //This is the help text associated with the above toggles. @@ -3292,6 +3292,8 @@ STR16 zOptionsScreenHelpText[] = L"Gegner lassen bei ihrem Ableben alle Gegenstände zurück.", L"Grenade launchers fire grenades at higher angles.", L"Aim levels beyond 4 are restricted to rifles and sniper rifles.", + L"When enabled |S|p|a|c|e selects next squad automatically.", + L"When enabled item shadows will be shown.", }; STR16 gzGIOScreenText[] = diff --git a/Utils/_RussianText.cpp b/Utils/_RussianText.cpp index 646d7971..c25d4c95 100644 --- a/Utils/_RussianText.cpp +++ b/Utils/_RussianText.cpp @@ -3406,7 +3406,7 @@ STR16 zOptionsToggleText[] = L"High Angle Grenade Launching", L"Restrict Extra Aim Levels to Rifles", L"Space selects next squad", - L"When enabled |S|p|a|c|e selects next squad automatically.", + L"Show Item Shadow", }; //This is the help text associated with the above toggles. @@ -3477,6 +3477,8 @@ STR16 zOptionsScreenHelpText[] = L"Enemy drop all items, when he is dead.", L"Grenade launchers fire grenades at higher angles.", L"Aim levels beyond 4 are restricted to rifles and sniper rifles.", + L"When enabled |S|p|a|c|e selects next squad automatically.", + L"When enabled item shadows will be shown.", };