Add tooltip for neut resist. Add handling missing attributes in getting modified value (return default, not exception). Tox fixes to clean up a little.
This commit is contained in:
@@ -16,4 +16,3 @@ settings = {
|
||||
|
||||
# Autodetect path, only change if the autodetection bugs out.
|
||||
path = dirname(unicode(__file__, sys.getfilesystemencoding()))
|
||||
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
#
|
||||
# Used by:
|
||||
# Modules from group: Tractor Beam (4 of 4)
|
||||
type = "active"
|
||||
from eos.config import settings
|
||||
type = "active"
|
||||
|
||||
|
||||
def handler(fit, module, context):
|
||||
print settings['setting1']
|
||||
|
||||
@@ -26,17 +26,23 @@ cappingAttrKeyCache = {}
|
||||
|
||||
class ItemAttrShortcut(object):
|
||||
def getModifiedItemAttr(self, key, default=None):
|
||||
if key in self.itemModifiedAttributes:
|
||||
return self.itemModifiedAttributes[key]
|
||||
else:
|
||||
try:
|
||||
if key in self.itemModifiedAttributes:
|
||||
return self.itemModifiedAttributes[key]
|
||||
else:
|
||||
return default
|
||||
except AttributeError:
|
||||
return default
|
||||
|
||||
|
||||
class ChargeAttrShortcut(object):
|
||||
def getModifiedChargeAttr(self, key, default=None):
|
||||
if key in self.chargeModifiedAttributes:
|
||||
return self.chargeModifiedAttributes[key]
|
||||
else:
|
||||
try:
|
||||
if key in self.chargeModifiedAttributes:
|
||||
return self.chargeModifiedAttributes[key]
|
||||
else:
|
||||
return default
|
||||
except AttributeError:
|
||||
return default
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user