From b69207b74374ff466398dceeb1c53b5bfe297577 Mon Sep 17 00:00:00 2001 From: ChrisL Date: Mon, 13 Apr 2009 21:43:14 +0000 Subject: [PATCH] Disabled some of the charges associated with the Increased Aiming Costs option. Corrected a AP display issue when you had to turn while a weapon was not in a ready position. Updated build version. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@2736 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- GameVersion.cpp | 8 ++++---- Tactical/Points.cpp | 18 +++++++++++++++--- ja2_2005Express.vcproj | 8 ++++---- 3 files changed, 23 insertions(+), 11 deletions(-) diff --git a/GameVersion.cpp b/GameVersion.cpp index 824eb9b1..f6cf4824 100644 --- a/GameVersion.cpp +++ b/GameVersion.cpp @@ -13,12 +13,12 @@ #ifdef JA2EDITOR //MAP EDITOR BUILD VERSION -CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.2389" }; +CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.2736" }; #elif defined JA2BETAVERSION //BETA/TEST BUILD VERSION -CHAR16 zVersionLabel[256] = { L"Debug v1.13.2660" }; +CHAR16 zVersionLabel[256] = { L"Debug v1.13.2736" }; #elif defined CRIPPLED_VERSION @@ -28,11 +28,11 @@ CHAR16 zVersionLabel[256] = { L"Beta v. 0.98" }; #else //RELEASE BUILD VERSION - CHAR16 zVersionLabel[256] = { L"Release v1.13.2660" }; + CHAR16 zVersionLabel[256] = { L"Release v1.13.2736" }; #endif -CHAR8 czVersionNumber[16] = { "Build 09.04.02" }; //YY.MM.DD +CHAR8 czVersionNumber[16] = { "Build 09.04.13" }; //YY.MM.DD CHAR16 zTrackingNumber[16] = { L"Z" }; diff --git a/Tactical/Points.cpp b/Tactical/Points.cpp index 87c914e4..03d45a29 100644 --- a/Tactical/Points.cpp +++ b/Tactical/Points.cpp @@ -1104,6 +1104,8 @@ INT16 CalcTotalAPsToAttack( SOLDIERTYPE *pSoldier, INT16 sGridNo, UINT8 ubAddTur UINT8 ubDirection; INT16 sAdjustedGridNo; UINT32 uiItemClass; + BOOLEAN fAddingTurningCost = FALSE; + BOOLEAN fAddingRaiseGunCost = FALSE; // LOOK IN BUDDY'S HAND TO DETERMINE WHAT TO DO HERE usItemNum = pSoldier->inv[HANDPOS].usItem; @@ -1127,8 +1129,15 @@ INT16 CalcTotalAPsToAttack( SOLDIERTYPE *pSoldier, INT16 sGridNo, UINT8 ubAddTur // HEADROCK HAM B2.6: Changed the number of APs to attack when aiming. if (bAimTime > 0) { - // Add 1/2 ready cost (rounded up) for getting the sights up to the eye - sAPCost += ((Weapon[ usItemNum ].ubReadyTime * (100 - GetPercentReadyTimeAPReduction(&pSoldier->inv[HANDPOS])) / 100) + 1) / 2; + GetAPChargeForShootOrStabWRTGunRaises( pSoldier, sGridNo, ubAddTurningCost, &fAddingTurningCost, &fAddingRaiseGunCost ); + if(fAddingRaiseGunCost == TRUE) + { + //CHRISL: I'm disabling this for now. Charging 1/2 ready cost for every shot isn't legitimate + // but for the time being, we have no way to track whether we've previously aimed or not. Until + // we do, this code shouldn't be used. + // Add 1/2 ready cost (rounded up) for getting the sights up to the eye + //sAPCost += ((Weapon[ usItemNum ].ubReadyTime * (100 - GetPercentReadyTimeAPReduction(&pSoldier->inv[HANDPOS])) / 100) + 1) / 2; + } // Add regular aim time for the first 4 aiming actions. sAPCost += __min((bAimTime*APBPConstants[AP_CLICK_AIM]),(4*APBPConstants[AP_CLICK_AIM])); @@ -1140,7 +1149,10 @@ INT16 CalcTotalAPsToAttack( SOLDIERTYPE *pSoldier, INT16 sGridNo, UINT8 ubAddTur // Add time to adjust eye to scope if (bAimTime > 0) { - sAPCost += APBPConstants[AP_CLICK_AIM]; + //CHRISL: I'm disabling this for now. Charging an extra "click" every time we use a scope + // isn't legitimate. If we could track whether we previously used a scope on the current + // target, that would be another matter. But for now, we can't, so this should be used. + //sAPCost += APBPConstants[AP_CLICK_AIM]; } // Add 2 APs for each aiming point between 5 and 6 if (bAimTime > 4) diff --git a/ja2_2005Express.vcproj b/ja2_2005Express.vcproj index 385757cc..5c64bfa7 100644 --- a/ja2_2005Express.vcproj +++ b/ja2_2005Express.vcproj @@ -66,7 +66,7 @@