From f423c67979acfb0ae3ff44715208b6d8db639b68 Mon Sep 17 00:00:00 2001 From: blitzmann Date: Mon, 23 May 2016 20:19:30 -0400 Subject: [PATCH] Fix remote ancillary bonus effects (#626) --- .../elitebonuslogisticremotearmorrepaircapneed1.py | 9 ++------- .../elitebonuslogisticremotearmorrepaircapneed2.py | 9 ++------- .../elitebonuslogisticshieldtransfercapneed1.py | 10 ++-------- .../elitebonuslogisticshieldtransfercapneed2.py | 9 ++------- eos/effects/remotearmorpowerneedbonuseffect.py | 10 ++-------- eos/effects/shieldtransportcpuneedbonuseffect.py | 9 ++------- eos/effects/shipbonusremotearmorrepairamount2af.py | 10 ++-------- eos/effects/shipbonusremotearmorrepairamountac2.py | 9 ++------- eos/effects/shipbonusremotearmorrepairamountgc2.py | 9 ++------- eos/effects/shipbonusremotearmorrepairamountgf2.py | 9 ++------- eos/effects/shipbonusremotearmorrepaircapneedac1.py | 9 ++------- eos/effects/shipbonusremotearmorrepaircapneedaf.py | 10 ++-------- eos/effects/shipbonusremotearmorrepaircapneedgc1.py | 9 ++------- eos/effects/shipbonusremotearmorrepaircapneedgf.py | 9 ++------- eos/effects/shipbonusshieldtransfercapneed1.py | 9 ++------- ...ystembonusamarrdefensive2remotearmorrepairamount.py | 2 +- ...uscaldaridefensive2remoteshieldtransporteramount.py | 2 +- ...embonusgallentedefensive2remotearmorrepairamount.py | 2 +- ...sminmatardefensive2remoteshieldtransporteramount.py | 2 +- 19 files changed, 34 insertions(+), 113 deletions(-) diff --git a/eos/effects/elitebonuslogisticremotearmorrepaircapneed1.py b/eos/effects/elitebonuslogisticremotearmorrepaircapneed1.py index 7f4e10117..3323288f1 100644 --- a/eos/effects/elitebonuslogisticremotearmorrepaircapneed1.py +++ b/eos/effects/elitebonuslogisticremotearmorrepaircapneed1.py @@ -1,8 +1,3 @@ -# eliteBonusLogisticRemoteArmorRepairCapNeed1 -# -# Used by: -# Ship: Oneiros type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "capacitorNeed", ship.getModifiedItemAttr("eliteBonusLogistics1"), skill="Logistics Cruisers") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "capacitorNeed", src.getModifiedItemAttr("eliteBonusLogistics1"), skill="Logistics Cruisers") diff --git a/eos/effects/elitebonuslogisticremotearmorrepaircapneed2.py b/eos/effects/elitebonuslogisticremotearmorrepaircapneed2.py index 7e39fddbb..8817d38dd 100644 --- a/eos/effects/elitebonuslogisticremotearmorrepaircapneed2.py +++ b/eos/effects/elitebonuslogisticremotearmorrepaircapneed2.py @@ -1,8 +1,3 @@ -# eliteBonusLogisticRemoteArmorRepairCapNeed2 -# -# Used by: -# Ship: Guardian type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "capacitorNeed", ship.getModifiedItemAttr("eliteBonusLogistics2"), skill="Logistics Cruisers") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "capacitorNeed", src.getModifiedItemAttr("eliteBonusLogistics2"), skill="Logistics Cruisers") diff --git a/eos/effects/elitebonuslogisticshieldtransfercapneed1.py b/eos/effects/elitebonuslogisticshieldtransfercapneed1.py index d0024995a..6e0bec64f 100644 --- a/eos/effects/elitebonuslogisticshieldtransfercapneed1.py +++ b/eos/effects/elitebonuslogisticshieldtransfercapneed1.py @@ -1,9 +1,3 @@ -# eliteBonusLogisticShieldTransferCapNeed1 -# -# Used by: -# Ship: Basilisk -# Ship: Etana type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Shield Booster", - "capacitorNeed", ship.getModifiedItemAttr("eliteBonusLogistics1"), skill="Logistics Cruisers") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Shield Emission Systems"), "capacitorNeed", src.getModifiedItemAttr("eliteBonusLogistics1"), skill="Logistics Cruisers") diff --git a/eos/effects/elitebonuslogisticshieldtransfercapneed2.py b/eos/effects/elitebonuslogisticshieldtransfercapneed2.py index 7e731892d..136cb4fc4 100644 --- a/eos/effects/elitebonuslogisticshieldtransfercapneed2.py +++ b/eos/effects/elitebonuslogisticshieldtransfercapneed2.py @@ -1,8 +1,3 @@ -# eliteBonusLogisticShieldTransferCapNeed2 -# -# Used by: -# Ship: Scimitar type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Shield Booster", - "capacitorNeed", ship.getModifiedItemAttr("eliteBonusLogistics2"), skill="Logistics Cruisers") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Shield Emission Systems"), "capacitorNeed", src.getModifiedItemAttr("eliteBonusLogistics2"), skill="Logistics Cruisers") diff --git a/eos/effects/remotearmorpowerneedbonuseffect.py b/eos/effects/remotearmorpowerneedbonuseffect.py index 48137cc6c..ac787d18b 100644 --- a/eos/effects/remotearmorpowerneedbonuseffect.py +++ b/eos/effects/remotearmorpowerneedbonuseffect.py @@ -1,9 +1,3 @@ -# remoteArmorPowerNeedBonusEffect -# -# Used by: -# Ship: Guardian -# Ship: Oneiros type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "power", ship.getModifiedItemAttr("remoteArmorPowerNeedBonus")) +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "power", src.getModifiedItemAttr("remoteArmorPowerNeedBonus")) diff --git a/eos/effects/shieldtransportcpuneedbonuseffect.py b/eos/effects/shieldtransportcpuneedbonuseffect.py index 8d40190cf..8ea54771c 100644 --- a/eos/effects/shieldtransportcpuneedbonuseffect.py +++ b/eos/effects/shieldtransportcpuneedbonuseffect.py @@ -1,8 +1,3 @@ -# shieldTransportCpuNeedBonusEffect -# -# Used by: -# Ships from group: Logistics (3 of 5) type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Shield Booster", - "cpu", ship.getModifiedItemAttr("shieldTransportCpuNeedBonus")) +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Shield Emission Systems"), "cpu", src.getModifiedItemAttr("shieldTransportCpuNeedBonus")) diff --git a/eos/effects/shipbonusremotearmorrepairamount2af.py b/eos/effects/shipbonusremotearmorrepairamount2af.py index dbabc1045..fc689f38f 100644 --- a/eos/effects/shipbonusremotearmorrepairamount2af.py +++ b/eos/effects/shipbonusremotearmorrepairamount2af.py @@ -1,9 +1,3 @@ -# shipBonusRemoteArmorRepairAmount2AF -# -# Used by: -# Ship: Deacon -# Ship: Inquisitor type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "armorDamageAmount", ship.getModifiedItemAttr("shipBonus2AF"), skill="Amarr Frigate") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "armorDamageAmount", src.getModifiedItemAttr("shipBonus2AF"), skill="Amarr Frigate") diff --git a/eos/effects/shipbonusremotearmorrepairamountac2.py b/eos/effects/shipbonusremotearmorrepairamountac2.py index 5d90469a3..1529e48fa 100644 --- a/eos/effects/shipbonusremotearmorrepairamountac2.py +++ b/eos/effects/shipbonusremotearmorrepairamountac2.py @@ -1,8 +1,3 @@ -# shipBonusRemoteArmorRepairAmountAC2 -# -# Used by: -# Ship: Augoror type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "armorDamageAmount", ship.getModifiedItemAttr("shipBonusAC2"), skill="Amarr Cruiser") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "armorDamageAmount", src.getModifiedItemAttr("shipBonusAC2"), skill="Amarr Cruiser") diff --git a/eos/effects/shipbonusremotearmorrepairamountgc2.py b/eos/effects/shipbonusremotearmorrepairamountgc2.py index fbd04f0b2..3a8e1d533 100644 --- a/eos/effects/shipbonusremotearmorrepairamountgc2.py +++ b/eos/effects/shipbonusremotearmorrepairamountgc2.py @@ -1,8 +1,3 @@ -# shipBonusRemoteArmorRepairAmountGC2 -# -# Used by: -# Ship: Exequror type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "armorDamageAmount", ship.getModifiedItemAttr("shipBonusGC2"), skill="Gallente Cruiser") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "armorDamageAmount", src.getModifiedItemAttr("shipBonusGC2"), skill="Gallente Cruiser") diff --git a/eos/effects/shipbonusremotearmorrepairamountgf2.py b/eos/effects/shipbonusremotearmorrepairamountgf2.py index 56bb2a1bb..6f7776451 100644 --- a/eos/effects/shipbonusremotearmorrepairamountgf2.py +++ b/eos/effects/shipbonusremotearmorrepairamountgf2.py @@ -1,8 +1,3 @@ -# shipBonusRemoteArmorRepairAmountGF2 -# -# Used by: -# Variations of ship: Navitas (2 of 2) type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "armorDamageAmount", ship.getModifiedItemAttr("shipBonusGF2"), skill="Gallente Frigate") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "armorDamageAmount", src.getModifiedItemAttr("shipBonusGF2"), skill="Gallente Frigate") diff --git a/eos/effects/shipbonusremotearmorrepaircapneedac1.py b/eos/effects/shipbonusremotearmorrepaircapneedac1.py index d93489454..5f7c04002 100644 --- a/eos/effects/shipbonusremotearmorrepaircapneedac1.py +++ b/eos/effects/shipbonusremotearmorrepaircapneedac1.py @@ -1,8 +1,3 @@ -# shipBonusRemoteArmorRepairCapNeedAC1 -# -# Used by: -# Ship: Augoror type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "capacitorNeed", ship.getModifiedItemAttr("shipBonusAC"), skill="Amarr Cruiser") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "capacitorNeed", src.getModifiedItemAttr("shipBonusAC"), skill="Amarr Cruiser") diff --git a/eos/effects/shipbonusremotearmorrepaircapneedaf.py b/eos/effects/shipbonusremotearmorrepaircapneedaf.py index b79927306..99d2e9705 100644 --- a/eos/effects/shipbonusremotearmorrepaircapneedaf.py +++ b/eos/effects/shipbonusremotearmorrepaircapneedaf.py @@ -1,9 +1,3 @@ -# shipBonusRemoteArmorRepairCapNeedAF -# -# Used by: -# Ship: Deacon -# Ship: Inquisitor type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "capacitorNeed", ship.getModifiedItemAttr("shipBonusAF"), skill="Amarr Frigate") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "capacitorNeed", src.getModifiedItemAttr("shipBonusAF"), skill="Amarr Frigate") diff --git a/eos/effects/shipbonusremotearmorrepaircapneedgc1.py b/eos/effects/shipbonusremotearmorrepaircapneedgc1.py index 022e51477..12900c3ab 100644 --- a/eos/effects/shipbonusremotearmorrepaircapneedgc1.py +++ b/eos/effects/shipbonusremotearmorrepaircapneedgc1.py @@ -1,8 +1,3 @@ -# shipBonusRemoteArmorRepairCapNeedGC1 -# -# Used by: -# Ship: Exequror type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "capacitorNeed", ship.getModifiedItemAttr("shipBonusGC"), skill="Gallente Cruiser") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "capacitorNeed", src.getModifiedItemAttr("shipBonusGC"), skill="Gallente Cruiser") diff --git a/eos/effects/shipbonusremotearmorrepaircapneedgf.py b/eos/effects/shipbonusremotearmorrepaircapneedgf.py index f081267cf..9f9f19386 100644 --- a/eos/effects/shipbonusremotearmorrepaircapneedgf.py +++ b/eos/effects/shipbonusremotearmorrepaircapneedgf.py @@ -1,8 +1,3 @@ -# shipBonusRemoteArmorRepairCapNeedGF -# -# Used by: -# Variations of ship: Navitas (2 of 2) type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", - "capacitorNeed", ship.getModifiedItemAttr("shipBonusGF"), skill="Gallente Frigate") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "capacitorNeed", src.getModifiedItemAttr("shipBonusGF"), skill="Gallente Frigate") diff --git a/eos/effects/shipbonusshieldtransfercapneed1.py b/eos/effects/shipbonusshieldtransfercapneed1.py index 922d3804f..982fd8478 100644 --- a/eos/effects/shipbonusshieldtransfercapneed1.py +++ b/eos/effects/shipbonusshieldtransfercapneed1.py @@ -1,8 +1,3 @@ -# shipBonusShieldTransferCapneed1 -# -# Used by: -# Ship: Osprey type = "passive" -def handler(fit, ship, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Shield Booster", - "capacitorNeed", ship.getModifiedItemAttr("shipBonusCC"), skill="Caldari Cruiser") +def handler(fit, src, context): + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Shield Emission Systems"), "capacitorNeed", src.getModifiedItemAttr("shipBonusCC"), skill="Caldari Cruiser") diff --git a/eos/effects/subsystembonusamarrdefensive2remotearmorrepairamount.py b/eos/effects/subsystembonusamarrdefensive2remotearmorrepairamount.py index f14c08301..fa0c9a3e8 100644 --- a/eos/effects/subsystembonusamarrdefensive2remotearmorrepairamount.py +++ b/eos/effects/subsystembonusamarrdefensive2remotearmorrepairamount.py @@ -4,5 +4,5 @@ # Subsystem: Legion Defensive - Adaptive Augmenter type = "passive" def handler(fit, module, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "armorDamageAmount", module.getModifiedItemAttr("subsystemBonusAmarrDefensive2"), skill="Amarr Defensive Systems") diff --git a/eos/effects/subsystembonuscaldaridefensive2remoteshieldtransporteramount.py b/eos/effects/subsystembonuscaldaridefensive2remoteshieldtransporteramount.py index e55064df9..d267413eb 100644 --- a/eos/effects/subsystembonuscaldaridefensive2remoteshieldtransporteramount.py +++ b/eos/effects/subsystembonuscaldaridefensive2remoteshieldtransporteramount.py @@ -4,5 +4,5 @@ # Subsystem: Tengu Defensive - Adaptive Shielding type = "passive" def handler(fit, module, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Shield Booster", + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Shield Emission Systems"), "shieldBonus", module.getModifiedItemAttr("subsystemBonusCaldariDefensive2"), skill="Caldari Defensive Systems") diff --git a/eos/effects/subsystembonusgallentedefensive2remotearmorrepairamount.py b/eos/effects/subsystembonusgallentedefensive2remotearmorrepairamount.py index 9a8a14678..25c865057 100644 --- a/eos/effects/subsystembonusgallentedefensive2remotearmorrepairamount.py +++ b/eos/effects/subsystembonusgallentedefensive2remotearmorrepairamount.py @@ -4,5 +4,5 @@ # Subsystem: Proteus Defensive - Adaptive Augmenter type = "passive" def handler(fit, module, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Armor Repairer", + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Remote Armor Repair Systems"), "armorDamageAmount", module.getModifiedItemAttr("subsystemBonusGallenteDefensive2"), skill="Gallente Defensive Systems") diff --git a/eos/effects/subsystembonusminmatardefensive2remoteshieldtransporteramount.py b/eos/effects/subsystembonusminmatardefensive2remoteshieldtransporteramount.py index 1e5d2c069..349d30c51 100644 --- a/eos/effects/subsystembonusminmatardefensive2remoteshieldtransporteramount.py +++ b/eos/effects/subsystembonusminmatardefensive2remoteshieldtransporteramount.py @@ -4,5 +4,5 @@ # Subsystem: Loki Defensive - Adaptive Shielding type = "passive" def handler(fit, module, context): - fit.modules.filteredItemBoost(lambda mod: mod.item.group.name == "Remote Shield Booster", + fit.modules.filteredItemBoost(lambda mod: mod.item.requiresSkill("Shield Emission Systems"), "shieldBonus", module.getModifiedItemAttr("subsystemBonusMinmatarDefensive2"), skill="Minmatar Defensive Systems")