From 472a63eb7c5ec73018ab8ec6ea7d4588eb3d681d Mon Sep 17 00:00:00 2001 From: Matthew Date: Fri, 13 Sep 2024 23:07:21 -0700 Subject: [PATCH] sc2: Adding carrier war council upgrade -- repair drones --- worlds/sc2/client.py | 2 +- worlds/sc2/item_descriptions.py | 2 +- worlds/sc2/item_names.py | 2 +- worlds/sc2/items.py | 2 +- worlds/sc2/rules.py | 5 ++++- 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/worlds/sc2/client.py b/worlds/sc2/client.py index d62507cb5e32..43c6b4b4aa70 100644 --- a/worlds/sc2/client.py +++ b/worlds/sc2/client.py @@ -1587,7 +1587,7 @@ def download_latest_release_zip( file = tempdir + os.sep + f"{repo}.zip" with open(file, "wb") as fh: fh.write(r2.content) - sc2_logger.info(f"Successfully downloaded {repo}.zip.") + sc2_logger.info(f"Successfully downloaded {repo}.zip. Installing...") return file, latest_metadata else: sc2_logger.warning(f"Status code: {r2.status_code}") diff --git a/worlds/sc2/item_descriptions.py b/worlds/sc2/item_descriptions.py index 1918d636eaed..1acd48b35641 100644 --- a/worlds/sc2/item_descriptions.py +++ b/worlds/sc2/item_descriptions.py @@ -944,7 +944,7 @@ def _ability_desc(unit_name_plural: str, ability_name: str, ability_description: item_names.DESTROYER_REFORGED_BLOODSHARD_CORE: "Destroyer War Council upgrade. When fully charged, the Destroyer's Destruction Beam weapon does full damage to secondary targets.", # Warp Ray item_names.DAWNBRINGER_SOLARITE_LENS: "Dawnbringer War Council upgrade. Dawnbringers gain +2 range.", - # Carrier + item_names.CARRIER_REPAIR_DRONES: "Carrier War Council upgrade. Carriers gain 2 repair drones which heal nearby mechanical units.", item_names.SKYLORD_HYPERJUMP: "Skylord War Council upgrade. " + _ability_desc("Skylords", "Hyperjump", "teleports the skylord to any location on the map."), # Trireme item_names.TEMPEST_DISINTEGRATION: "Tempest War Council upgrade. " + _ability_desc("Tempests", "Disintegration", "deals 500 damage to a target unit or structure over 20 seconds"), diff --git a/worlds/sc2/item_names.py b/worlds/sc2/item_names.py index 0db4a5ca4b84..1186a65540e6 100644 --- a/worlds/sc2/item_names.py +++ b/worlds/sc2/item_names.py @@ -768,7 +768,7 @@ DESTROYER_REFORGED_BLOODSHARD_CORE = "Reforged Bloodshard Core (Destroyer)" # Warp Ray DAWNBRINGER_SOLARITE_LENS = "Solarite Lens (Dawnbringer)" -# Carrier +CARRIER_REPAIR_DRONES = "Repair Drones (Carrier)" SKYLORD_HYPERJUMP = "Hyperjump (Skylord)" # Trireme TEMPEST_DISINTEGRATION = "Disintegration (Tempest)" diff --git a/worlds/sc2/items.py b/worlds/sc2/items.py index 08dd54b75adc..a643c1d64dc6 100644 --- a/worlds/sc2/items.py +++ b/worlds/sc2/items.py @@ -1862,7 +1862,7 @@ def get_full_item_list(): item_names.DESTROYER_REFORGED_BLOODSHARD_CORE: ItemData(336 + SC2LOTV_ITEM_ID_OFFSET, ProtossItemType.War_Council_2, 5, SC2Race.PROTOSS, classification=ItemClassification.progression, parent_item=item_names.DESTROYER), # 536 reserved for Warp Ray item_names.DAWNBRINGER_SOLARITE_LENS: ItemData(537 + SC2LOTV_ITEM_ID_OFFSET, ProtossItemType.War_Council_2, 7, SC2Race.PROTOSS, classification=ItemClassification.progression, parent_item=item_names.DAWNBRINGER), - # 538 reserved for Carrier + item_names.CARRIER_REPAIR_DRONES: ItemData(538 + SC2LOTV_ITEM_ID_OFFSET, ProtossItemType.War_Council_2, 8, SC2Race.PROTOSS, classification=ItemClassification.progression, parent_item=item_names.CARRIER), item_names.SKYLORD_HYPERJUMP: ItemData(539 + SC2LOTV_ITEM_ID_OFFSET, ProtossItemType.War_Council_2, 9, SC2Race.PROTOSS, parent_item=item_names.SKYLORD), # 540 reserved for Trireme item_names.TEMPEST_DISINTEGRATION: ItemData(541 + SC2LOTV_ITEM_ID_OFFSET, ProtossItemType.War_Council_2, 11, SC2Race.PROTOSS, parent_item=item_names.TEMPEST), diff --git a/worlds/sc2/rules.py b/worlds/sc2/rules.py index 3e38abc2a6a8..cdbaae49fc4f 100644 --- a/worlds/sc2/rules.py +++ b/worlds/sc2/rules.py @@ -1007,7 +1007,10 @@ def steps_of_the_rite_requirement(self, state: CollectionState) -> bool: ) def protoss_heal(self, state: CollectionState) -> bool: - return state.has_any({item_names.CARRIER, item_names.SENTRY, item_names.SHIELD_BATTERY, item_names.RECONSTRUCTION_BEAM}, self.player) + return ( + state.has_any((item_names.SENTRY, item_names.SHIELD_BATTERY, item_names.RECONSTRUCTION_BEAM), self.player) + or state.has_all((item_names.CARRIER, item_names.CARRIER_REPAIR_DRONES), self.player) + ) def templars_charge_requirement(self, state: CollectionState) -> bool: return (