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

Method handler

eos/effects.py:35066–35086  ·  view source on GitHub ↗
(fit, container, context, projectionRange, **kwargs)

Source from the content-addressed store, hash-verified

35064
35065 @staticmethod
35066 def handler(fit, container, context, projectionRange, **kwargs):
35067 if 'projected' not in context:
35068 return
35069 if fit.ship.getModifiedItemAttr('disallowAssistance'):
35070 return
35071 repAmountBase = container.getModifiedItemAttr('armorDamageAmount')
35072 repAmountBase *= calculateRangeFactor(
35073 srcOptimalRange=container.getModifiedItemAttr('maxRange'),
35074 srcFalloffRange=container.getModifiedItemAttr('falloffEffectiveness'),
35075 distance=projectionRange)
35076 cycleTime = container.getModifiedItemAttr('duration') / 1000.0
35077 repSpoolMax = container.getModifiedItemAttr('repairMultiplierBonusMax')
35078 repSpoolPerCycle = container.getModifiedItemAttr('repairMultiplierBonusPerCycle')
35079 defaultSpoolValue = eos.config.settings['globalDefaultSpoolupPercentage']
35080 spoolType, spoolAmount = resolveSpoolOptions(SpoolOptions(SpoolType.SPOOL_SCALE, defaultSpoolValue, False), container)
35081 amount = repAmountBase * (1 + calculateSpoolup(repSpoolMax, repSpoolPerCycle, cycleTime, spoolType, spoolAmount)[0])
35082 amountPreSpool = repAmountBase * (1 + calculateSpoolup(repSpoolMax, repSpoolPerCycle, cycleTime, SpoolType.SPOOL_SCALE, 0)[0])
35083 amountFullSpool = repAmountBase * (1 + calculateSpoolup(repSpoolMax, repSpoolPerCycle, cycleTime, SpoolType.SPOOL_SCALE, 1)[0])
35084 fit._armorRr.append((amount, cycleTime))
35085 fit._armorRrPreSpool.append((amountPreSpool, cycleTime))
35086 fit._armorRrFullSpool.append((amountFullSpool, cycleTime))
35087
35088
35089class Effect7167(BaseEffect):

Callers

nothing calls this directly

Calls 5

calculateRangeFactorFunction · 0.90
resolveSpoolOptionsFunction · 0.90
calculateSpoolupFunction · 0.90
getModifiedItemAttrMethod · 0.45
appendMethod · 0.45

Tested by

no test coverage detected