From c4c5ddeec1159023f42b9d7868e29f60450d4e4c Mon Sep 17 00:00:00 2001 From: MaddMugsy Date: Tue, 18 Jul 2006 04:29:26 +0000 Subject: [PATCH] -fixed BR's not restocking -fixed 90210 not working -fixed 8 character IMP names not working git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@353 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- GameVersion.cpp | 2 +- Laptop/BobbyR.cpp | 4 ++-- Laptop/IMP Confirm.cpp | 12 ++++++------ 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/GameVersion.cpp b/GameVersion.cpp index 47c9d433..82ef48b3 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.348" }; + INT16 zVersionLabel[256] = { L"Release v1.13.353" }; #endif diff --git a/Laptop/BobbyR.cpp b/Laptop/BobbyR.cpp index 2367ea71..264d1644 100644 --- a/Laptop/BobbyR.cpp +++ b/Laptop/BobbyR.cpp @@ -669,7 +669,7 @@ void DailyUpdateOfBobbyRaysNewInventory() if( LaptopSaveInfo.BobbyRayInventory[ i ].ubQtyOnOrder == 0) { //if the qty on hand is half the desired amount or fewer - if( LaptopSaveInfo.BobbyRayInventory[ i ].ubQtyOnHand <= (StoreInventory[ usItemIndex ][ BOBBY_RAY_NEW ] / 2 ) ) + if( LaptopSaveInfo.BobbyRayInventory[ i ].ubQtyOnHand <= (StoreInventory[ usItemIndex ][ BOBBY_RAY_NEW ] / 2 * gGameOptions.ubBobbyRay ) ) { // remember value of the "previously eligible" flag fPrevElig = LaptopSaveInfo.BobbyRayInventory[ i ].fPreviouslyEligible; @@ -766,7 +766,7 @@ UINT8 HowManyBRItemsToOrder(UINT16 usItemIndex, UINT8 ubCurrentlyOnHand, UINT8 u Assert(usItemIndex < MAXITEMS); // formulas below will fail if there are more items already in stock than optimal - Assert(ubCurrentlyOnHand <= StoreInventory[ usItemIndex ][ ubBobbyRayNewUsed ]); + Assert(ubCurrentlyOnHand <= StoreInventory[ usItemIndex ][ ubBobbyRayNewUsed ] * gGameOptions.ubBobbyRay) ; Assert(ubBobbyRayNewUsed < BOBBY_RAY_LISTS); diff --git a/Laptop/IMP Confirm.cpp b/Laptop/IMP Confirm.cpp index 9a58caa4..893d5201 100644 --- a/Laptop/IMP Confirm.cpp +++ b/Laptop/IMP Confirm.cpp @@ -653,18 +653,18 @@ INT32 FirstFreeBigEnoughPocket(MERCPROFILESTRUCT *pProfile, UINT16 usItem) void WriteOutCurrentImpCharacter( INT32 iProfileId ) { DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("WriteOutCurrentImpCharacter: IMP.dat")); - char zImpFileName[12]; - strcat(zImpFileName,IMP_MERC_FILENAME); + char zImpFileName[13]; + strcpy(zImpFileName,IMP_MERC_FILENAME); strcat(zImpFileName,IMP_FILENAME_SUFFIX); WriteOutCurrentImpCharacter ( iProfileId, zImpFileName); DebugMsg (TOPIC_JA2,DBG_LEVEL_3,String("WriteOutCurrentImpCharacter: Nickname.dat")); - char zFileName[12]; + char zFileName[13]; char temp; - for(int i=0;i < 8;i++) // Madd: I couldn't get strcpy or anything to work here... weird... if s/o wants to fix it, go ahead + for(int i=0;i < 9;i++) // Madd: I couldn't get strcpy or anything to work here... weird... if s/o wants to fix it, go ahead { temp = (char) gMercProfiles[iProfileId].zNickname[i]; zFileName[i] = temp; @@ -712,7 +712,7 @@ void WriteOutCurrentImpCharacter( INT32 iProfileId, STR fileName ) BOOLEAN ImpExists ( STR nickName ) { - char zFileName[12]; + char zFileName[13]; strcpy(zFileName,nickName); strcat(zFileName,IMP_FILENAME_SUFFIX); @@ -729,7 +729,7 @@ void LoadImpCharacter( STR nickName ) HWFILE hFile; UINT32 uiBytesRead = 0; - char zFileName[12]; + char zFileName[13]; strcpy(zFileName,nickName); strcat(zFileName,IMP_FILENAME_SUFFIX);