From e342a20fde278f58c0655a976c86fdd7433a9717 Mon Sep 17 00:00:00 2001 From: PoryGone <98504756+PoryGone@users.noreply.github.com> Date: Wed, 3 Sep 2025 21:50:59 -0400 Subject: [PATCH] Celeste (Open World): Post-merge Logic Fix (#5415) * APWorld Skeleton * Hair Color Rando and first items * All interactable items * Checkpoint Items and Locations * First pass sample intermediate data * Bulk of Region/location code * JSON Data Parser * New items and Level Item mapping * Data Parsing fixes and most of 1a data * 1a complete data and region/location/item creation fixes * Add Key Location type and ID output * Add options to slot data * 1B Level Data * Added Location logging * Add Goal Area Options * 1c Level Data * Old Site A B C level data * Key/Binosanity and Hair Length options * Key Item/Location and Clutter Event handling * Remove generic 'keys' item * 3a level data * 3b and 3c level data * Chapter 4 level data * Chapter 5 Logic Data * Chapter 5 level data * Trap Support * Add TrapLink Support * Chapter 6 A/B/C Level Data * Add active_levels to slot_data * Item and Location Name Groups + style cleanups * Chapter 7 Level Data and Items, Gemsanity option * Goal Area and victory handling * Fix slot_data * Add Core Level Data * Carsanity * Farewell Level Data and ID Range Update * Farewell level data and handling * Music Shuffle * Require Cassettes * Change default trap expiration action to Deaths * Handle Poetry * Mod versioning * Rename folder, general cleanup * Additional Cleanup * Handle Farewell Golden Goal when Include Goldens is off * Better handling of Farewell Golden * Update Docs * Beta test bug fixes * Bump to v1.0.0 * Update Changelog * Several Logic tweaks * Update APWorld Version * Add Celeste (Open World) to README * Peer review changes * Logic Fixes: * Adjust Mirror Temple B Key logic * Increment APWorld version * Fix several logic bugs * Add missing link * Add Item Name Groups for common alternative item names * Account for Madeline's post-Celeste hair-dying activities * Account for ignored member variable and hardcoded color in Celeste codebase * Add Blue Clouds to the logic of reaching Farewell - intro-02-launch * Type checking workaround * Bump version number * Adjust Setup Guide * Minor typing fixes * Logic and PR fixes * Increment APWorld Version * Use more world helpers * Core review * CODEOWNERS * Minor logic fix and insert APWorld version into spoiler * Fix merge error --- worlds/celeste_open_world/__init__.py | 12 +++++++++++- worlds/celeste_open_world/data/CelesteLevelData.json | 8 ++++---- worlds/celeste_open_world/data/CelesteLevelData.py | 2 +- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/worlds/celeste_open_world/__init__.py b/worlds/celeste_open_world/__init__.py index 38c3778e..c0661b55 100644 --- a/worlds/celeste_open_world/__init__.py +++ b/worlds/celeste_open_world/__init__.py @@ -1,5 +1,6 @@ from copy import deepcopy import math +from typing import TextIO from BaseClasses import ItemClassification, Location, MultiWorld, Region, Tutorial from Utils import visualize_regions @@ -41,6 +42,8 @@ class CelesteOpenWorld(World): options_dataclass = CelesteOptions options: CelesteOptions + apworld_version = 10005 + level_data: dict[str, Level] = load_logic_data() location_name_to_id: dict[str, int] = location_data_table @@ -251,7 +254,7 @@ class CelesteOpenWorld(World): def fill_slot_data(self): return { - "apworld_version": 10004, + "apworld_version": self.apworld_version, "min_mod_version": 10000, "death_link": self.options.death_link.value, @@ -292,6 +295,13 @@ class CelesteOpenWorld(World): "chosen_poem": self.random.randint(0, 119), } + @classmethod + def stage_write_spoiler_header(cls, multiworld: MultiWorld, spoiler_handle: TextIO): + major: int = cls.apworld_version // 10000 + minor: int = (cls.apworld_version % 10000) // 100 + bugfix: int = (cls.apworld_version % 100) + spoiler_handle.write(f"\nCeleste (Open World) APWorld v{major}.{minor}.{bugfix}\n") + def output_active_traps(self) -> dict[int, int]: trap_data = {} diff --git a/worlds/celeste_open_world/data/CelesteLevelData.json b/worlds/celeste_open_world/data/CelesteLevelData.json index 5b4edd9b..9d636960 100644 --- a/worlds/celeste_open_world/data/CelesteLevelData.json +++ b/worlds/celeste_open_world/data/CelesteLevelData.json @@ -37055,6 +37055,10 @@ { "dest": "north-west", "rule": [ [ "double_dash_refills", "springs", "dash_switches" ] ] + }, + { + "dest": "south-east-door", + "rule": [] } ] }, @@ -37082,10 +37086,6 @@ "dest": "north-east-door", "rule": [] }, - { - "dest": "south-east-door", - "rule": [] - }, { "dest": "south-west-door", "rule": [] diff --git a/worlds/celeste_open_world/data/CelesteLevelData.py b/worlds/celeste_open_world/data/CelesteLevelData.py index f4c492dd..6ba43fc3 100644 --- a/worlds/celeste_open_world/data/CelesteLevelData.py +++ b/worlds/celeste_open_world/data/CelesteLevelData.py @@ -4771,11 +4771,11 @@ all_region_connections: dict[str, RegionConnection] = { "10a_d-00_north---10a_d-00_south": RegionConnection("10a_d-00_north", "10a_d-00_south", [["Farewell - Power Source Key 5", ], ]), "10a_d-00_south-east---10a_d-00_south": RegionConnection("10a_d-00_south-east", "10a_d-00_south", [[ItemName.double_dash_refills, ItemName.dash_switches, ], ]), "10a_d-00_south-east---10a_d-00_north-west": RegionConnection("10a_d-00_south-east", "10a_d-00_north-west", [[ItemName.double_dash_refills, ItemName.springs, ItemName.dash_switches, ], ]), + "10a_d-00_south-east---10a_d-00_south-east-door": RegionConnection("10a_d-00_south-east", "10a_d-00_south-east-door", []), "10a_d-00_north-west---10a_d-00_south": RegionConnection("10a_d-00_north-west", "10a_d-00_south", [[ItemName.jellyfish, ItemName.dash_switches, ], ]), "10a_d-00_north-west---10a_d-00_breaker": RegionConnection("10a_d-00_north-west", "10a_d-00_breaker", [[ItemName.jellyfish, ItemName.springs, ItemName.dash_switches, ItemName.breaker_boxes, ], ]), "10a_d-00_breaker---10a_d-00_south": RegionConnection("10a_d-00_breaker", "10a_d-00_south", []), "10a_d-00_breaker---10a_d-00_north-east-door": RegionConnection("10a_d-00_breaker", "10a_d-00_north-east-door", []), - "10a_d-00_breaker---10a_d-00_south-east-door": RegionConnection("10a_d-00_breaker", "10a_d-00_south-east-door", []), "10a_d-00_breaker---10a_d-00_south-west-door": RegionConnection("10a_d-00_breaker", "10a_d-00_south-west-door", []), "10a_d-00_breaker---10a_d-00_west-door": RegionConnection("10a_d-00_breaker", "10a_d-00_west-door", []), "10a_d-00_breaker---10a_d-00_north-west-door": RegionConnection("10a_d-00_breaker", "10a_d-00_north-west-door", []),