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

Function getLauncherMult

graphs/data/fitDamageStats/calc/application.py:177–195  ·  view source on GitHub ↗
(mod, distance, tgtSpeed, tgtSigRadius)

Source from the content-addressed store, hash-verified

175
176
177def getLauncherMult(mod, distance, tgtSpeed, tgtSigRadius):
178 missileMaxRangeData = mod.missileMaxRangeData
179 if missileMaxRangeData is None:
180 return 0
181 # The ranges already consider ship radius
182 lowerRange, higherRange, higherChance = missileMaxRangeData
183 if distance is None or distance <= lowerRange:
184 distanceFactor = 1
185 elif lowerRange < distance <= higherRange:
186 distanceFactor = higherChance
187 else:
188 distanceFactor = 0
189 applicationFactor = _calcMissileFactor(
190 atkEr=mod.getModifiedChargeAttr('aoeCloudSize'),
191 atkEv=mod.getModifiedChargeAttr('aoeVelocity'),
192 atkDrf=mod.getModifiedChargeAttr('aoeDamageReductionFactor'),
193 tgtSpeed=tgtSpeed,
194 tgtSigRadius=tgtSigRadius)
195 return distanceFactor * applicationFactor
196
197
198def getBreacherMult(mod, distance):

Callers 1

getApplicationPerKeyFunction · 0.85

Calls 2

_calcMissileFactorFunction · 0.85
getModifiedChargeAttrMethod · 0.80

Tested by

no test coverage detected