ArchipelagoMW / Archipelago

Archipelago Multi-Game Randomizer and Server
https://archipelago.gg
Other
481 stars 638 forks source link

Core: move region and location management to worlds #4028

Open alwaysintreble opened 2 days ago

alwaysintreble commented 2 days ago

What is this fixing or adding?

This moves the region, location, and entrance caches to all be per world. There's a layer of back compatibility so all of the multiworld related helpers still work, and multiworld.regions access still works. latter will need to be deprecated and dropped eventually but unsure if any of the helpers need to be removed, as I haven't looked too deeply into all the core usages of them.

todo: The RegionManager class should be moved to no longer be locally defined under MultiWorld still, but I think the others are fine where they are. Some typing also needs to be fixed, but I'd rather make sure this is fully tested and functional and looks how we want it to before worrying too much about this. Some tests need to be fixed for the changes due to the way they create their multiworlds/worlds.

How was this tested?

A bunch of generations with solo Messenger, multiworld, and item link generations.

If this makes graphical changes, please attach screenshots.