mirror of
https://github.com/1dot13/source.git
synced 2026-07-29 13:52:17 +02:00
- To make it easier to search for dialogue and understand what a line is supposed to mean, changed a few dialogue enums.
- Merged IsMercOnTeam...(...) functions into one - Fix: during hiring, AIM mercs only complained about their hated ones if these were already in the country, thus ignoring other mercs in transit git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8512 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -3217,7 +3217,7 @@ BOOLEAN CanMercBeHired()
|
||||
continue;
|
||||
}
|
||||
|
||||
if( IsMercOnTeamAndInOmertaAlready( bMercID ) )
|
||||
if( IsMercOnTeam( bMercID, TRUE, FALSE ) )
|
||||
{
|
||||
//if the merc hates someone on the team, see if a buddy is on the team
|
||||
for ( UINT8 j = 0; j< NUMBER_HATED_MERCS_ONTEAM; ++j )
|
||||
@@ -3239,7 +3239,7 @@ BOOLEAN CanMercBeHired()
|
||||
if( bMercID < 0 )
|
||||
continue;
|
||||
|
||||
if( IsMercOnTeam( bMercID ) && !IsMercDead( bMercID ) )
|
||||
if( IsMercOnTeam( bMercID, FALSE, FALSE ) && !IsMercDead( bMercID ) )
|
||||
{
|
||||
if ( j == 0 )
|
||||
{
|
||||
@@ -3282,7 +3282,7 @@ BOOLEAN CanMercBeHired()
|
||||
}
|
||||
else
|
||||
{
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_PERSONALITY_BIAS_WITH_HATED_1 );
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_HATED_1_ON_TEAM_LONGTIMETOHATE );
|
||||
fRetVal = TRUE;
|
||||
}
|
||||
}
|
||||
@@ -3296,8 +3296,8 @@ BOOLEAN CanMercBeHired()
|
||||
}
|
||||
else
|
||||
{
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_PERSONALITY_BIAS_WITH_HATED_2 );
|
||||
// DelayMercSpeech( gbCurrentSoldier, QUOTE_PERSONALITY_BIAS_WITH_MERC_2, 750, TRUE, FALSE );
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_HATED_2_ON_TEAM_LONGTIMETOHATE );
|
||||
// DelayMercSpeech( gbCurrentSoldier, QUOTE_HATED_2_ON_TEAM_LONGTIMETOHATE, 750, TRUE, FALSE );
|
||||
fRetVal = TRUE;
|
||||
}
|
||||
}
|
||||
@@ -3311,7 +3311,7 @@ BOOLEAN CanMercBeHired()
|
||||
}
|
||||
else
|
||||
{
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_PERSONALITY_BIAS_WITH_HATED_3 );
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_HATED_3_ON_TEAM_LONGTIMETOHATE );
|
||||
fRetVal = TRUE;
|
||||
}
|
||||
}
|
||||
@@ -3325,7 +3325,7 @@ BOOLEAN CanMercBeHired()
|
||||
}
|
||||
else
|
||||
{
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_PERSONALITY_BIAS_WITH_HATED_4 );
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_HATED_4_ON_TEAM_LONGTIMETOHATE );
|
||||
fRetVal = TRUE;
|
||||
}
|
||||
}
|
||||
@@ -3339,7 +3339,7 @@ BOOLEAN CanMercBeHired()
|
||||
}
|
||||
else
|
||||
{
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_PERSONALITY_BIAS_WITH_HATED_5 );
|
||||
InitVideoFaceTalking(gbCurrentSoldier, QUOTE_HATED_5_ON_TEAM_LONGTIMETOHATE );
|
||||
fRetVal = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -204,7 +204,7 @@ INT32 GetNumberOfHiredMercs()
|
||||
usMercID = GetMercIDFromMERCArray( i );
|
||||
|
||||
// Is the merc hired?
|
||||
if( IsMercOnTeam( (UINT8)usMercID ) || gMercProfiles[ usMercID ].iMercMercContractLength != 0 )
|
||||
if( IsMercOnTeam( (UINT8)usMercID, FALSE, FALSE ) || gMercProfiles[ usMercID ].iMercMercContractLength != 0 )
|
||||
{
|
||||
|
||||
#ifdef JA2UB
|
||||
@@ -527,7 +527,7 @@ void DisplayHiredMercs()
|
||||
usMercID = GetMercIDFromMERCArray( i );
|
||||
|
||||
//is the merc on the team, or is owed money
|
||||
if( IsMercOnTeam( (UINT8)usMercID ) || gMercProfiles[ usMercID ].iMercMercContractLength != 0 )
|
||||
if( IsMercOnTeam( (UINT8)usMercID, FALSE, FALSE ) || gMercProfiles[ usMercID ].iMercMercContractLength != 0 )
|
||||
{
|
||||
// count the number of mercs we really hired, but only display those that should be on this page
|
||||
++merccounter;
|
||||
@@ -616,7 +616,7 @@ void SettleMercAccounts()
|
||||
ubMercID = GetMercIDFromMERCArray( (UINT8) i );
|
||||
|
||||
//if the merc is on the team, or does the player owe money for a fired merc
|
||||
if( IsMercOnTeam( ubMercID ) || ( gMercProfiles[ ubMercID ].iMercMercContractLength != 0 ) )
|
||||
if( IsMercOnTeam( ubMercID, FALSE, FALSE ) || ( gMercProfiles[ ubMercID ].iMercMercContractLength != 0 ) )
|
||||
{
|
||||
//Calc the contract charge
|
||||
#ifdef JA2UB
|
||||
|
||||
+9
-9
@@ -1001,10 +1001,10 @@ void DailyUpdateOfMercSite( UINT16 usDate)
|
||||
iNumDays = 0;
|
||||
|
||||
//loop through all of the hired mercs from M.E.R.C.
|
||||
for(i=0; i<NUMBER_OF_MERCS; i++)
|
||||
for(i=0; i<NUMBER_OF_MERCS; ++i )
|
||||
{
|
||||
ubMercID = GetMercIDFromMERCArray( (UINT8) i );
|
||||
if( IsMercOnTeam( ubMercID ) )
|
||||
if( IsMercOnTeam( ubMercID, FALSE, FALSE ) )
|
||||
{
|
||||
// WANNE: If we have drunken merc, then skip otherwise is will exist 2 times!
|
||||
if (gConditionsForMercAvailability[ i ].Drunk)
|
||||
@@ -2325,10 +2325,10 @@ BOOLEAN IsAnyMercMercsHired( )
|
||||
UINT8 i;
|
||||
|
||||
//loop through all of the hired mercs from M.E.R.C.
|
||||
for(i=0; i<NUMBER_OF_MERCS; i++)
|
||||
for(i=0; i<NUMBER_OF_MERCS; ++i)
|
||||
{
|
||||
ubMercID = GetMercIDFromMERCArray( i );
|
||||
if( IsMercOnTeam( ubMercID ) )
|
||||
if( IsMercOnTeam( ubMercID, FALSE, FALSE ) )
|
||||
{
|
||||
return( TRUE );
|
||||
}
|
||||
@@ -2380,12 +2380,12 @@ UINT8 CountNumberOfMercMercsHired()
|
||||
UINT8 ubCount=0;
|
||||
|
||||
//loop through all of the hired mercs from M.E.R.C.
|
||||
for(i=0; i<NUMBER_OF_MERCS; i++)
|
||||
for(i=0; i<NUMBER_OF_MERCS; ++i)
|
||||
{
|
||||
ubMercID = GetMercIDFromMERCArray( i );
|
||||
if( IsMercOnTeam( ubMercID ) )
|
||||
if( IsMercOnTeam( ubMercID, FALSE, FALSE ) )
|
||||
{
|
||||
ubCount++;
|
||||
++ubCount;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2535,7 +2535,7 @@ void HandlePlayerHiringMerc( UINT8 ubHiredMercID )
|
||||
|
||||
// anv: Speck is hired
|
||||
case SPECK_PLAYABLE:
|
||||
if( IsMercOnTeam( VICKI ) )
|
||||
if( IsMercOnTeam( VICKI, FALSE, FALSE ) )
|
||||
StartSpeckTalking( SPECK_QUOTE_PLAYER_HIRES_SPECK_TOGETHER_WITH_VICKI );
|
||||
else
|
||||
StartSpeckTalking( SPECK_QUOTE_PLAYER_HIRES_SPECK );
|
||||
@@ -2618,7 +2618,7 @@ BOOLEAN ShouldSpeckStartTalkingDueToActionOnSubPage()
|
||||
BOOLEAN IsSpeckComAvailable() // anv: Prevent Speck from talking if his playable version is out of reach
|
||||
{
|
||||
//he's hired, travelling, dead or POW, he cant' talk
|
||||
if( ( ( IsMercOnTeam( SPECK_PLAYABLE )
|
||||
if( ( ( IsMercOnTeam( SPECK_PLAYABLE, FALSE, FALSE )
|
||||
|| gMercProfiles[ SPECK_PLAYABLE ].bMercStatus == MERC_IS_DEAD
|
||||
|| gMercProfiles[ SPECK_PLAYABLE ].bMercStatus == MERC_RETURNING_HOME
|
||||
|| gMercProfiles[ SPECK_PLAYABLE ].bMercStatus == MERC_FIRED_AS_A_POW ) )
|
||||
|
||||
@@ -529,7 +529,7 @@ BOOLEAN WillMercRenew( SOLDIERTYPE *pSoldier, BOOLEAN fSayQuote )
|
||||
continue;
|
||||
|
||||
// is this buddy on the team?
|
||||
if( IsMercOnTeamAndAlive( (UINT8) bMercID) )
|
||||
if( IsMercOnTeam( (UINT8) bMercID, FALSE, FALSE ) )
|
||||
{
|
||||
fBuddyAround = TRUE;
|
||||
|
||||
@@ -565,7 +565,7 @@ BOOLEAN WillMercRenew( SOLDIERTYPE *pSoldier, BOOLEAN fSayQuote )
|
||||
if( bMercID < 0 )
|
||||
continue;
|
||||
|
||||
if( IsMercOnTeamAndInOmertaAlreadyAndAlive( (UINT8) bMercID ) )
|
||||
if( IsMercOnTeam( (UINT8) bMercID, TRUE, TRUE ) )
|
||||
{
|
||||
if ( gMercProfiles[ pSoldier->ubProfile ].bHatedCount[ i ] == 0 )
|
||||
{
|
||||
@@ -609,7 +609,7 @@ BOOLEAN WillMercRenew( SOLDIERTYPE *pSoldier, BOOLEAN fSayQuote )
|
||||
|
||||
if ( bMercID >= 0 )
|
||||
{
|
||||
if ( IsMercOnTeamAndInOmertaAlreadyAndAlive( (UINT8) bMercID ) )
|
||||
if ( IsMercOnTeam( (UINT8) bMercID, TRUE, TRUE ) )
|
||||
{
|
||||
if ( gMercProfiles[ pSoldier->ubProfile ].bLearnToHateCount == 0 )
|
||||
{
|
||||
|
||||
@@ -2586,7 +2586,8 @@ void InitManualMobileRestrictions()
|
||||
}
|
||||
|
||||
|
||||
extern BOOLEAN IsMercOnTeam(UINT8 ubMercID);
|
||||
extern BOOLEAN IsMercOnTeam(UINT8 ubMercID, BOOLEAN aAlreadyInCountry, BOOLEAN aAlive );
|
||||
|
||||
// @brief Calculates the contingent for mobile militia.
|
||||
// Calculates current active mobile militia and compares to variable maximum limit which can be altered by external data.
|
||||
// @param printMessage Set to TRUE to get a screenmessage telling the player which maximum is reached. No message is generated when the maximum is not yet reached (<=100).
|
||||
@@ -2650,7 +2651,7 @@ UINT8 GetMobileMilitiaQuota( BOOLEAN printMessage )
|
||||
UINT16 rebelStructSize = sizeof ( gProfilesRPC );
|
||||
for (UINT16 rebelPC = 0; rebelPC < rebelStructSize; rebelPC++)
|
||||
{
|
||||
if ( IsMercOnTeam ( gProfilesRPC[ rebelPC ].ProfilId ) ) iNumRebelsInPlayerTeam++;
|
||||
if ( IsMercOnTeam ( gProfilesRPC[ rebelPC ].ProfilId, FALSE, FALSE ) ) iNumRebelsInPlayerTeam++;
|
||||
}
|
||||
}
|
||||
//if ( IsMercOnTeam ( IRA ) ) iNumRebelsInPlayerTeam++;
|
||||
|
||||
@@ -412,7 +412,7 @@ void MercDailyUpdate()
|
||||
// WANNE: Only send mails from the original 1.13 merc, and not from the wildfire merc,
|
||||
// otherwise we get wrong mails cause of hardcoded Email.edt structure!!!!!
|
||||
UINT16 numOriginalProfiles = 255;
|
||||
for( cnt = 0; cnt < numOriginalProfiles; cnt++)
|
||||
for( cnt = 0; cnt < numOriginalProfiles; ++cnt)
|
||||
{
|
||||
pProfile = &(gMercProfiles[ cnt ]);
|
||||
|
||||
@@ -426,7 +426,7 @@ void MercDailyUpdate()
|
||||
pProfile->uiPrecedentQuoteSaid = 0;
|
||||
|
||||
// skip anyone currently on the player's team
|
||||
if ( IsMercOnTeam( (UINT8) cnt ))
|
||||
if ( IsMercOnTeam( (UINT8) cnt, FALSE, FALSE ))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -110,14 +110,14 @@ enum DialogQuoteIDs
|
||||
//70
|
||||
QUOTE_ENEMY_RETREATED,
|
||||
QUOTE_GOING_TO_AUTO_SLEEP,
|
||||
QUOTE_WORK_UP_AND_RETURNING_TO_ASSIGNMENT, // woke up from auto sleep, going back to wo
|
||||
QUOTE_WORK_UP_AND_RETURNING_TO_ASSIGNMENT, // woke up from auto sleep, going back to work
|
||||
QUOTE_ME_TOO, // me too quote, in agreement with whatever the merc previous said
|
||||
QUOTE_USELESS_ITEM,
|
||||
QUOTE_BOOBYTRAP_ITEM,
|
||||
QUOTE_SUSPICIOUS_GROUND,
|
||||
QUOTE_DROWNING,
|
||||
QUOTE_MERC_REACHED_DESTINATION,
|
||||
QUOTE_SPARE2,
|
||||
QUOTE_JA2UB_LAPTOP_FIXED, // JA2UB: played when the laptop is fixed
|
||||
|
||||
//80
|
||||
QUOTE_REPUTATION_REFUSAL, //80
|
||||
@@ -171,8 +171,8 @@ enum DialogQuoteIDs
|
||||
QUOTE_IMPATIENT_QUOTE,
|
||||
QUOTE_LENGTH_OF_CONTRACT,
|
||||
QUOTE_COMMENT_BEFORE_HANG_UP,
|
||||
QUOTE_PERSONALITY_BIAS_WITH_HATED_1,
|
||||
QUOTE_PERSONALITY_BIAS_WITH_HATED_2,
|
||||
QUOTE_HATED_1_ON_TEAM_LONGTIMETOHATE, // played when we refuse to be hired because hated person is present and hatetime >= 24 (else play QUOTE_HATED_1_ON_TEAM)
|
||||
QUOTE_HATED_2_ON_TEAM_LONGTIMETOHATE,
|
||||
QUOTE_MERC_LEAVING_ALSUCO_SOON,
|
||||
QUOTE_MERC_GONE_UP_IN_PRICE,
|
||||
#ifdef JA2UB
|
||||
@@ -210,9 +210,9 @@ enum DialogQuoteIDs
|
||||
QUOTE_RENEWING_CAUSE_BUDDY_3_ON_TEAM,
|
||||
QUOTE_RENEWING_CAUSE_BUDDY_4_ON_TEAM,
|
||||
QUOTE_RENEWING_CAUSE_BUDDY_5_ON_TEAM,
|
||||
QUOTE_PERSONALITY_BIAS_WITH_HATED_3,
|
||||
QUOTE_PERSONALITY_BIAS_WITH_HATED_4,
|
||||
QUOTE_PERSONALITY_BIAS_WITH_HATED_5,
|
||||
QUOTE_HATED_3_ON_TEAM_LONGTIMETOHATE,
|
||||
QUOTE_HATED_4_ON_TEAM_LONGTIMETOHATE,
|
||||
QUOTE_HATED_5_ON_TEAM_LONGTIMETOHATE,
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -889,7 +889,7 @@ void HandlePowerGenAlarm()
|
||||
|
||||
if( bID != -1 )
|
||||
{
|
||||
TacticalCharacterDialogue( &Menptr[ bID ], QUOTE_PERSONALITY_BIAS_WITH_HATED_2 );
|
||||
TacticalCharacterDialogue( &Menptr[ bID ], QUOTE_HATED_2_ON_TEAM_LONGTIMETOHATE );
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -899,15 +899,15 @@ void HandlePowerGenAlarm()
|
||||
|
||||
if( bSoldierId1 != -1 && Menptr[ bSoldierId1 ].ubProfile != BIGGENS_UB ) //BIGGENS
|
||||
{
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierId1 ], QUOTE_PERSONALITY_BIAS_WITH_HATED_1 );
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierId1 ], QUOTE_HATED_1_ON_TEAM_LONGTIMETOHATE );
|
||||
}
|
||||
else if( bSoldierId2 != -1 && Menptr[ bSoldierId2 ].ubProfile != BIGGENS_UB ) //BIGGENS
|
||||
{
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierId2 ], QUOTE_PERSONALITY_BIAS_WITH_HATED_1 );
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierId2 ], QUOTE_HATED_1_ON_TEAM_LONGTIMETOHATE );
|
||||
}
|
||||
else if( bSoldierId3 != -1 && Menptr[ bSoldierId3 ].ubProfile != BIGGENS_UB ) // BIGGENS
|
||||
{
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierId3 ], QUOTE_PERSONALITY_BIAS_WITH_HATED_1 );
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierId3 ], QUOTE_HATED_1_ON_TEAM_LONGTIMETOHATE );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1186,7 +1186,7 @@ BOOLEAN ExitShopKeeperInterface()
|
||||
bSoldierID = RandomSoldierIdFromNewMercsOnPlayerTeam();
|
||||
if( bSoldierID != -1 )
|
||||
{
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierID ], QUOTE_SPARE2 );
|
||||
TacticalCharacterDialogue( &Menptr[ bSoldierID ], QUOTE_JA2UB_LAPTOP_FIXED );
|
||||
}
|
||||
|
||||
gJa25SaveStruct.uiJa25GeneralFlags |= JA_GF__PLAYER_SAID_LAPTOP_FIXED_QUOTE;
|
||||
|
||||
@@ -1767,103 +1767,27 @@ void AddSoldierToSectorGridNo( SOLDIERTYPE *pSoldier, INT32 sGridNo, UINT8 ubDir
|
||||
|
||||
|
||||
// IsMercOnTeam() checks to see if the passed in Merc Profile ID is currently on the player's team
|
||||
BOOLEAN IsMercOnTeam(UINT8 ubMercID)
|
||||
BOOLEAN IsMercOnTeam(UINT8 ubMercID, BOOLEAN aAlreadyInCountry, BOOLEAN aAlive)
|
||||
{
|
||||
UINT16 cnt;
|
||||
UINT8 ubLastTeamID;
|
||||
SOLDIERTYPE *pTeamSoldier;
|
||||
|
||||
cnt = gTacticalStatus.Team[ OUR_TEAM ].bFirstID;
|
||||
|
||||
ubLastTeamID = gTacticalStatus.Team[ OUR_TEAM ].bLastID;
|
||||
|
||||
// look for all mercs on the same team,
|
||||
for ( pTeamSoldier = MercPtrs[ cnt ]; cnt <= ubLastTeamID; cnt++,pTeamSoldier++)
|
||||
for ( pTeamSoldier = MercPtrs[ cnt ]; cnt <= ubLastTeamID; ++cnt, pTeamSoldier++)
|
||||
{
|
||||
if ( pTeamSoldier->ubProfile == ubMercID )
|
||||
if ( pTeamSoldier->ubProfile == ubMercID && pTeamSoldier->bActive )
|
||||
{
|
||||
if( pTeamSoldier->bActive )
|
||||
return(TRUE);
|
||||
}
|
||||
}
|
||||
if ( aAlreadyInCountry && pTeamSoldier->bAssignment == IN_TRANSIT )
|
||||
continue;
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
if ( aAlive && pTeamSoldier->stats.bLife <= 0 )
|
||||
continue;
|
||||
|
||||
// ATE: Added this new function for contract renewals
|
||||
BOOLEAN IsMercOnTeamAndAlive(UINT8 ubMercID)
|
||||
{
|
||||
UINT16 cnt;
|
||||
UINT8 ubLastTeamID;
|
||||
SOLDIERTYPE *pTeamSoldier;
|
||||
|
||||
cnt = gTacticalStatus.Team[ OUR_TEAM ].bFirstID;
|
||||
|
||||
ubLastTeamID = gTacticalStatus.Team[ OUR_TEAM ].bLastID;
|
||||
|
||||
// look for all mercs on the same team,
|
||||
for ( pTeamSoldier = MercPtrs[ cnt ]; cnt <= ubLastTeamID; cnt++,pTeamSoldier++)
|
||||
{
|
||||
if ( pTeamSoldier->ubProfile == ubMercID )
|
||||
{
|
||||
if( pTeamSoldier->bActive )
|
||||
{
|
||||
if ( pTeamSoldier->stats.bLife > 0 )
|
||||
{
|
||||
return(TRUE);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
BOOLEAN IsMercOnTeamAndInOmertaAlready(UINT8 ubMercID)
|
||||
{
|
||||
UINT16 cnt;
|
||||
UINT8 ubLastTeamID;
|
||||
SOLDIERTYPE *pTeamSoldier;
|
||||
|
||||
cnt = gTacticalStatus.Team[ OUR_TEAM ].bFirstID;
|
||||
|
||||
ubLastTeamID = gTacticalStatus.Team[ OUR_TEAM ].bLastID;
|
||||
|
||||
// look for all mercs on the same team,
|
||||
for ( pTeamSoldier = MercPtrs[ cnt ]; cnt <= ubLastTeamID; cnt++,pTeamSoldier++)
|
||||
{
|
||||
if ( pTeamSoldier->ubProfile == ubMercID )
|
||||
{
|
||||
if ( pTeamSoldier->bActive && pTeamSoldier->bAssignment != IN_TRANSIT )
|
||||
return(TRUE);
|
||||
}
|
||||
}
|
||||
|
||||
return(FALSE);
|
||||
}
|
||||
|
||||
BOOLEAN IsMercOnTeamAndInOmertaAlreadyAndAlive(UINT8 ubMercID)
|
||||
{
|
||||
UINT16 cnt;
|
||||
UINT8 ubLastTeamID;
|
||||
SOLDIERTYPE *pTeamSoldier;
|
||||
|
||||
cnt = gTacticalStatus.Team[ OUR_TEAM ].bFirstID;
|
||||
|
||||
ubLastTeamID = gTacticalStatus.Team[ OUR_TEAM ].bLastID;
|
||||
|
||||
// look for all mercs on the same team,
|
||||
for ( pTeamSoldier = MercPtrs[ cnt ]; cnt <= ubLastTeamID; cnt++,pTeamSoldier++)
|
||||
{
|
||||
if ( pTeamSoldier->ubProfile == ubMercID )
|
||||
{
|
||||
if ( pTeamSoldier->bActive && pTeamSoldier->bAssignment != IN_TRANSIT )
|
||||
{
|
||||
if ( pTeamSoldier->stats.bLife > 0 )
|
||||
{
|
||||
return(TRUE);
|
||||
}
|
||||
}
|
||||
return( TRUE );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -37,13 +37,7 @@ BOOLEAN AddSoldierToSectorNoCalculateDirection( UINT8 ubID );
|
||||
BOOLEAN AddSoldierToSectorNoCalculateDirectionUseAnimation( UINT8 ubID, UINT16 usAnimState, UINT16 usAnimCode );
|
||||
|
||||
// IsMercOnTeam() checks to see if the passed in Merc Profile ID is currently on the player's team
|
||||
BOOLEAN IsMercOnTeam(UINT8 ubMercID);
|
||||
// requires non-intransit assignment, too
|
||||
BOOLEAN IsMercOnTeamAndInOmertaAlready(UINT8 ubMercID);
|
||||
// ATE: Added for contract renewals
|
||||
BOOLEAN IsMercOnTeamAndAlive(UINT8 ubMercID);
|
||||
// ATE: Added for contract renewals
|
||||
BOOLEAN IsMercOnTeamAndInOmertaAlreadyAndAlive(UINT8 ubMercID);
|
||||
BOOLEAN IsMercOnTeam( UINT8 ubMercID, BOOLEAN aAlreadyInCountry, BOOLEAN aAlive );
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -2300,7 +2300,7 @@ BOOLEAN DoesMercHaveABuddyOnTheTeam( UINT8 ubMercID )
|
||||
if( bBuddyID < 0 )
|
||||
continue;
|
||||
|
||||
if( IsMercOnTeam( bBuddyID ) )
|
||||
if( IsMercOnTeam( bBuddyID, FALSE, FALSE ) )
|
||||
{
|
||||
if( !IsMercDead( bBuddyID ) )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user