Restrict skills being applied to citadels. The effect must be of type "structure" for it to apply. Fix issue with agility
This commit is contained in:
@@ -89,7 +89,7 @@ class Effect(EqBase):
|
||||
The type of the effect, automaticly fetched from effects/<effectName>.py if the file exists.
|
||||
|
||||
Valid values are:
|
||||
"passive", "active", "projected", "gang"
|
||||
"passive", "active", "projected", "gang", "structure"
|
||||
|
||||
Each gives valuable information to eos about what type the module having
|
||||
the effect is. passive vs active gives eos clues about wether to module
|
||||
|
||||
@@ -24,6 +24,7 @@ from itertools import chain
|
||||
from eos.effectHandlerHelpers import HandledItem, HandledImplantBoosterList
|
||||
import eos.db
|
||||
import eos
|
||||
import eos.types
|
||||
import logging
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
@@ -329,8 +330,9 @@ class Skill(HandledItem):
|
||||
return
|
||||
|
||||
for effect in item.effects.itervalues():
|
||||
if effect.runTime == runTime and effect.isType("passive"):
|
||||
if effect.runTime == runTime and effect.isType("passive") and (not isinstance(fit.ship, eos.types.Citadel) or effect.isType("structure")):
|
||||
try:
|
||||
print "Running effect: ", self, fit, runTime, effect
|
||||
effect.handler(fit, self, ("skill",))
|
||||
except AttributeError:
|
||||
continue
|
||||
|
||||
@@ -334,7 +334,7 @@ class Fit(object):
|
||||
|
||||
@property
|
||||
def alignTime(self):
|
||||
agility = self.ship.getModifiedItemAttr("agility")
|
||||
agility = self.ship.getModifiedItemAttr("agility") or 0
|
||||
mass = self.ship.getModifiedItemAttr("mass")
|
||||
|
||||
return -log(0.25) * agility * mass / 1000000
|
||||
|
||||
Reference in New Issue
Block a user