mirror of
https://github.com/1dot13/source.git
synced 2026-07-29 13:52:17 +02:00
new feature: madlab's robot can be upgraded
requires gamedir r2642 https://thepit.ja-galaxy-forum.com/index.php?t=msg&goto=364403 git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9338 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -50,6 +50,14 @@ INT16 EffectiveStrength( SOLDIERTYPE *pSoldier, BOOLEAN fTrainer )
|
||||
iEffStrength = 0;
|
||||
}
|
||||
|
||||
if (AM_A_ROBOT(pSoldier))
|
||||
{
|
||||
if (Item[pSoldier->inv[ROBOT_CHASSIS_SLOT].usItem].bRobotStrBonus > 0)
|
||||
{
|
||||
iEffStrength += Item[pSoldier->inv[ROBOT_CHASSIS_SLOT].usItem].bRobotStrBonus;
|
||||
}
|
||||
}
|
||||
|
||||
// Flugente: diseases can affect stat effectivity
|
||||
INT16 diseaseeffect = 0;
|
||||
if ( gGameExternalOptions.fDisease )
|
||||
@@ -93,6 +101,14 @@ INT16 EffectiveAgility( SOLDIERTYPE * pSoldier, BOOLEAN fTrainer )
|
||||
|
||||
iEffAgility = pSoldier->stats.bAgility;
|
||||
|
||||
if (AM_A_ROBOT(pSoldier))
|
||||
{
|
||||
if (Item[pSoldier->inv[ROBOT_CHASSIS_SLOT].usItem].bRobotAgiBonus > 0)
|
||||
{
|
||||
iEffAgility += Item[pSoldier->inv[ROBOT_CHASSIS_SLOT].usItem].bRobotAgiBonus;
|
||||
}
|
||||
}
|
||||
|
||||
if ( !fTrainer )
|
||||
iEffAgility += pSoldier->bExtraAgility;
|
||||
|
||||
@@ -266,6 +282,14 @@ INT16 EffectiveDexterity( SOLDIERTYPE * pSoldier, BOOLEAN fTrainer )
|
||||
|
||||
iEffDexterity = pSoldier->stats.bDexterity;
|
||||
|
||||
if (AM_A_ROBOT(pSoldier))
|
||||
{
|
||||
if (Item[pSoldier->inv[ROBOT_CHASSIS_SLOT].usItem].bRobotDexBonus > 0)
|
||||
{
|
||||
iEffDexterity += Item[pSoldier->inv[ROBOT_CHASSIS_SLOT].usItem].bRobotDexBonus;
|
||||
}
|
||||
}
|
||||
|
||||
if ( !fTrainer )
|
||||
iEffDexterity += pSoldier->bExtraDexterity;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user