Repository navigation
Conversation
Add an additional re-computation of `picksomething` in `src/role.c:genl_player_setup`, so that unambiguous combinations like OPTIONS=role:valkyrie,race:dwarf do not require a prompt for confirmation, when starting the game.
Author
|
proposed fix works in my local test, Gentoo Linux system, using: nh rcfile: https://www.alt.org/nethack/userdata/a/aoei/aoei.nh500rc (fiddle with the comments at the top for fully-specified vs. implicitly-specified role combinations) |
Author
|
bug report reference: #K4519 (submitted with online form at https://nethack.org/common/contact.html) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It seems that the game will always ask "are you sure you want to play $combo? y/n" on start
in cases where, due to role or race restrictions, only one combination of race/role/align/gender is possible,
but the full combination has not been explicitly set in the rcfile.
Examples that will prompt (one or more property constrained implicitly):
OPTIONS=race:dwarf,role:valkyrie,gender:female
OPTIONS=race:dwarf,role:valkyrie,align:lawful
OPTIONS=race:dwarf,role:valkyrie
OPTIONS=race:gnome,role:wizard,gender:female
Examples that will not prompt:
OPTIONS=race:dwarf,role:valkyrie,gender:female,align:lawful
OPTIONS=race:gnome,role:wizard,gender:female,align:neutral
A possible fix for this is to re-compute
picksomethinginsrc/role.cafterrigid_role_checks();