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

Method __runProjectionEffects

eos/saveddata/fit.py:1129–1147  ·  view source on GitHub ↗

To support a simpler way of doing self projections (so that we don't have to make a copy of the fit and recalculate), this function was developed to be a common source of projected effect application.

(self, runTime, targetFit, projectionInfo)

Source from the content-addressed store, hash-verified

1127 pyfalog.debug('Done with fit calculation')
1128
1129 def __runProjectionEffects(self, runTime, targetFit, projectionInfo):
1130 """
1131 To support a simpler way of doing self projections (so that we don't have to make a copy of the fit and
1132 recalculate), this function was developed to be a common source of projected effect application.
1133 """
1134 for item in chain(self.drones, self.fighters):
1135 if item is not None:
1136 # apply effects onto target fit x amount of times
1137 for _ in range(projectionInfo.amount):
1138 targetFit.register(item, origin=self)
1139 item.calculateModifiedAttributes(
1140 targetFit, runTime, forceProjected=True,
1141 forcedProjRange=0)
1142 for mod in self.modules:
1143 for _ in range(projectionInfo.amount):
1144 targetFit.register(mod, origin=self)
1145 mod.calculateModifiedAttributes(
1146 targetFit, runTime, forceProjected=True,
1147 forcedProjRange=projectionInfo.projectionRange)
1148
1149 def fill(self):
1150 """

Callers 1

Calls 2

registerMethod · 0.45

Tested by

no test coverage detected