Have fits filter rigs by size

This commit is contained in:
2025-12-06 01:41:00 +01:00
parent 766d45dd17
commit f3a89157ca

View File

@@ -245,11 +245,17 @@ class ItemView(Display):
if slot is None:
continue
# Rigs don't use CPU/power, they use calibration - allow them through
# Rigs don't use CPU/power, they use calibration - check rig size compatibility
if slot == FittingSlot.RIG:
# Check if item can fit on the ship
if not fit.canFit(item):
continue
# Check rig size compatibility with ship
shipRigSize = fit.ship.getModifiedItemAttr("rigSize")
itemRigSize = item.attributes.get("rigSize")
if shipRigSize is not None and itemRigSize is not None:
if shipRigSize != itemRigSize.value:
continue
fittingItems.append(item)
continue