Update 1030624

This commit is contained in:
blitzmann
2016-04-17 23:39:22 -04:00
parent af9a9c5698
commit c3db808b7c
5 changed files with 70 additions and 0 deletions

View 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

View 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)

View 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)

View 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)))

BIN
eve.db

Binary file not shown.