Add Mode and separation to fitting list.
Todo: A few exceptions are thrown when trying to remove mode via double click, spawn context menu, move to a different position, etc. All simply because Mode is not a Module. Will need to add try-except blocks to cover these instances
This commit is contained in:
@@ -495,6 +495,10 @@ class Fit(object):
|
||||
Slot.RIG: "rigSlots",
|
||||
Slot.SUBSYSTEM: "maxSubSystems"}
|
||||
|
||||
if type == Slot.MODE:
|
||||
# Mode slot doesn't really exist, return default 0
|
||||
return 0
|
||||
|
||||
slotsUsed = self.getSlotsUsed(type, countDummies)
|
||||
totalSlots = self.ship.getModifiedItemAttr(slots[type]) or 0
|
||||
return int(totalSlots - slotsUsed)
|
||||
|
||||
@@ -36,6 +36,7 @@ class Slot(Enum):
|
||||
HIGH = 3
|
||||
RIG = 4
|
||||
SUBSYSTEM = 5
|
||||
MODE = 6 # not a real slot, need for pyfa display rack separation
|
||||
|
||||
class Hardpoint(Enum):
|
||||
NONE = 0
|
||||
|
||||
Reference in New Issue
Block a user