Skip to content

Improve gameplay HUD and minimap navigation - #227

Open
Rokk001 wants to merge 32 commits into
tomluchowski:shaders-improvementfrom
Rokk001:pr/gameplay-hud-navigation-complete
Open

Rokk001 wants to merge 32 commits into
tomluchowski:shaders-improvementfrom
Rokk001:pr/gameplay-hud-navigation-complete

Conversation

@Rokk001

@Rokk001 Rokk001 commented Sep 27, 2026 •

Copy link
Copy Markdown

Unify the gameplay HUD around a resource strip, distinct active categories, adaptive action-icon sizing and compact paging. Keep the minimap controls outside the circular map and preserve contextual selection behavior.

The selected room now remains visibly highlighted in the Rooms navigation until the action changes. Review the follow-up.

Depends on #215, #226 and #161: the selected-room highlight uses the room-listing helper introduced by #161, so #161 must be merged first. Validation: the focused selected-room probe passes 728 checks; earlier HUD and minimap checks remain unchanged. No new full-game or other-platform run is claimed.


Supersedes #95, closed and force-pushed by mistake; recreated with the same content and cleaned-up commit trailers.

Rokk001 and others added 27 commits September 7, 2026 00:45
Embed per-monitor DPI awareness and maintain the verified OGRE 13.6.5 renderer patch required for context-safe window replacement, runtime GL options and correct fullscreen client geometry.

Validation: clean Release build, DPI and 3440x1440 fullscreen probes, three GL3Plus variants and the patch reverse check passed; version 0.7.1 remains unchanged because this is unreleased work and the project has no changelog.
Apply display, input, audio, gameplay, minimap, shadow and negotiated nickname changes to the running session while preserving rollback for failed window or input transitions and keeping the 3440x1440 navigation visible.

Validation: clean Release and Debug builds, packet tests, DPI, layout and GL3Plus probes passed; the user confirmed the reported resolution, fullscreen, cursor, flicker and navigation failures are fixed. Version 0.7.1 remains unchanged because this is unreleased work and the project has no changelog.
The spells tab put its ten buttons in a single row of 60 pixel squares running
out to x=700. The pane they live in is the window width minus the 200 pixels of
minimap, so at the 800 wide minimum window it is 600 pixels across, and the last
two spells, Weakness and the Eye of Evil, hung past its right edge where they
could be neither seen nor clicked. Only a window at least 900 wide showed the
whole row, and nothing said so.

The rooms tab solved the same problem long ago: two rows of 40 pixel buttons.
The spells tab now uses the same shape, five spells to a row, ending at x=300
with room to spare at any size the game accepts. The cooldown bar inside each
button now covers exactly its button too, instead of overhanging 20 pixels on
both sides, which with narrower buttons would have bled half way across the
neighbours.

The rooms tab had the tail of the same bug: the temple and portal buttons the
editor uses sat at x=570 to 690, past the same edge. They join the end of the
second row instead.

(cherry picked from commit 10db1cb)
This packages the accepted implementation without private development notes. No release version or changelog change is required for this unreleased contribution.
# Conflicts:
#	gui/OD.looknfeel
#	gui/WindowTabRooms.layout
#	gui/WindowTabSpells.layout
Replace the auto declarations introduced by this branch with explicit types,
as requested in issue tomluchowski#42 and required by the project coding guidelines. No behavioural change.
Replace the auto declarations introduced by this branch with explicit types,
as requested in issue tomluchowski#42 and required by the project coding guidelines. No behavioural change.
@Rokk001

Rokk001 commented Sep 27, 2026

Copy link
Copy Markdown
Author

Comment from the original #95 by @Rokk001 (source):

Fixed in 12331099: the selected room remains highlighted in navigation.

The minimap corner buttons and the production and skill buttons are
AlwaysOnTop, so the full map window could be drawn below them. Make the
map window AlwaysOnTop as well.
The gameplay HUD work highlights the selected room button by walking the
room buttons with SkillManager::listAllRooms, which is introduced by the
room navigation cycling branch. Stack this branch on top of it so it
builds on its own.

Conflicts resolved so that both features survive:
- source/game/SkillManager.cpp: both branches appended a new function at
  the end of the file. Keep getSelectedButton() from this branch and
  listAllRooms() from the room navigation branch, one after the other.
- source/modes/GameMode.cpp (constructor): keep the Query, Sell, panel
  toggle and events button handlers from this branch and add the
  right-click room focus handlers from the room navigation branch after
  them.
- source/modes/GameMode.h: keep <memory> from this branch and add <map>,
  which the per-room focus index map from the room navigation branch
  needs.
The HUD streamed the raw double mana value into the ManaDisplay widget,
which showed up to three decimal places (e.g. 12.345). Cast it to long
like the mana income and upkeep labels next to it.
Split the generated navigation artwork into named functions with a shared
image helper and a segment test instead of repeated lambdas, replace the
remaining lambdas and nested conditionals with named handlers, share the
action toggle, name the layout and frame constants, group the action button
arrangement, guard the glyph and parent lookups against null, and drop a
duplicated include.

This branch has not been deployed

No deployments
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.

2 participants