MCPcopy Create free account
hub / github.com/pyfa-org/Pyfa / handler

Method handler

eos/effects.py:26805–26822  ·  view source on GitHub ↗
(fit, module, context, projectionRange, **kwargs)

Source from the content-addressed store, hash-verified

26803
26804 @staticmethod
26805 def handler(fit, module, context, projectionRange, **kwargs):
26806 if 'projected' not in context:
26807 return
26808 if fit.ship.getModifiedItemAttr('disallowOffensiveModifiers'):
26809 return
26810 rangeFactor = calculateRangeFactor(
26811 srcOptimalRange=module.getModifiedItemAttr('maxRange'),
26812 srcFalloffRange=module.getModifiedItemAttr('falloffEffectiveness'),
26813 distance=projectionRange)
26814 for srcAttr, tgtAttr in (
26815 ('aoeCloudSizeBonus', 'aoeCloudSize'),
26816 ('aoeVelocityBonus', 'aoeVelocity'),
26817 ('missileVelocityBonus', 'maxVelocity'),
26818 ('explosionDelayBonus', 'explosionDelay')
26819 ):
26820 fit.modules.filteredChargeBoost(lambda mod: mod.charge.requiresSkill('Missile Launcher Operation'),
26821 tgtAttr, module.getModifiedItemAttr(srcAttr) * rangeFactor,
26822 stackingPenalties=True, **kwargs)
26823
26824
26825class Effect6424(BaseEffect):

Callers

nothing calls this directly

Calls 4

calculateRangeFactorFunction · 0.90
filteredChargeBoostMethod · 0.80
requiresSkillMethod · 0.80
getModifiedItemAttrMethod · 0.45

Tested by

no test coverage detected