mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
Moved armed vehicle/robot in gas check into function
Originally placed in DecideAction(green/yellow/red/black) functions separately
This commit is contained in:
@@ -807,12 +807,6 @@ INT8 DecideActionGreen(SOLDIERTYPE *pSoldier)
|
||||
// check if standing in tear gas without a gas mask on, or in smoke
|
||||
bInGas = InGasOrSmoke( pSoldier, pSoldier->sGridNo );
|
||||
|
||||
// Flugente: tanks do not care about gas
|
||||
if ( ARMED_VEHICLE( pSoldier ) || ENEMYROBOT( pSoldier ) )
|
||||
{
|
||||
bInGas = FALSE;
|
||||
}
|
||||
|
||||
// if real-time, and not in the way, do nothing 90% of the time (for GUARDS!)
|
||||
// unless in water (could've started there), then we better swim to shore!
|
||||
|
||||
@@ -2589,12 +2583,6 @@ INT8 DecideActionRed(SOLDIERTYPE *pSoldier)
|
||||
// check if standing in tear gas without a gas mask on
|
||||
bInGas = InGasOrSmoke( pSoldier, pSoldier->sGridNo );
|
||||
|
||||
// Flugente: tanks do not care about gas
|
||||
if ( ARMED_VEHICLE( pSoldier ) || ENEMYROBOT( pSoldier ) )
|
||||
{
|
||||
bInGas = FALSE;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
// WHEN LEFT IN GAS, WEAR GAS MASK IF AVAILABLE AND NOT WORN
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
@@ -5042,12 +5030,6 @@ INT16 ubMinAPCost;
|
||||
// check if standing in tear gas without a gas mask on
|
||||
bInGas = InGasOrSmoke( pSoldier, pSoldier->sGridNo );
|
||||
|
||||
// Flugente: tanks do not care about gas
|
||||
if ( ARMED_VEHICLE( pSoldier ) || ENEMYROBOT( pSoldier ) )
|
||||
{
|
||||
bInGas = FALSE;
|
||||
}
|
||||
|
||||
// calculate our morale
|
||||
pSoldier->aiData.bAIMorale = CalcMorale(pSoldier);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user