diff --git a/src/open_samus_returns_rando/specific_patches/door_patches.py b/src/open_samus_returns_rando/specific_patches/door_patches.py index 010960f..a4f44f1 100644 --- a/src/open_samus_returns_rando/specific_patches/door_patches.py +++ b/src/open_samus_returns_rando/specific_patches/door_patches.py @@ -39,7 +39,7 @@ "unk2": 1, "unk3": 0, "args": Container({ - 601445949: Container({ # type: ignore + "CallbackName": Container({ "type": "s", "value": "RemoveDoors", }), @@ -562,7 +562,7 @@ def add_custom_shields(editor: PatcherEditor, new_shield: NewShield) -> None: # Remove the drops from breaking the shield custom_shield.raw["components"].pop("DROP") # Remove the particle animation that occurs after the shield breaks (color mismatch) - custom_shield.raw["action_sets"][0]["animations"][0]["events0"][1]["args"][729149823]["value"] = 0 + custom_shield.raw["action_sets"][0]["animations"][0]["events0"][1]["args"]["LinkType"]["value"] = 0 elif new_shield.base_shield in {"doorshieldsupermissile", "doorshieldpowerbomb"}: # Some shaders do not use dissolve fx, so force fx to be used custom_shield.raw["components"]["LIFE"]["fields"]["bDisolveByMaterial"]["value"] = False diff --git a/src/open_samus_returns_rando/specific_patches/metroid_patches.py b/src/open_samus_returns_rando/specific_patches/metroid_patches.py index ccd09da..1c07384 100644 --- a/src/open_samus_returns_rando/specific_patches/metroid_patches.py +++ b/src/open_samus_returns_rando/specific_patches/metroid_patches.py @@ -27,9 +27,9 @@ def _patch_metroids(editor: PatcherEditor) -> None: death_callbacks = [ item for events in events0 - for magic_number, item in events["args"].items() - # arguments with this number defines the function to call - if magic_number == 601445949 + for parameter_name, item in events["args"].items() + # check if this event defines a CallbackName + if parameter_name == "CallbackName" ] for death_callback in death_callbacks: death_callback["value"] = "RemoveMetroid"