mirror of
https://github.com/1dot13/source.git
synced 2026-08-05 14:00:23 +02:00
Fix: mouse position was not restored after a message box was closed
Modified the Ranger trait to make it more useful after loosing all survival bonuses: - aim click bonus for shotguns is now again 1 (hunter) or 2 (ranger) - new aim click bonus for rifles that is half the shotgun bonus. With the default value of "1" this means 0 for hunter and 1 for ranger. This does NOT stack with the sniper bonus! It's one or the other depending on which is higher. - new speed bonus to reloading single shells into shotguns - new range bonus for shotguns of 10% (hunter) or 20% (ranger) EDB now displays the trait modified values for: - Gun Range - Draw Cost git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7761 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -963,14 +963,21 @@ UINT16 GunRange( OBJECTTYPE * pObj, SOLDIERTYPE * pSoldier ) // SANDRO - added a
|
||||
rng = (usRange * GetPercentRangeBonus(pObj))/10000;
|
||||
rng += GetRangeBonus(pObj);
|
||||
|
||||
// SANDRO - STOMP traits - Gunslinger bonus range with pistols
|
||||
// SANDRO - STOMP traits
|
||||
if ( pSoldier != NULL && Item[ pObj->usItem ].usItemClass & IC_GUN )
|
||||
{
|
||||
// Gunslinger bonus range with pistols
|
||||
if ((Weapon[ pObj->usItem ].ubWeaponType == GUN_PISTOL || Weapon[ pObj->usItem ].ubWeaponType == GUN_M_PISTOL) &&
|
||||
gGameOptions.fNewTraitSystem && HAS_SKILL_TRAIT( pSoldier, GUNSLINGER_NT ) )
|
||||
{
|
||||
rng += (rng * gSkillTraitValues.ubGSEffectiveRangeBonusPistols * NUM_SKILL_TRAITS( pSoldier, GUNSLINGER_NT ) / 100 );
|
||||
}
|
||||
// Ranger bonus range with shotguns
|
||||
else if ( Weapon[ pObj->usItem ].ubWeaponType == GUN_SHOTGUN &&
|
||||
gGameOptions.fNewTraitSystem && HAS_SKILL_TRAIT( pSoldier, RANGER_NT ) )
|
||||
{
|
||||
rng += (rng * gSkillTraitValues.ubRAEffectiveRangeBonusShotguns * NUM_SKILL_TRAITS( pSoldier, RANGER_NT ) / 100 );
|
||||
}
|
||||
}
|
||||
|
||||
return rng;
|
||||
|
||||
Reference in New Issue
Block a user