Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Muse Dash: Fix bad generations occuring due to changing item ids #2122

Merged
merged 12 commits into from
Aug 29, 2023

Conversation

DeamonHunter
Copy link
Collaborator

What is this fixing or adding?

This PR adjusts the MuseDashCollection class to be a bit more hardcoded, and resolve some issues where running it multiple times could cause Ids to change. (Test added to ensure this isn't the case anymore)

Additionally:

  • Fixed the item creation branch that could add an item with code: None into the pool.
  • Added test to ensure the additional free dlcs are included. Fixed typo causing Budget Is Burning Vol.1 to not show.
  • Adjusted the removed song test to work without needing to generate. (Thus removing random elements.)
  • Song Updates

How was this tested?

Several local generations + tests.

If this makes graphical changes, please attach screenshots.

N/A

worlds/musedash/test/TestCollection.py Outdated Show resolved Hide resolved
worlds/musedash/test/TestCollection.py Show resolved Hide resolved
"Nyaa SFX Trap": 8,
"Error SFX Trap": 9,
"Nyaa SFX Trap": STARTING_CODE + 8,
"Error SFX Trap": STARTING_CODE + 9,
}

item_names_to_id = ChainMap({}, sfx_trap_items, vfx_trap_items)
location_names_to_id = ChainMap(song_locations, album_locations)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The World API defines both item_name_to_id and location_name_to_id as a ClassVar[Dict[str, int]], not a ChainMap.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made the MuseDashWorld part into a dictionary, but kept this as a chainmap. Hopefully should be good.

worlds/musedash/MuseDashCollection.py Show resolved Hide resolved
worlds/musedash/MuseDashCollection.py Outdated Show resolved Hide resolved
worlds/musedash/test/TestCollection.py Outdated Show resolved Hide resolved
worlds/musedash/MuseDashCollection.py Outdated Show resolved Hide resolved
@Berserker66 Berserker66 merged commit 9d29c6d into ArchipelagoMW:main Aug 29, 2023
12 checks passed
@ThePhar ThePhar added the is: bug/fix Issues that are reporting bugs or pull requests that are fixing bugs. label Oct 16, 2023
FlySniper pushed a commit to FlySniper/Archipelago that referenced this pull request Nov 14, 2023
Jouramie pushed a commit to Jouramie/Archipelago that referenced this pull request Feb 28, 2024
@DeamonHunter DeamonHunter deleted the Deamon/FixCollectionBug branch April 8, 2024 22:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
is: bug/fix Issues that are reporting bugs or pull requests that are fixing bugs.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants