MCPcopy Index your code
hub / github.com/pyfa-org/Pyfa / handler

Method handler

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

Source from the content-addressed store, hash-verified

27269
27270 @staticmethod
27271 def handler(fit, module, context, projectionRange, **kwargs):
27272 if 'projected' not in context:
27273 return
27274 if fit.ship.getModifiedItemAttr('disallowOffensiveModifiers'):
27275 return
27276 strength = module.getModifiedItemAttr('scan{0}StrengthBonus'.format(fit.scanType))
27277 strength *= calculateRangeFactor(
27278 srcOptimalRange=module.getModifiedItemAttr('maxRange'),
27279 srcFalloffRange=module.getModifiedItemAttr('falloffEffectiveness'),
27280 distance=projectionRange)
27281 if 'effect' in kwargs:
27282 from eos.modifiedAttributeDict import ModifiedAttributeDict
27283 strength *= ModifiedAttributeDict.getResistance(fit, kwargs['effect'])
27284 fit.addProjectedEcm(strength)
27285
27286
27287class Effect6472(BaseEffect):

Callers

nothing calls this directly

Calls 4

calculateRangeFactorFunction · 0.90
getResistanceMethod · 0.80
addProjectedEcmMethod · 0.80
getModifiedItemAttrMethod · 0.45

Tested by

no test coverage detected