Merge pull request #740 from Ebag333/ECM-Burst-Effect

Implementing ECM Burst Jammer as a projected effect
This commit is contained in:
Ryan Holmes
2016-09-27 00:35:26 -04:00
committed by GitHub

View File

@@ -1,5 +1,9 @@
# Used by:
# Modules from group: Burst Jammer (11 of 11)
type = "active"
type = "projected", "active"
def handler(fit, module, context):
pass
if "projected" in context:
# jam formula: 1 - (1- (jammer str/ship str))^(# of jam mods with same str))
strModifier = 1 - module.getModifiedItemAttr("scan{0}StrengthBonus".format(fit.scanType))/fit.scanStrength
fit.ecmProjectedStr *= strModifier