Binding 'repeat' (DOAGAIN, or redo) to a different key than ^A didn't work as intended because the code that used it was checking for DOAGAIN (a key value from config.h) instead of g.Cmd.spkeys[NHKF_DOAGAIN] (the key currently bound to repeat). Contrary to the github issue, re-bound prefix keys worked ok for me if followed by a direction. However, they behaved strangely if followed by anything else. If the keystroke was stolen from some other command and that command hadn't been bound to another key, following the prefix with a non-direction could end up executing the command that used to own the key. For example, BIND=d:nopickup to use 'd' to move without auto-pickup would work if you used d<direction> but if you used d<something-else> if would execute the drop command. The NHKF_REQMENU prefix could be bound to some key other than 'm' but it only worked as intended if the new key was a movement prefix. This also makes DOAGAIN be unconditional. If it is deleted or commented out in config.h, the default binding will be '\000' so unusable (freeing up ^A for something), but still be available to be bound to some key (perhaps even ^A). This also includes an unrelated change to mdlib.c. The comments added to config.h will force a full rebuild. Changing mdlib.c now rather than separately will avoid forcing that twice. Fixes #426
40 KiB
40 KiB