Aleph-One-Marathon / alephone

Aleph One is the open source continuation of Bungie’s Marathon 2 game engine.
https://alephone.lhowon.org/
GNU General Public License v3.0
656 stars 99 forks source link

Escaping from an M1 terminal should go to #logon before exiting #146

Open ravenshining opened 5 years ago

ravenshining commented 5 years ago

In Marathon 1, when you escape out of a terminal, it takes you to the terminal's #LOGOFF before dumping you out, instead of dumping you out directly like M2, M∞, and A1 do. If we ever want M1 film playback, we'd have to replicate this behaviour.

There are a few ambiguities with how to go about a fix, however:

  1. We need to tell A1 whether a map's terminals dump you or log you off, whether by detecting map format, looking for the "Terminals Stop Time" flag, via a new separate flag, or by which type of tags the terminal contains (see 2)

  2. M1 maps used #BRIEFING to both teleport between levels and give you text, skipping to #LOGOFF therefore skips the teleport. If we want a map to escape to #LOGOFF but also use #INTERLEVEL TELEPORT or #INTRALEVEL TELEPORT instead of #BRIEFING, we would have to make extra sure the terminal ignores #INTERLEVEL TELEPORT, #INTRALEVEL TELEPORT, and #TAG when skipping to #LOGOFF.

  3. All of Bungie's and Double-aught's maps AFAIK used only one #LOGOFF per term, however, scenarios like Eternal and M1R use multiple #LOGOFF tags to transition between AIs in a single terminal session. If those maps are flagged to escape to #LOGOFF, do we skip to the next and proceed, skip to the next and exit, or skip to the last and exit? Given the conventions Pfhorrest and I have been using, skipping to the next #LOGOFF and exiting would make the most sense.

ravenshining commented 5 years ago

After some more testing, I've found more differences in M1 terminal responses to input that might prevent possible future M1 film compatibility, and which alter the experience for those who might prefer a faithful reproduction of M1's slightly more nuanced control.

Also, a correction: M1 doesn't use #logoff, instead it returns to #logon when exiting.

PgUp/PgDown/Arrows:

Tab:

Option:

Escape:

If multiple #logon or #LOGOFF screens are present:

Only this is the same across M1, M∞, and A1:


Finally, after poking around in computer_interface.cpp, it looks like using the _group_is_marathon_1 flag to produce M1 behaviour might be a better solution than any of my ideas in the opening comment, since that's already used to alter terminal rendering.

We might even be able to use _group_is_marathon_1 to to fine-tune behaviour in future scenarios if support for it is added to Atque and the right logic to A1. For example, lets say we call it M1 in Atque, maybe one could put #LOGOFF M1 in a terminal to tell it to escape to there, and #INFORMATION M1 to control whether to use M1 or M2 text boundaries.

Hopper262 commented 5 years ago

One correction for future readers: A1 (and also M∞, judging by the source code) does not care about "Left Trigger" or "Secondary Trigger" when reading terminals. A1 advances screens with Tab, Enter, Return, or Space - coincidentally, Left Trigger is bound to Space by default. Rebinding the triggers will have no effect on terminals; the space key will still be used to advance. The weapon firing simply happens because you're still holding space when the normal game controls take effect again.

M∞ also treats the Option key the same as Tab / Enter / Return / Space, according to its source code. I assume Option is the default binding for Secondary Trigger. In typical Bungie fashion, the comment next to this key assignment says "command" instead!

In Aleph One 1.3b1 or later, a controller can also be used to navigate terminals.

ravenshining commented 5 years ago

I see how I made that mistake. After rebinding the keys a few times, it appears that M∞ uses option, while M1 does not. If A1 accepts option, I suppose it must require an actual Mac keyboard and ignores how my OS remaps my windows keyboard to behave like a Mac keyboard.

I'll edit my post accordingly.

Hopper262 commented 5 years ago

You're not missing anything, Aleph One does not accept the Option key. I assume the devs removed that because the modifier keys are positioned/named differently across OS'es, and we have four other keys that do the same thing. ;)