added slay

> $$$ 4 iggy
fixed coop
stopped speck talking
preopened merc account
CREATURE_ENABLED = 0 no longer has any effect u can remove it from ur ini
ALLOW_CUSTOM_NIV = 1   -> new server ini variable, please add
added gear cost to MERC's

please feel free to make suggestion on MERC NPC costs...

git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@2178 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
haydent
2008-05-18 02:53:59 +00:00
parent f17cc948a4
commit 741e5c03bf
7 changed files with 68 additions and 24 deletions
+15 -2
View File
@@ -535,6 +535,7 @@ void DisplayMercsStats( UINT8 ubMercID )
{
UINT16 usPosY, usPosX;
CHAR16 sString[128];
CHAR16 NsString[128];
usPosY = MERC_HEALTH_Y;
@@ -599,7 +600,10 @@ void DisplayMercsStats( UINT8 ubMercID )
usPosX = MERC_STATS_SECOND_COL_X + StringPixLength(MercInfo[MERC_FILES_SALARY], MERC_NAME_FONT) + 1;
swprintf(sString, L"%d %s", gMercProfiles[ ubMercID ].sSalary, MercInfo[MERC_FILES_PER_DAY]);
swprintf(NsString, L"+ %d gear.",gMercProfiles[ ubMercID ].usOptionalGearCost);
DrawTextToScreen( sString, usPosX, usPosY, 95, MERC_NAME_FONT, MERC_DYNAMIC_STATS_COLOR, FONT_MCOLOR_BLACK, FALSE, RIGHT_JUSTIFIED);
if(is_networked && ALLOW_EQUIP)DrawTextToScreen( NsString, usPosX, usPosY+MERC_SPACE_BN_LINES, 95, MERC_NAME_FONT, MERC_DYNAMIC_STATS_COLOR, FONT_MCOLOR_BLACK, FALSE, RIGHT_JUSTIFIED);
}
@@ -608,6 +612,7 @@ BOOLEAN MercFilesHireMerc(UINT8 ubMercID)
{
MERC_HIRE_STRUCT HireMercStruct;
INT8 bReturnCode;
INT32 Namount=0;
memset(&HireMercStruct, 0, sizeof(MERC_HIRE_STRUCT));
@@ -652,7 +657,11 @@ BOOLEAN MercFilesHireMerc(UINT8 ubMercID)
//Set the time and ID of the last hired merc will arrive
// LaptopSaveInfo.sLastHiredMerc.iIdOfMerc = HireMercStruct.ubProfileID;
// LaptopSaveInfo.sLastHiredMerc.uiArrivalTime = HireMercStruct.uiTimeTillMercArrives;
if(is_networked && (gMercProfiles[ ubMercID ].sSalary > LaptopSaveInfo.iCurrentBalance) )
Namount += gMercProfiles[ ubMercID ].sSalary * (-1);
if(ALLOW_EQUIP)Namount += gMercProfiles[ubMercID].usOptionalGearCost * (-1);
if(is_networked && (Namount*(-1) > LaptopSaveInfo.iCurrentBalance))
{
DoLapTopMessageBox( MSG_BOX_LAPTOP_DEFAULT, sATMText[ 4 ], LAPTOP_SCREEN, MSG_BOX_FLAG_OK, NULL);
return(FALSE);//not enough big ones $$$sATMText
@@ -673,7 +682,11 @@ BOOLEAN MercFilesHireMerc(UINT8 ubMercID)
{
//take off nominal fee: hayden,
if (is_networked)
AddTransactionToPlayersBook( HIRED_MERC, ubMercID, GetWorldTotalMin(), gMercProfiles[ ubMercID ].sSalary * (-1) );
{
AddTransactionToPlayersBook( HIRED_MERC, ubMercID, GetWorldTotalMin(), Namount );
}
//if we succesfully hired the merc
return(TRUE);
}
+6
View File
@@ -27,6 +27,7 @@
#include "Quests.h"
#endif
#include "connect.h"
UINT8 NUMBER_OF_MERCS;
UINT8 LAST_MERC_ID;
@@ -362,6 +363,7 @@ void GameInitMercs()
gubMercArray[ 24 ] = 69;
gubMercArray[ 25 ] = 70;
gubMercArray[ 26 ] = 72;
gubMercArray[ 27 ] = 64;
LaptopSaveInfo.gubPlayersMercAccountStatus = MERC_NO_ACCOUNT;
gubCurMercIndex = 0;
@@ -1068,6 +1070,8 @@ void InitMercVideoFace()
BOOLEAN StartSpeckTalking(UINT16 usQuoteNum)
{
if(is_networked)return( FALSE );
if( usQuoteNum == MERC_VIDEO_SPECK_SPEECH_NOT_TALKING || usQuoteNum == MERC_VIDEO_SPECK_HAS_TO_TALK_BUT_QUOTE_NOT_CHOSEN_YET )
return( FALSE );
@@ -2161,6 +2165,8 @@ BOOLEAN ShouldSpeckStartTalkingDueToActionOnSubPage()
BOOLEAN ShouldSpeckSayAQuote()
{
//if we are entering from anywhere except a sub page, and we should say the opening quote
if( gfJustEnteredMercSite && gubArrivedFromMercSubSite == MERC_CAME_FROM_OTHER_PAGE )
{
+2 -3
View File
@@ -8,9 +8,8 @@
extern UINT8 NUMBER_OF_MERCS;
extern UINT8 LAST_MERC_ID;
#define MAX_NUMBER_OF_MERCS 27
//#define NUMBER_OF_MERCS 27//hayden
//#define LAST_MERC_ID 26//hayden
#define MAX_NUMBER_OF_MERCS 28
#define NUMBER_OF_BAD_MERCS 5
#define NUMBER_MERCS_AFTER_FIRST_MERC_ARRIVES 6
#define NUMBER_MERCS_AFTER_SECOND_MERC_ARRIVES 8