Skip to content

spectator hud: add separate stats for land, air and naval army#7894

Open
NeYurii wants to merge 1 commit into
beyond-all-reason:masterfrom
NeYurii:landnavalair_val
Open

spectator hud: add separate stats for land, air and naval army#7894
NeYurii wants to merge 1 commit into
beyond-all-reason:masterfrom
NeYurii:landnavalair_val

Conversation

@NeYurii

@NeYurii NeYurii commented Jun 7, 2026

Copy link
Copy Markdown

Work done

In advanced spectator hud add separate metrics for land, air and naval army value.
Reason: there can be a lot of army value in ships or fighters, and with single metric it is hard to estimate real land army size.

Spanish and Chinese translation made with translator so possibly contains some errors.

Screenshots:

BEFORE:

image

AFTER:

image

@WatchTheFort

Copy link
Copy Markdown
Member

This widget is already a UX nightmare, we should be improving the UX, not exacerbating the problem.

@Azzurite

Azzurite commented Jun 7, 2026

Copy link
Copy Markdown
Contributor

When I started watching this game, I was impressed with this spectator interface. The literal only "UX" problem I see is that when you see it on a stream/video, you can't hover over it to get tooltips, and thus it is hard to know what the abbreviations stand for.

I think this is a great addition to it :)

@WatchTheFort What do you think is the UX problem with this spectator interface, and how would you improve it?

@Azzurite Azzurite left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is an optimization opportunity here, theoretically it is possible to completely remove the unitCache[..].armyUnits, cachedTotals[..].armyUnits and unitDefsToTrack.armyUnitDefs.

Instead, you can just have getOneStat return the sum cachedTotals[teamID].landArmyUnits + cachedTotals[teamID].airArmyUnits + cachedTotals[teamID].navalArmyUnits for the metricKeys.armyValue case.

Comment thread luaui/Widgets/gui_spectator_hud.lua Outdated
Comment thread luaui/Widgets/gui_spectator_hud.lua Outdated
@WatchTheFort

Copy link
Copy Markdown
Member

@WatchTheFort What do you think is the UX problem with this spectator interface, and how would you improve it?

You only know what the letters mean if you already know what the letters mean. A UI packed full of abbreviations and short forms is bad design, in any software.

@Azzurite

Azzurite commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

A UI packed full of abbreviations and short forms is bad design

You have kind of a point, however, I think your statement should be "is bad design for new users". As soon as you know what the abbreviations mean, they actually become good design, because it saves screen space, allowing you to see more of the action, while still identifying it clearly.

I know specialist software from my jobs that simply could not display everything on their screens if they didn't use abbreviations. Or look at pilot cockpits or the Apollo instruments. These interfaces are all perfectly clear to the ones trained on them and allow them to find the right information quickly.

I know from myself that I am perfectly fine spectating BAR matches with this interface. You can make the argument that the default should be something like

    Metal per Second
[=====<200%>===========]

  Total Metal Produced
[========<60%>=========]

   Army Value in Metal
[=========<0%>=========]

with an option to change to the abbreviations. But abbreviations are still a fine thing in some cases, which includes this one.

@Azzurite

Azzurite commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

(and anyway, I don't think this point is very relevant to this particular PR, there are already a lot of these bars and abbreviations, adding these ones does not make it particularly worse)

Comment thread language/en/interface.json Outdated
Comment thread language/en/interface.json Outdated
@NeYurii NeYurii force-pushed the landnavalair_val branch 3 times, most recently from 82b0843 to 2bb3dc4 Compare June 8, 2026 10:10
@NeYurii

NeYurii commented Jun 8, 2026

Copy link
Copy Markdown
Author

There is an optimization opportunity here, theoretically it is possible to completely remove the unitCache[..].armyUnits, cachedTotals[..].armyUnits and unitDefsToTrack.armyUnitDefs.

Instead, you can just have getOneStat return the sum cachedTotals[teamID].landArmyUnits + cachedTotals[teamID].airArmyUnits + cachedTotals[teamID].navalArmyUnits for the metricKeys.armyValue case.

Applied this changes.

This widget is already a UX nightmare, we should be improving the UX, not exacerbating the problem.

Maybe. But i can not imagine other ways to change it then make entirely new widget or move it to separate window (like in starcraft or something like). Even if at one point it will be changed, this still can be useful while we still dealing with this widget.
This change was asked by one tourney player, so i think it could be useful for many people.

@sprunk

sprunk commented Jun 8, 2026

Copy link
Copy Markdown
Collaborator

A UI packed full of abbreviations and short forms is bad design

You have kind of a point, however, I think your statement should be "is bad design for new users"

BAR's target audience is autists who love complexity, so adding a bunch of obscure sliders is actually excellent for attracting new users.

Comment thread luaui/Widgets/gui_spectator_hud.lua Outdated
@NeYurii NeYurii force-pushed the landnavalair_val branch from 2bb3dc4 to 2fda9b7 Compare June 8, 2026 14:33

@Azzurite Azzurite left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just tested it in game, and in the options for spectator hud mode "custom":

Image

The entries for the different new army values are missing.

The definition can be found in gui_options line 5001.

@NeYurii NeYurii force-pushed the landnavalair_val branch from 2fda9b7 to 6c0f05a Compare June 9, 2026 12:11
@NeYurii

NeYurii commented Jun 9, 2026

Copy link
Copy Markdown
Author

Just tested it in game, and in the options for spectator hud mode "custom":
Image

The entries for the different new army values are missing.

The definition can be found in gui_options line 5001.

Fixed this.
Would not it be better if options were added by each widget? I saw there addOption, but apparently it is only for custom widgets.

@Azzurite

Azzurite commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Would not it be better if options were added by each widget?

Definitely. I don't know anything about this part of the code. In my uneducated opinion, the optimal implementation would be to have the option widget call a function in the spectator HUD widget, which returns the definitions of all available options. The option widget would then only be responsible for rendering them and putting these options in the appropriate location. The spectator HUD widget can not know where to exactly put them.

It would be a very worthwhile refactoring, good idea!

@Azzurite Azzurite left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice addition :)

@WatchTheFort

Copy link
Copy Markdown
Member

@icexuick Can we please get a UX design overhaul for this widget? It is extremely unfriendly.

@icexuick

Copy link
Copy Markdown
Collaborator

@icexuick Can we please get a UX design overhaul for this widget? It is extremely unfriendly.

Yes, this will be added to the new UI rework.
For the time being, we might leave it be, even though I agree with all the letters/abbreviations being very poor/bad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants