mirror of
https://github.com/1dot13/source.git
synced 2026-08-12 14:10:23 +02:00
New Trait: SURVIVAL (new minor trait) gets the non-weapon parts of the ranger trait.
Requires GameDir >= r2213. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@7756 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -349,9 +349,9 @@ INT16 AdjustMaxSightRangeForEnvEffects( SOLDIERTYPE *pSoldier, INT8 bLightLevel,
|
||||
//Added a feature reducing weather penalty for ranger trait - SANDRO
|
||||
INT16 sWeatherPenalty = 0; // percent vision reduction 0-100%
|
||||
sWeatherPenalty = min( (max( 0, (gGameExternalOptions.ubVisDistDecreasePerRainIntensity * gbCurrentRainIntensity))), 100) ;
|
||||
if( gGameOptions.fNewTraitSystem && HAS_SKILL_TRAIT( pSoldier, RANGER_NT ) )
|
||||
if ( gGameOptions.fNewTraitSystem && HAS_SKILL_TRAIT( pSoldier, SURVIVAL_NT ) )
|
||||
{
|
||||
sWeatherPenalty = (sWeatherPenalty * ( 100 - (gSkillTraitValues.ubRAWeatherPenaltiesReduction * NUM_SKILL_TRAITS( pSoldier, RANGER_NT ))) ) / 100;
|
||||
sWeatherPenalty = (sWeatherPenalty * (100 - (gSkillTraitValues.ubSVWeatherPenaltiesReduction * NUM_SKILL_TRAITS( pSoldier, SURVIVAL_NT )))) / 100;
|
||||
sWeatherPenalty = min( (max( 0, sWeatherPenalty)), 100 ); // keep it in 0-100 range
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user