Author Topic: Optional extra buttons  (Read 1187 times)

Offline tkzv

  • Commander
  • *****
  • Posts: 586
    • View Profile
Optional extra buttons
« on: July 23, 2018, 12:32:38 am »
Right now my desktop doesn't work and I only have a notebook and a tab. Lack of the middle mouse button — or of the whole keyboard — makes the game much more frustrating. OXCE+ has a lot of useful functions called from keyboard, such as Ufopaedia, results of the last shot, mission briefing, debug(;D). Also there are left-click, right-click, middle-click, Ctrl-left-click, Shift-left-click... did I miss anything?

Has anybody suggested adding extra icons/buttons to the interface yet?

What I suggest isn't expanding the classic bottom toolbar, but adding extra buttons on the sides (disabled by default). The buttons would correspond not to actions, but exactly to keyboard keys — thus no need for new icons, and the engine would handle it as a pressed key. Some of the buttons would be prefixes such as Ctrl or Shift, or turning clicks into right-clicks or middle-clicks.

Is anybody planning something like that?

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5061
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: Optional extra buttons
« Reply #1 on: July 23, 2018, 12:40:33 am »
When drawing any mockup, please draw it in original resolution/scale.
You'll realize how much less space there is to actually do things... not saying no here... just that it needs a better idea, because this one doesn't work in original resolution/scale.

Offline tkzv

  • Commander
  • *****
  • Posts: 586
    • View Profile
Re: Optional extra buttons
« Reply #2 on: July 23, 2018, 08:10:58 am »
Here's how standard buttons look at 640x400 with common\Language\FontSmall.png
I think 9 should be enough for most common actions.

Or should I double the font size too?

Update: doubled it.

Update 2: Here are the buttons used for switching between enemies. Top one uses FontSmall.png, 2nd from top uses double FontSmall.png
« Last Edit: July 23, 2018, 08:40:13 am by tkzv »

Offline KZad Bhat

  • Colonel
  • ****
  • Posts: 185
    • View Profile
Re: Optional extra buttons
« Reply #3 on: July 24, 2018, 12:10:52 am »
Tablets even have the advantage that almost all of them, and probably any of them powerful enough to handle OXC or its branches, of having a higher resolution than 640x400 (or 480). So another consideration is to determine what will be the standard minimum resolution assumed for the tablet versions, and you know you have at least that to work with. It can allow you to put buttons outside and around the interface.

Offline NKF

  • Sergeant
  • **
  • Posts: 35
    • View Profile
Re: Optional extra buttons
« Reply #4 on: July 25, 2018, 02:22:05 pm »
This thread has got some long dormant gears in my head turning. I am just doing a bit of an idea dump here while it is still fresh in my mind. It might be able to provide a theoretical solution for the extra buttons (or perhaps less buttons) 

While I really like the ability OpenXcom to use a variety of resolutions, I've always been bothered by the fact that the user interface does not scale with the resolution. Fair enough as the original UI graphics were built for the good old 320x200. But you do end up with these really tiny buttons at higher resolutions, and I'm honestly not a fan of any game interface where I have to squint to see what I'm clicking. Just exaggerating a bit here as it is not that bad with the X-Com games.   

I don't know if this will line up with the direction intended for OpenXcom, but the idea I've been entertaining is a sort of custom UI system. It would work in place of but not completely replace the original. That needs to stay especially as a fall-back interface in case things go wrong.

The idea is to have a user interface text file where the user can define their own buttons, information displays, button groupings (TU reserve buttons). Specify how they look ( from the default graphics set or from a user supplied texture file), their dimensions, whether they scale with screen resolution, etc and most importantly link them to the relevant game functions. Then populate the screen with the instances of the buttons and where they appear on screen.

The person designing the interface would have to take care that all necessary functions are displayed.

One important consideration would be to define the button area. The classic user interface gutter along the side or bottom of the screen, or use the entire screen and allow floating buttons and other elements that can be positioned anywhere. Not necessarily at run-time unless you want to throw in grab handles as well (think: Ultima 7 or 8 inventory screens or Planescape Torment's radial menu). Although that might be overdoing it a little.

Something like this would potentially allow for users to build custom UI mod packs for their chosen resolution or device. It would provide an easy way to introduce and try out new interface elements with different ways of presenting information. Compact unit stat displays for example, shorter or vertical bars, or even do something unusual like a radial percentage clock, etc. But I digress.
« Last Edit: July 25, 2018, 02:27:48 pm by NKF »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5061
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: Optional extra buttons
« Reply #5 on: July 25, 2018, 02:33:01 pm »
Tablets even have the advantage that almost all of them, and probably any of them powerful enough to handle OXC or its branches, of having a higher resolution than 640x400 (or 480). So another consideration is to determine what will be the standard minimum resolution assumed for the tablet versions, and you know you have at least that to work with. It can allow you to put buttons outside and around the interface.

PCs have even more power than tablets... I don't see how tablets should have any advantage.
We design for 320x200, because that's the smallest resolution we officially support (and most likely will continue supporting forever).

<snip>

Xracer started something similar, there is a thread somewhere on the forum about it.
He eventually gave up.

It would take one very dedicated developer about 2 years to develop... I'll pass.

Offline Kammerer

  • Colonel
  • ****
  • Posts: 133
    • View Profile
Re: Optional extra buttons
« Reply #6 on: July 25, 2018, 05:41:08 pm »
If anyone's interested, the HD mod branch is available here: https://github.com/Xracer/OXCHD. The in-game samples are there: https://openxcom.org/forum/index.php/topic,1558.100.html
« Last Edit: July 25, 2018, 05:45:05 pm by Kammerer »

Offline KZad Bhat

  • Colonel
  • ****
  • Posts: 185
    • View Profile
Re: Optional extra buttons
« Reply #7 on: July 25, 2018, 07:56:33 pm »
I was just responding to the point of tkzv doing his mockup in 640x480. But as I said, any tablet that can handle this at all will have a higher resolution than that anyway. The can provide so extra possible space to work with to place extra buttons the actual playfield.

Offline tkzv

  • Commander
  • *****
  • Posts: 586
    • View Profile
Re: Optional extra buttons
« Reply #8 on: July 26, 2018, 12:25:52 am »
We design for 320x200, because that's the smallest resolution we officially support (and most likely will continue supporting forever).
Then ignore the 1st screenshot and the top button on the 3rd. This is my suggestion with existing sprites and fonts at 320x200 doubled.

P.S. Or do you want a 320x200 mockup?
By the way, why isn't the 320x200 choice available in video options? I only saw 320x240 and 320x180. Typing it manually works.
« Last Edit: July 26, 2018, 12:39:33 am by tkzv »

Offline Meridian

  • Global Moderator
  • Commander
  • *****
  • Posts: 5061
  • Aaand we're back!
    • View Profile
    • My Wiki
Re: Optional extra buttons
« Reply #9 on: July 27, 2018, 09:50:00 pm »
By the way, why isn't the 320x200 choice available in video options? I only saw 320x240 and 320x180. Typing it manually works.

The choices are given by the resolutions supported by your video card... they are different for everyone... and are just suggestions, you can type manually anything you like (bigger or equal to 320x200).

Offline tkzv

  • Commander
  • *****
  • Posts: 586
    • View Profile
Re: Optional extra buttons
« Reply #10 on: July 28, 2018, 03:50:54 pm »
Anyway, here are 320x200 mockups: