Skip to content

Conversation

@Silvris
Copy link
Collaborator

@Silvris Silvris commented Mar 28, 2024

What is this fixing or adding?

This PR is the combination of three major changes to plando items.

  • Moves plando items to the options api as a member of PerGameCommonOptions
  • Changes the placement of items to use fill_restrictive, which means plando should be capable of avoiding placements that can never result in a playable world
  • Plando now evaluates item and location groups.

How was this tested?

Manually via generating games with yamls using plando items. Opening as draft since any game using pre_fill will need thorough testing with this approach (KDL3 was already found to be bugged).

Ran unittests, but more unittests should likely be added.

Silvris added 3 commits March 27, 2024 22:30
the test is still busted, but now it actually plandos the items
@github-actions github-actions bot added the affects: core Issues/PRs that touch core and may need additional validation. label Mar 28, 2024
@alwaysintreble alwaysintreble added is: enhancement Issues requesting new features or pull requests implementing new features. is: refactor/cleanup Improvements to code/output readability or organizization. labels Mar 28, 2024
Co-authored-by: Exempt-Medic <60412657+Exempt-Medic@users.noreply.github.com>
@Exempt-Medic
Copy link
Contributor

It seems like this removes the ability to have plando blocks without any locations listed. For example, so that specific items end up in specific worlds. Is the intended workaround to use Everywhere?

@Silvris
Copy link
Collaborator Author

Silvris commented Mar 29, 2024

It seems like this removes the ability to have plando blocks without any locations listed. For example, so that specific items end up in specific worlds. Is the intended workaround to use Everywhere?

I believe I missed this usecase (plando items guide doesn't mention it, and it's built into get_unfilled_locations_for_players so I couldn't tell it from the plando code).

@BadMagic100
Copy link
Collaborator

Disclaimer: I have not looked at the code yet

It might be worth considering and documenting/fixing possible negative interactions with #3032 if you haven't already

I'm also curious about how pre_fill is impacted as it may affect generic ER

@beauxq
Copy link
Collaborator

beauxq commented Mar 29, 2024

Some people use plando when they WANT to make something that will be seen as unbeatable according to the logic.
Will this still be possible with this change?

@Silvris
Copy link
Collaborator Author

Silvris commented Mar 29, 2024

Some people use plando when they WANT to make something that will be seen as unbeatable according to the logic. Will this still be possible with this change?

It might still be possible, but current methods (such as locking the item behind a location that logically requires it) will no longer work. It should be noted that this doesn't prevent impossible combinations (that usually end in fill error) such as filling your entire sphere 1 with junk.

@Silvris
Copy link
Collaborator Author

Silvris commented Mar 29, 2024

Disclaimer: I have not looked at the code yet

It might be worth considering and documenting/fixing possible negative interactions with #3032 if you haven't already

I'm also curious about how pre_fill is impacted as it may affect generic ER

This should be fine, as we use the actual instance of the item instead of creating a new item and then removing using that. It's definitely worth testing though.

It appears that any world that uses pre_fill to place items that are not in the itempool must also define get_pre_fill_items so that the state used for plando can account for those items.

@Silvris
Copy link
Collaborator Author

Silvris commented May 21, 2024

List of worlds that implement pre_fill and not get_pre_fill_items:

  • Adventure (does not place progression in prefill)
  • Blasphemous
  • Castlevania 64 (does not place progression in prefill)
  • Hylics 2
  • KH2
  • KDL3 (KDL3: Version 2.0.0 #3323)
  • Pokemon Emerald
  • Pokemon RB
  • Shivers
  • Super Metroid (does not place progression)

Worlds that implement get_pre_fill_items but do not actually include all pre_fill items

  • A Link to the Past
  • Raft (very funny)

I will need to check all of these later to confirm if this is the proper reason for some worlds having issues.

@NewSoupVi
Copy link
Member

✅️

I do still wish upon a star every day that the actual PR that addresses the Witness thing gets merged one day

Copy link
Contributor

@Jouramie Jouramie left a comment

Choose a reason for hiding this comment

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

I only looked at the stardew test, LGTM.

@ScipioWright
Copy link
Collaborator

ScipioWright commented Apr 21, 2025

Approved for TUNIC, also I'm deleting that code anyway
#4908

Copy link
Collaborator

@hatkirby hatkirby left a comment

Choose a reason for hiding this comment

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

Lingo changes look fine to me. I've opened a PR to remove the plando stuff entirely anyway (#4910).

Copy link
Contributor

@Exempt-Medic Exempt-Medic left a comment

Choose a reason for hiding this comment

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

Did some more testing, not a ton, but enough. I'm fine with the behavioral changes this brings and definitely fine with all the bugs it fixes. ALttP changes are waiting on Berserker still

Co-authored-by: Fabian Dill <Berserker66@users.noreply.github.com>
Copy link
Member

@Berserker66 Berserker66 left a comment

Choose a reason for hiding this comment

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

LttP is probably fine, like with many LttP changes I always have the suspicion that while it looks fine it breaks in some "hilarious" way months later, but we'll only find out if we send it.

Silvris and others added 2 commits May 10, 2025 16:45
Co-authored-by: Doug Hoskisson <beauxq@users.noreply.github.com>
@Exempt-Medic Exempt-Medic added the is: bug/fix Issues that are reporting bugs or pull requests that are fixing bugs. label May 10, 2025
@Exempt-Medic Exempt-Medic merged commit a166dc7 into ArchipelagoMW:main May 10, 2025
16 checks passed
ProfDeCube pushed a commit to ProfDeCube/Archipelago that referenced this pull request Jun 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

affects: core Issues/PRs that touch core and may need additional validation. is: bug/fix Issues that are reporting bugs or pull requests that are fixing bugs. is: enhancement Issues requesting new features or pull requests implementing new features. is: refactor/cleanup Improvements to code/output readability or organizization. waiting-on: peer-review Issue/PR has not been reviewed by enough people yet.

Projects

None yet

Development

Successfully merging this pull request may close these issues.