Update 1030624
This commit is contained in:
18
eos/effects/fighterabilityecm.py
Normal file
18
eos/effects/fighterabilityecm.py
Normal file
@@ -0,0 +1,18 @@
|
||||
"""
|
||||
Since fighter abilities do not have any sort of item entity in the EVE database, we must derive the abilities from the
|
||||
effects, and thus this effect file contains some custom information useful only to fighters.
|
||||
"""
|
||||
from eos.types import State
|
||||
|
||||
# User-friendly name for the ability
|
||||
displayName = "ECM"
|
||||
|
||||
prefix = "fighterAbilityECM"
|
||||
|
||||
type = "projected", "active"
|
||||
def handler(fit, module, context):
|
||||
if "projected" not in context: return
|
||||
# jam formula: 1 - (1- (jammer str/ship str))^(# of jam mods with same str))
|
||||
strModifier = 1 - module.getModifiedItemAttr("{}Srength{}".format(prefix, fit.scanType))/fit.scanStrength
|
||||
|
||||
fit.ecmProjectedStr *= strModifier
|
||||
19
eos/effects/fighterabilityenergyneutralizer.py
Normal file
19
eos/effects/fighterabilityenergyneutralizer.py
Normal file
@@ -0,0 +1,19 @@
|
||||
"""
|
||||
Since fighter abilities do not have any sort of item entity in the EVE database, we must derive the abilities from the
|
||||
effects, and thus this effect file contains some custom information useful only to fighters.
|
||||
"""
|
||||
from eos.types import State
|
||||
|
||||
# User-friendly name for the ability
|
||||
displayName = "Energy Neutralizer"
|
||||
|
||||
prefix = "fighterAbilityEnergyNeutralizer"
|
||||
|
||||
type = "active", "projected"
|
||||
|
||||
def handler(fit, container, context):
|
||||
if "projected" in context and ((hasattr(container, "state") and container.state >= State.ACTIVE) or hasattr(container, "amountActive")):
|
||||
multiplier = container.amountActive if hasattr(container, "amountActive") else 1
|
||||
amount = container.getModifiedItemAttr("{}Amount".format(prefix))
|
||||
time = container.getModifiedItemAttr("{}Duration".format(prefix))
|
||||
fit.addDrain(time, amount * multiplier, 0)
|
||||
17
eos/effects/fighterabilitystasiswebifier.py
Normal file
17
eos/effects/fighterabilitystasiswebifier.py
Normal file
@@ -0,0 +1,17 @@
|
||||
"""
|
||||
Since fighter abilities do not have any sort of item entity in the EVE database, we must derive the abilities from the
|
||||
effects, and thus this effect file contains some custom information useful only to fighters.
|
||||
"""
|
||||
from eos.types import State
|
||||
|
||||
# User-friendly name for the ability
|
||||
displayName = "Stasis Webifier"
|
||||
|
||||
prefix = "fighterAbilityStasisWebifier"
|
||||
|
||||
type = "active", "projected"
|
||||
|
||||
def handler(fit, src, context):
|
||||
if "projected" not in context: return
|
||||
multiplier = src.amountActive if hasattr(src, "amountActive") else 1
|
||||
fit.ship.boostItemAttr("maxVelocity", src.getModifiedItemAttr("{}SpeedPenalty") * multiplier)
|
||||
16
eos/effects/fighterabilitywarpdisruption.py
Normal file
16
eos/effects/fighterabilitywarpdisruption.py
Normal file
@@ -0,0 +1,16 @@
|
||||
"""
|
||||
Since fighter abilities do not have any sort of item entity in the EVE database, we must derive the abilities from the
|
||||
effects, and thus this effect file contains some custom information useful only to fighters.
|
||||
"""
|
||||
from eos.types import State
|
||||
|
||||
# User-friendly name for the ability
|
||||
displayName = "Warp Disruption"
|
||||
|
||||
prefix = "fighterAbilityWarpDisruption"
|
||||
|
||||
type = "active", "projected"
|
||||
|
||||
def handler(fit, src, context):
|
||||
if "projected" not in context: return
|
||||
fit.ship.increaseItemAttr("warpScrambleStatus", src.getModifiedItemAttr("{}PointStrength".format(prefix)))
|
||||
Reference in New Issue
Block a user