mirror of
https://github.com/1dot13/source.git
synced 2026-08-12 14:10:23 +02:00
Convert to SoldierID
This commit is contained in:
+1
-1
@@ -1091,7 +1091,7 @@ void EnemyHeliSAMCheck( INT16 id )
|
||||
// also check whether this sector is not enemy-controlled - we can't have the AI shooting at its own helis
|
||||
if ( pSAMStrategicMap && !pSAMStrategicMap->fEnemyControlled )
|
||||
{
|
||||
UINT16 ubBestSAMOperatorID = NOBODY;
|
||||
SoldierID ubBestSAMOperatorID = NOBODY;
|
||||
FLOAT samcth = GetBestSAMOperatorCTH_Player( gpSamSectorX[i], gpSamSectorY[i], 0, &ubBestSAMOperatorID );
|
||||
|
||||
// cth is reduced if SAM is damaged, even if it can still operate
|
||||
|
||||
@@ -3776,7 +3776,7 @@ UINT32 CalculateSnitchInterrogationValue(SOLDIERTYPE *pSoldier, UINT16 *pusMaxPt
|
||||
}
|
||||
|
||||
// Flugente: Determine the best cth with SAMs in a sector, and which merc has that cth if present
|
||||
FLOAT GetBestSAMOperatorCTH_Player( INT16 sSectorX, INT16 sSectorY, INT16 sSectorZ, UINT16 *pubID )
|
||||
FLOAT GetBestSAMOperatorCTH_Player( INT16 sSectorX, INT16 sSectorY, INT16 sSectorZ, SoldierID *pubID )
|
||||
{
|
||||
// if nobody is here, nobody can fire
|
||||
FLOAT bestsamcth = 0.0f;
|
||||
|
||||
@@ -318,7 +318,7 @@ UINT32 CalculatePrisonGuardValue(SOLDIERTYPE *pSoldier );
|
||||
UINT32 CalculateSnitchInterrogationValue(SOLDIERTYPE *pSoldier, UINT16 *pusMaxPts );
|
||||
|
||||
// Flugente: Determine the best cth with SAMs in a sector, and which merc has that cth if present
|
||||
FLOAT GetBestSAMOperatorCTH_Player( INT16 sSectorX, INT16 sSectorY, INT16 sSectorZ, UINT16 *pubID );
|
||||
FLOAT GetBestSAMOperatorCTH_Player( INT16 sSectorX, INT16 sSectorY, INT16 sSectorZ, SoldierID *pubID );
|
||||
|
||||
INT16 GetTrainWorkerPts(SOLDIERTYPE *pSoldier);
|
||||
|
||||
@@ -592,4 +592,4 @@ UINT8 CalcSoldierNeedForSleep( SOLDIERTYPE *pSoldier );
|
||||
// Flugente: administration assignment
|
||||
FLOAT GetAdministrationPercentage( INT16 sX, INT16 sY );
|
||||
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -3009,9 +3009,7 @@ void MercCellMouseClickCallback( MOUSE_REGION *reg, INT32 reason )
|
||||
|
||||
if( gpAR->pRobotCell )
|
||||
{ //if controller is retreating, make the robot retreat too.
|
||||
UINT16 ubRobotControllerID;
|
||||
|
||||
ubRobotControllerID = gpAR->pRobotCell->pSoldier->ubRobotRemoteHolderID;
|
||||
SoldierID ubRobotControllerID = gpAR->pRobotCell->pSoldier->ubRobotRemoteHolderID;
|
||||
|
||||
if( ubRobotControllerID == NOBODY )
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user