Author Topic: Context Menu  (Read 5331 times)

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Context Menu
« on: October 09, 2011, 08:46:14 pm »
Every now and then I poke at the AIW context menu to re-implement some of the old functions from the pre-Unity days.  But one thing really sticks out at me: it really doesn't feel easy to use.  And this tends to dampen my enthusiasm for stuffing functionality in there.  Surely there are solutions, but I'm more of an engineer than a UI designer.  Anyway, a few thoughts:


1) Alt+right-click just doesn't feel right to open it (requires both input devices and both hands) and while it's also possible to open it with one key if you bind it to KeyBind.OpenDefaultContextMenu that's not bound by default.  Having to go into the input bindings window just to make stuff usable tends to limit the number of people who even try.  I'd really like to have a nice, prominent one-key default binding for opening the thing.  Like Spacebar, Tab, Enter, or maybe Tilde/Backqoute.  Naturally the problem is that AIW has a hilarious density of default bindings already:

- Spacebar: Used for KeyBind.ReverseEngineDamageFilter (InGame) and KeyBind.CenterOnSelection (PlanetView).  The first of those I could probably displace or unbind altogether, but CenterOnSelection is kind of important.  I wonder how much pain would arise if I displaced that to, say, LeftBracket?  Or made it so that (on default bindings) tapping space once would open the context menu, and pressing space while on the context menu would close it and center on the selection?

- Tab: heh.  KeyBind.SwitchBetweenPlanetAndGalaxyView isn't important, right?

- Enter: Used for opening the chat window.  It's not even a rebindable key, that's just what KeyCode.Return does in this game.  Interestingly there's also a KeyBind.OpenChatPopup but changing that to something other than Return won't stop the code that checks it literally.
(Edit: sorry, I was incorrect, the hardcoded part is to make Return send a chat from the chat popup once it's already open, it's actually quite possible to rebind opening the chat popup away from Return)

- Tilde/Backquote: would only displace KeyBind.GoToMostRecentFlare (InGame) but I seem to recall that some keyboards don't even have one of these, and that it caused problems sometime in the past when we were trying to use it for something more important.  But since it's rebindable that's not insurmountable.  Anyone object to making Backquote the default for KeyBind.OpenDefaultContextMenu and bumping KeyBind.GoToMostRecentFlare to LeftBracket or some other currently unbound key?  Anyone think it wouldn't really help the usability even if we did that?


2) Ok, the thing's open now, how usable is it?  How would you like to use it?  (in the words of marketing, "do people want fire that can be fitted nasally?") 

- Originally I intended it for mouse-only usage and it does function that way.  Probably a radial would be more usable for mouse interaction, more on that (why I don't want to do that, specifically) later.

- Later I became increasingly interested in binding each menu-button to a key (or two keys, for buttons with both a left-click and right-click event) because the keyboard doesn't depend on moving the mouse some specific distance, etc.  In my head I pictured someone with one hand over the numberpad just flying through the options because everything was on 0-9, etc.
-- But that hasn't really worked out that way.  If you're enterprising enough to actually bind all the button-specific keybinds you can do that, and use it that way, but I wonder if anyone ever really has.  I could have given them default bindings (within the context of a specific context menu the whole keyboard is basically fair game, it just overrides anything from any other context like InGame or WithSelection or PlanetView) but it was difficult to keep things consistent.
-- So I'm wondering if maybe taking a sort of "grid keys" approach would work better?  Basically the first function responds to 1 (Alpha1 or Keypad1 or both, dunno), the second to 2, and so on.  On the alpha row we could go clear over to Equals (on my own provincial backwoods keyboard layout, anyway), and have Backspace back up to the previous menu.  That would even fit with making backquote the key to open the context menu to begin with.  Alternatively it could do Q for the first function, W for the second, and so on (possibly QWERASDF or going out to T or even Y, dunno; my apologies to Dvorak).  Anyway, this would make all the menus automatically keyboard navigable, though I'd probably still need to provide a way to manually rebind the individual functions.  Any preferences?  Sound like total hogwash?

- There's also the issue of whether it stays open when you do a certain task in it.  Generally now it will close after you click something if that something actually made a change to the game or issued an order, and won't close if it's just configuring an order to be issued later.  And if you hold shift it mostly won't close even when issuing an order.  But I wonder if it needs some kind of explanatory note or on-menu toggle for "don't leave me".


3) Ok, it's open, the buttons are easily triggerable in some way.  How does it tell you what they do?

- Right now you can hold / and mouseover a button to get an explanatory tooltip (though in recent testing it doesn't always work, hmm), but unless you read through the bindings or some version 3 change notes you'd have no idea it did that.
-- In my working copy I've got it displaying a little note at the bottom of the context menu saying to press Slash (or whatever you've bound to it) and mouseover to get the info.
-- Should it just always display those tooltips on mouseover unless you flip some new specific toggle on the settings window?

- Even with the individual tooltips, it's not necessarily going to be clear how to use a given menu.
-- In my working copy I've got a label above the buttons that the individual menu can populate with whatever, like currently (been working on resuscitating arc move but didn't want to leave it the way it was) :

"Arc Move Step 1
Right click where you want the center of the circle to be.
(The advanced buttons below are entirely optional)"

and after you right click

"Arc Move Step 2
Right click where you want the center of the arc to be.  This determines how big the circle is. If the arc is less than 360 degrees it also determines the part of the circle to use."

-- On the other hand, if there's text on the screen, do players actually read it?  My previous experience with UI design tends to say no :)  Which mostly makes sense: if they wanted to read a book, they would be reading a book.


4) Radial menus... I caught a lot of guff from some folks about how these absolutely needed to be radial back when the context menu was first added.  But I stand by not going that direction:

- They're indisputably a lot more work in terms of needing an icon (and an icon that actually explains the meaning of the button in some way), and even more work if actually a radial menu instead of 8 boxes arranged around the cursor.

- I could live with the "more work" part (and just make programmer art icons so painful that one of you supplied a replacement out of self-defense) if I were convinced that they were actually more usable.  I'm not, for AIW's case:
-- Unless the task is something easily communicated by a picture (which simply is not going to be all of what we put here) and the picture is really good at its job you're still going to need more info to even identify the task conclusively; a mouseover can do that but it's extra work simply to _read_ the menu, let alone use it.
-- Speaking of reading, do you really prefer to read in a circle rather than left-to-right top-to-bottom?

- Puts a pretty hard limit on the number of items in a given menu.  I imagine 8 is about the max.  On the other hand, maybe if I need more than 8 for a specific menu I'm doing it wrong (though there is the give-resources menu, and 8 players plus other functions).


And what logically goes at the beginning, but probably better at the end:

0) Does anyone care?  Would you rather have more-devious Hybrids and/or an FS campaign that doesn't make you do the same thing 8 times in a row? (speaking in terms of things I might actually do on hobby time, everything else is AVWW right now really)  Does any of the stuff in the context menu or that might possibly go on the context menu need to be all that accessible?  The game certainly got on just fine without one until 3.12X or whenever I added it to begin with.  Just a ton of little functions (some useful, some hilariously arcane) that we don't have room to give default keys that can fit there, etc.  Some existing little functions (galaxy map filters) that we could move there, when it comes down to it.
« Last Edit: October 09, 2011, 08:52:21 pm by keith.lamothe »
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Nalgas

  • Hero Member
  • *****
  • Posts: 680
Re: Context Menu
« Reply #1 on: October 09, 2011, 09:33:43 pm »
Alt+right-click just doesn't feel right to open it (requires both input devices and both hands) and while it's also possible to open it with one key if you bind it to KeyBind.OpenDefaultContextMenu that's not bound by default.

Never particularly bothered me.  It's less silly than a whole lot of the other default bindings the game comes with (holding shift-n-4 while dragging a selection box with the mouse with your other hand to add all mk4 ships in it to your current selection is always a good time), so it's waaaaaaay down on the list of things that seem weird or out of place to me.  I don't think it's actually occurred to me to want to change it to something other than what it is after the first 15 minutes or so that I spent using it way back whenever.

Or made it so that (on default bindings) tapping space once would open the context menu, and pressing space while on the context menu would close it and center on the selection?

No.  That is just not ok.  Heh.

- Tilde/Backquote: would only displace KeyBind.GoToMostRecentFlare (InGame) but I seem to recall that some keyboards don't even have one of these, and that it caused problems sometime in the past when we were trying to use it for something more important.  But since it's rebindable that's not insurmountable.  Anyone object to making Backquote the default for KeyBind.OpenDefaultContextMenu and bumping KeyBind.GoToMostRecentFlare to LeftBracket or some other currently unbound key?  Anyone think it wouldn't really help the usability even if we did that?

Go nuts, although see above.  I already swapped that one out to put something actually useful on it instead, because it's a conveniently-located key, so it wouldn't affect me.  I think that would be the least problematic place to put it of all the proposed options; I just am not entirely convinced it isn't ok how it is.  No one I play with has ever really complained about it.

Alternatively it could do Q for the first function, W for the second, and so on (possibly QWERASDF or going out to T or even Y, dunno; my apologies to Dvorak).

Won't someone think of poor QGMLWB?  I'm mostly kidding, although one of my friends who I've played with before recently switched to that purely out of boredom.

Ok, it's open, the buttons are easily triggerable in some way.  How does it tell you what they do?

Some way to discover that the tooltips even exist would indeed be a good start compared to the way it is now, even if a few of the things in there are a bit complex to figure out the workings of just through a tooltip or two.  Most of the things that are or would be most commonly used by people could be made more easily discoverable that way, at least.

Offline Kittens

  • Newbie Mark III
  • *
  • Posts: 38
Re: Context Menu
« Reply #2 on: October 10, 2011, 01:06:59 am »
I don't mind alt-rightclick at all to be honest. It's a bit annoying that you can't deselect units while in the galaxy view, though.

For instance, I still have some units selected, I'm looking at the galaxy view and I want to give my ally some resources. I can only do this with the context menu while having no units selected, so I have to go back in planet view, deselect my units, and then alt-rightclick to access the resource trading menu.

Offline Mithror

  • Jr. Member Mark II
  • **
  • Posts: 76
Re: Context Menu
« Reply #3 on: October 10, 2011, 05:37:33 am »
I don't mind alt-rightclick at all to be honest. It's a bit annoying that you can't deselect units while in the galaxy view, though.

For instance, I still have some units selected, I'm looking at the galaxy view and I want to give my ally some resources. I can only do this with the context menu while having no units selected, so I have to go back in planet view, deselect my units, and then alt-rightclick to access the resource trading menu.

Yes, definitely. Fix this and I'm a happy panda! :)

Offline zoutzakje

  • Hero Member Mark III
  • *****
  • Posts: 1,052
  • Crosshatch Conqueror
Re: Context Menu
« Reply #4 on: October 10, 2011, 08:42:17 am »
I have no issues with Alt-Right click (though I often do forget that whole menu even exists lol). But perhaps Alt-m would be easier? you can acces it with one hand and use your mouse to select an option.
And if there's text on the screen, I read it. Always. the more I know about how stuff works or where to go for quests in other games, the better. I doubt there are many tooltips left in AI war that I haven't fully read and / or mostly memorized yet.
And yeah, I care. any improvement to the game counts in my opinion, no matter how small the improvement may be.

Offline Hearteater

  • Core Member
  • *****
  • Posts: 2,334
Re: Context Menu
« Reply #5 on: October 10, 2011, 09:02:12 am »
Is there any need for the context menu to actually appear at the mouse location?  Is there any reason a side/bottom/top bar that is hidden until you press the "context" key binding work?

I ask this because in a lot of UI systems it is a lot easier to handle tooltips with that type of setup.  It also makes a lot of sense to users for the key binding to show/hide the menu.

For me, the only context menu option I use currently is Auto-Load (besides custom map layout, which feels fairly awkward to me as a context menu and I'd rather have a drop down on the bottom bar).  Although I use Auto Load a ton.  I'd almost like alt-right click to be "special action" click that did the most common context-sensitive action when you clicked on something so you could avoid the entire context menu most of the time.  So transports would get auto-load as their alt-right click action.

Offline Nalgas

  • Hero Member
  • *****
  • Posts: 680
Re: Context Menu
« Reply #6 on: October 10, 2011, 09:21:30 am »
Thinking a little more, I am strongly opposed to removing the alt-right click binding.  Adding some sort of alternate keyboard binding is ok, but contextual menus are by their nature a mouse-related interface element; they are menus that have traditionally been brought up using the mouse showing a set of actions related to what you have selected or what you clicked on, and keyboard shortcuts for doing that are usually conveniences that have been added later and/or that no one uses.  Unless changing them to be something entirely different, that's just what they are, and taking that away from them is potentially even weirder and more confusing.  Having it not appear near your mouse cursor would also be a great way to make it unwieldy and slower to use.

Also, there's about a decade and a half of precedence for using a keyboard and mouse combination for bringing up contextual menus.  These days everyone has a multi-button mouse or a multitouch trackpad, but ctrl-click still brings up contextual menus in OS X (and sends a right click event in general, actually) as a legacy of the old days before that was true.  Way, way back in the day, I believe it was actually cmd-click, at least in some early web browsers before it was standardized system-wide.

Offline Echo35

  • Master Member Mark II
  • *****
  • Posts: 1,703
  • More turrets! MORE TURRETS!
Re: Context Menu
« Reply #7 on: October 10, 2011, 05:49:08 pm »
Thinking a little more, I am strongly opposed to removing the alt-right click binding.  Adding some sort of alternate keyboard binding is ok, but contextual menus are by their nature a mouse-related interface element; they are menus that have traditionally been brought up using the mouse showing a set of actions related to what you have selected or what you clicked on, and keyboard shortcuts for doing that are usually conveniences that have been added later and/or that no one uses.  Unless changing them to be something entirely different, that's just what they are, and taking that away from them is potentially even weirder and more confusing.  Having it not appear near your mouse cursor would also be a great way to make it unwieldy and slower to use.

Also, there's about a decade and a half of precedence for using a keyboard and mouse combination for bringing up contextual menus.  These days everyone has a multi-button mouse or a multitouch trackpad, but ctrl-click still brings up contextual menus in OS X (and sends a right click event in general, actually) as a legacy of the old days before that was true.  Way, way back in the day, I believe it was actually cmd-click, at least in some early web browsers before it was standardized system-wide.

I agree. I'm so used to using some sort of modifier in some manner or another for contextual menus, taking it out completely would suck. Maybe leave it in, but allow us to bind it to something, like a mouse button (For those of us with fancy multi-button mice.

Offline Nethris

  • Newbie Mark II
  • *
  • Posts: 22
Re: Context Menu
« Reply #8 on: October 11, 2011, 08:15:06 am »
I agree. I'm so used to using some sort of modifier in some manner or another for contextual menus, taking it out completely would suck. Maybe leave it in, but allow us to bind it to something, like a mouse button (For those of us with fancy multi-button mice.

Certainly don't take out the option to just use a modifier + click to open it up, even if a decent keyboard navigation option was added I don't think I'd be using it enough to bother, and if I'm going to be clicking options opening it with the mouse makes sense.

Unrelated to making changes to it, when I went to check what the heck was even in the contextual menus just now I found out that it lets you view ship modules and use the design screen to apply something to your entire selection - at least now if I ever bother leaving avengers on in a fallen spire game again replacing most of the modules on my entire fleet after they're nuked (and half the ships somehow get what they're supposed to be rebuilding wrong) will be much less annoying.

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Context Menu
« Reply #9 on: October 11, 2011, 08:59:28 am »
Sorry about the confusion on the open-with keybind: there's already two, one for key+right-click and another for just key.  The one for just the key is not bound by default, what I was thinking was giving it a default binding.  But it's not sounding like there's a big need for that.  Of course, part of why there's not a need is that there's not much need to actually use any part of the thing ;)  But that might change, we'll see.

Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Hearteater

  • Core Member
  • *****
  • Posts: 2,334
Re: Context Menu
« Reply #10 on: October 11, 2011, 10:25:30 am »
Are there that many true context sensitive commands?  Auto-Load is, but some seem to be selection sensitive.  That is, the command is based on what units you have selected and NOT where you actually click.  Anything that isn't context sensitive should really not be on the context menu from a UI design standpoint.  Galaxy Map layout for example.

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Context Menu
« Reply #11 on: October 11, 2011, 10:36:06 am »
Anything that isn't context sensitive should really not be on the context menu from a UI design standpoint.  Galaxy Map layout for example.
It's sensitive to the context of whether you're looking at the galaxy map :)
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline TechSY730

  • Core Member Mark V
  • *****
  • Posts: 4,570
Re: Context Menu
« Reply #12 on: October 11, 2011, 10:57:38 am »
Anything that isn't context sensitive should really not be on the context menu from a UI design standpoint.  Galaxy Map layout for example.
It's sensitive to the context of whether you're looking at the galaxy map :)

Actually, if you have units selected when you go into the galaxy map, then you get the unit context menu, not the galaxy map context menu. Not sure if this is a bug or intended.

Offline Nalgas

  • Hero Member
  • *****
  • Posts: 680
Re: Context Menu
« Reply #13 on: October 11, 2011, 10:58:36 am »
Are there that many true context sensitive commands?  Auto-Load is, but some seem to be selection sensitive.  That is, the command is based on what units you have selected and NOT where you actually click.

I just checked, and oddly enough, AI War has nearly the same behavior as Firefox in that sense, at least on the planetary map.  In Firefox, right-clicking the background (or any non-active/interactive element) with nothing selected brings up the generic context menu for the page.  Right-clicking the same places with something selected brings up the context menu for the selection, even if the click is not on or anywhere near the selection.  The only real difference is that right-clicking directly on something that has its own context menu will bring it up even if it's not selected, which is not true in AI War.  That is of course the most common way of using contextual menus, so it stands out as being weird, but all of the other behaviors are the same (regardless of whether or not they're correct, which is a different matter entirely).

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Context Menu
« Reply #14 on: October 11, 2011, 11:06:33 am »
Yea, to some extent "Context Menu" is... not a misnomer, really, as it really does look at the context to determine which menu to show you.  But the fact that it's contextual is not the reason we added it: we added it because we wanted to add more functions but had run out of keys.  The contextual organization just helps it provide access to those functions without filling your screen with several dozen buttons corresponding to every such function.

All that said: it opens next to your mouse cursor because the default way of interacting with it is your mouse cursor.  If it were keyboard-only then yea, it could just open in some corner.
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!