WeatherEffectsExtension - AndroidQuazar/VanillaExpandedFramework GitHub Wiki
This DefModExtension can be added to weather defs, in their <modExtensions>
tag. You also need to add <li>WeatherOverlay_Effects</li>
to <overlayClasses>
.
Here is an example:
<li Class="VFECore.WeatherEffectsExtension">
<ticksInterval>1000</ticksInterval> <!-- Do effects ticks interval -->
<hediffsToApply> <!-- Hediffs added to pawns -->
<li>
<hediff>ToxicBuildup</hediff> <!-- Hediff defName -->
<severityOffset>0.010</severityOffset> <!-- Initial and added severity to hediffs -->
<effectMultiplyingStat>ToxicSensitivity</effectMultiplyingStat> <!-- Stat taken into account for severity -->
</li>
</hediffsToApply>
<causesRotting>True</causesRotting> <!-- Should it rot things -->
<rotProgressPerDamage>3000</rotProgressPerDamage> <!-- Rotting progress per hit-->
<killingPlants>false</killingPlants> <!-- Should it kill plants -->
<chanceToKillPlants>0.0065</chanceToKillPlants> <!-- Chance to kill plants -->
<activeOnWeatherPerceived>RG-W_ToxicRain</activeOnWeatherPerceived> <!-- Only active when this weather is visible on the screen -->
<worksOnNonFleshPawns>false</worksOnNonFleshPawns> <!-- Set it to true if you want to affect non-flesh pawns such as mechanoids -->
</li>
<li Class="VFECore.WeatherEffectsExtension">
<ticksInterval>300~600</ticksInterval> <!-- Can also accept range, so it will work every 300-600 ticks randomly -->
<damageToApply>Blunt</damageToApply> <!-- Damage def to deal -->
<damageRange>0.1~0.5</damageRange> <!-- Damage range to deal -->
<percentOfPawnsToDealDamage>0.1</percentOfPawnsToDealDamage> <!-- Percent of pawns on the map to take damage. 0.1 will take random 10% of all pawns to deal damage -->
<activeOnWeatherPerceived>RG_Hail</activeOnWeatherPerceived> <!-- Only active when this weather is visible on the screen -->
</li>