mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
Remove unused function
This commit is contained in:
@@ -2948,89 +2948,6 @@ void EnemyCapturesPlayerSoldier( SOLDIERTYPE *pSoldier )
|
||||
}
|
||||
|
||||
|
||||
void HandleEnemyStatusInCurrentMapBeforeLoadingNewMap()
|
||||
{
|
||||
INT32 i;
|
||||
BOOLEAN fMadeCorpse;
|
||||
INT8 bKilledEnemies = 0, bKilledCreatures = 0, bKilledRebels = 0, bKilledCivilians = 0;
|
||||
return;
|
||||
//If any of the soldiers are dying, kill them now.
|
||||
for( i = gTacticalStatus.Team[ ENEMY_TEAM ].bFirstID; i <= gTacticalStatus.Team[ ENEMY_TEAM ].bLastID; i++ )
|
||||
{
|
||||
if( MercPtrs[ i ]->bActive && MercPtrs[ i ]->stats.bLife < OKLIFE && MercPtrs[ i ]->stats.bLife )
|
||||
{
|
||||
MercPtrs[ i ]->stats.bLife = 0;
|
||||
MercPtrs[ i ]->iHealableInjury = 0; // added just for sure - SANDRO
|
||||
HandleSoldierDeath( MercPtrs[ i ], &fMadeCorpse );
|
||||
bKilledEnemies++;
|
||||
}
|
||||
}
|
||||
//Do the same for the creatures.
|
||||
for( i = gTacticalStatus.Team[ CREATURE_TEAM ].bFirstID; i <= gTacticalStatus.Team[ CREATURE_TEAM ].bLastID; i++ )
|
||||
{
|
||||
if( MercPtrs[ i ]->bActive && MercPtrs[ i ]->stats.bLife < OKLIFE && MercPtrs[ i ]->stats.bLife )
|
||||
{
|
||||
MercPtrs[ i ]->stats.bLife = 0;
|
||||
HandleSoldierDeath( MercPtrs[ i ], &fMadeCorpse );
|
||||
bKilledCreatures++;
|
||||
}
|
||||
}
|
||||
//Militia
|
||||
for( i = gTacticalStatus.Team[ MILITIA_TEAM ].bFirstID; i <= gTacticalStatus.Team[ MILITIA_TEAM ].bLastID; i++ )
|
||||
{
|
||||
if( MercPtrs[ i ]->bActive && MercPtrs[ i ]->stats.bLife < OKLIFE && MercPtrs[ i ]->stats.bLife )
|
||||
{
|
||||
MercPtrs[ i ]->stats.bLife = 0;
|
||||
MercPtrs[ i ]->iHealableInjury = 0; // added just for sure - SANDRO
|
||||
HandleSoldierDeath( MercPtrs[ i ], &fMadeCorpse );
|
||||
bKilledRebels++;
|
||||
}
|
||||
}
|
||||
//Civilians
|
||||
for( i = gTacticalStatus.Team[ CIV_TEAM ].bFirstID; i <= gTacticalStatus.Team[ CIV_TEAM ].bLastID; i++ )
|
||||
{
|
||||
if( MercPtrs[ i ]->bActive && MercPtrs[ i ]->stats.bLife < OKLIFE && MercPtrs[ i ]->stats.bLife )
|
||||
{
|
||||
MercPtrs[ i ]->stats.bLife = 0;
|
||||
MercPtrs[ i ]->iHealableInjury = 0; // added just for sure - SANDRO
|
||||
HandleSoldierDeath( MercPtrs[ i ], &fMadeCorpse );
|
||||
bKilledCivilians++;
|
||||
}
|
||||
}
|
||||
|
||||
// TEST MESSAGES ONLY!
|
||||
if( bKilledCivilians )
|
||||
ScreenMsg( FONT_BLUE, MSG_TESTVERSION, L"%d civilians died after you left the sector.", bKilledCivilians );
|
||||
if( bKilledRebels )
|
||||
ScreenMsg( FONT_BLUE, MSG_TESTVERSION, L"%d militia died after you left the sector.", bKilledRebels );
|
||||
if( bKilledEnemies )
|
||||
ScreenMsg( FONT_BLUE, MSG_TESTVERSION, L"%d enemies died after you left the sector.", bKilledEnemies );
|
||||
if( bKilledCreatures )
|
||||
ScreenMsg( FONT_BLUE, MSG_TESTVERSION, L"%d creatures died after you left the sector.", bKilledCreatures );
|
||||
|
||||
if( !gbWorldSectorZ )
|
||||
{
|
||||
SECTORINFO *pSector;
|
||||
pSector = &SectorInfo[ SECTOR(gWorldSectorX, gWorldSectorY) ];
|
||||
pSector->ubAdminsInBattle = 0;
|
||||
pSector->ubTroopsInBattle = 0;
|
||||
pSector->ubElitesInBattle = 0;
|
||||
pSector->ubCreaturesInBattle = 0;
|
||||
//RecalculateSectorWeight(
|
||||
}
|
||||
else if( gbWorldSectorZ > 0 )
|
||||
{
|
||||
UNDERGROUND_SECTORINFO *pSector;
|
||||
pSector = FindUnderGroundSector( gWorldSectorX, gWorldSectorY, gbWorldSectorZ );
|
||||
if( !pSector )
|
||||
return;
|
||||
pSector->ubAdminsInBattle = 0;
|
||||
pSector->ubTroopsInBattle = 0;
|
||||
pSector->ubElitesInBattle = 0;
|
||||
pSector->ubCreaturesInBattle = 0;
|
||||
}
|
||||
}
|
||||
|
||||
BOOLEAN PlayerSectorDefended( UINT8 ubSectorID )
|
||||
{
|
||||
if ( NumNonPlayerTeamMembersInSector( SECTORX( ubSectorID ), SECTORY( ubSectorID ), MILITIA_TEAM ) )
|
||||
|
||||
Reference in New Issue
Block a user