Removed features I'd love to get back

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Flambard
    Scout
    • Mar 2019
    • 30

    Removed features I'd love to get back

    I want to preclude this post, by admitting, that I have some ulterior motives for this request, mainly having MAngband and Angband be somewhat aligned, allowing players to retain their knowledge across those games.

    1. Loading options from .prf files.

    It's weird, that I can no longer setup default options without reloading a savefile from another character. And I can't edit the savefile itself, because it's in binary format.

    + that is the only way to set options in MAngband, because player savefiles are kept on the server, and there's no way to generate a character by loading some other character's savefile

    2. Macro system.

    I know it was a large piece of code nobody understood completely, and it had a potential to screw up players (as each key could be accidentally re-mapped to something nonsensical), but to me it was an important, and very convenient tool.

    I'm used to have all the spells and missile-shooting actions being macroed to 1 simple keystroke, and typing in the whole command is a chore!

    + it was nice to tell Players "we use the same macro system as V, so if you understand that, you already know what to do" + the ability to just copy the .prf file from Angband to MAngband (or vice versa) and have everything working as expected

    * * *

    If this is some principal thing, I'll hold my peace, but if this is some kind of oversight, and there's just not enough dev.time to restore those, I'd gladly provide pull requests. Just want to know what's the stance on those, before I dive into code.
  • fph
    Veteran
    • Apr 2009
    • 1030

    #2
    What macros would you like to use that don't work as keymaps?
    --
    Dive fast, die young, leave a high-CHA corpse.

    Comment

    • Flambard
      Scout
      • Mar 2019
      • 30

      #3
      Originally posted by fph
      What macros would you like to use that don't work as keymaps?
      Something like `f1*t` or `m1a*5`

      Comment

      • Derakon
        Prophet
        • Dec 2009
        • 9022

        #4
        Originally posted by Flambard
        Something like `f1*t` or `m1a*5`
        Those work just fine as keymaps; I use ones just like those all the time.

        Literally the only thing macros do differently than keymaps is macros can be accepted any time the game is prompting you for input, such as when you're in the middle of a menu or there's a -more- prompt pending. As such, macros leave you open to lethal errors. For example, say there's a -more- prompt when you hit your "m1a*5" macro. The "m" in the macro clears the prompt, then you send 1, and walk southwest...into LOS of the Tarrasque, Vecna, Azriel, etc. and die horribly.

        Whereas a keymap in the same situation wouldn't activate. If you hit "m" you'd just clear the -more- prompt and nothing else would happen.

        Comment

        • Pete Mack
          Prophet
          • Apr 2007
          • 6883

          #5
          Originally, macros were necessary to deal with Unix tty stuff. Other than that, there were almost no cases where macros were really useful in V. Other games variants let you change your stance through various menus. In those games, macros are still necessary. Examples are
          ToME2: jump between all out melee (fast, aggressive) and sneaky (slow, cowardly.) Going thru the menus was a nuisance, but a macro that incremented each attribute by 4 and another that decremented them by 4, and suddenly the feature became useful.
          Sil: Toggle flaming arrows to preserve ammo in less desperate fights.

          Comment

          • Derakon
            Prophet
            • Dec 2009
            • 9022

            #6
            I'm pretty sure you can still do that with keymaps so long as the keymap is invoked when the game doesn't have any pending operations. That is, you're not in a menu or subscreen and there's no -more- prompt. For example, I'm fairly confident that "CEEEE" would in ToME reduce your exploration speed by 4 levels, and "Ceeee" would increase it by four. They'd both leave you on the C screen though; IIRC you can put \e into a keymap to send the Escape key.

            Comment

            • Flambard
              Scout
              • Mar 2019
              • 30

              #7
              Originally posted by Derakon
              Those work just fine as keymaps; I use ones just like those all the time.

              Literally the only thing macros do differently than keymaps is macros can be accepted any time the game is prompting you for input, such as when you're in the middle of a menu or there's a -more- prompt pending. As such, macros leave you open to lethal errors. For example, say there's a -more- prompt when you hit your "m1a*5" macro. The "m" in the macro clears the prompt, then you send 1, and walk southwest...into LOS of the Tarrasque, Vecna, Azriel, etc. and die horribly.

              Whereas a keymap in the same situation wouldn't activate. If you hit "m" you'd just clear the -more- prompt and nothing else would happen.
              Ahh, I feel stupid now, I was under the assumption keymaps were 1-to-1 mappings between "underlying"/roguelike/original keys. And yeah, that "1 walks you southwest" thing actually happened to me a lot (not with Tarrasque around, thankfully).

              Thank you very much for that detailed explanation, I'll play around with keymaps and see if I still miss any functions (likely not).

              Comment

              • Flambard
                Scout
                • Mar 2019
                • 30

                #8
                Originally posted by Pete Mack
                Originally, macros were necessary to deal with Unix tty stuff. Other than that, there were almost no cases where macros were really useful in V. Other games variants let you change your stance through various menus. In those games, macros are still necessary. Examples are
                ToME2: jump between all out melee (fast, aggressive) and sneaky (slow, cowardly.) Going thru the menus was a nuisance, but a macro that incremented each attribute by 4 and another that decremented them by 4, and suddenly the feature became useful.
                Sil: Toggle flaming arrows to preserve ammo in less desperate fights.
                Yup, I wanted to mention such things (e.g. a macro to enter options menu, select a submenu, "scroll down" by 4 points, press "y", escape, like "\e=12222y\e\e"), but I thought that's something too convoluted to mention.

                In MAng, such things are still useful, but I couldn't come up with a good reason to have something like that in V. Also, clearing prompts/exiting sub-menus is something a macro could/SHOULD do in MAng (via "\e"), but, again, I don't see a good reason to have this in V (as it's not real-time).

                Anyways, if keymaps still can send "\e", and still do exactly the same thing, with the only difference being they must be executed from the request-command prompt, I feel that's sufficient.

                I'll play around and report if I'm still missing anything.

                Comment

                • Gwarl
                  Administrator
                  • Jan 2017
                  • 1025

                  #9
                  Originally posted by Pete Mack
                  Originally, macros were necessary to deal with Unix tty stuff.
                  This is a curious thing on angband.live. Variants which retain the original macro/keymap system will only accept macros and not keymaps for control sequences (such as arrow keys). V keymaps work fine with arrow keys.

                  Comment

                  • Pete Mack
                    Prophet
                    • Apr 2007
                    • 6883

                    #10
                    Gwarl-
                    Nothing curious about it. Arrow keys are represented as an escape sequence of ordinary ASCII characters in the input stream. You can either let the curses library handle it, or deal with it directly.

                    Comment

                    • Gwarl
                      Administrator
                      • Jan 2017
                      • 1025

                      #11
                      Yes, I gave arrow keys as an example where macros were (and in other variants are) needed. There's also a cursor setting in the terminal which encodes numpad 1 and 7 differently, and angband 4 preffered a different setting than angband 3 here to run as expected (although either version could be used with either setting with some pref file editing).

                      Comment

                      • takkaria
                        Veteran
                        • Apr 2007
                        • 1951

                        #12
                        Originally posted by Gwarl
                        This is a curious thing on angband.live. Variants which retain the original macro/keymap system will only accept macros and not keymaps for control sequences (such as arrow keys). V keymaps work fine with arrow keys.
                        It's not just a keymap/macro level thing - it's a more fundamental feature of modern V's input system that it recognises arrow keys as arrow keys (and page up/down as page up/down etc.) Before I rewrote the input system somewhere around 3.2, the game had no notion of arrow keys, there were just escape sequences that were mapped to numbers in the macro layer.
                        takkaria whispers something about options. -more-

                        Comment

                        Working...
                        😀
                        😂
                        🥰
                        😘
                        🤢
                        😎
                        😞
                        😡
                        👍
                        👎