Skip to content

Add mouse support to menus, dialogue and inventories - #1018

Open
Solessfir wants to merge 3 commits into
Try:masterfrom
Solessfir:menu-mouse
Open

Solessfir wants to merge 3 commits into
Try:masterfrom
Solessfir:menu-mouse

Conversation

@Solessfir

@Solessfir Solessfir commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Mouse support for the desktop UI, split into three commits so each can be reviewed on its own.

Game menus and journal

  • Menus use the same input path as touch (Add touch navigation for game menus #1014): left click activates the item under the pointer, sliders can be dragged (with the script step), right click still goes back.
  • Hovering selects items. Selection only changes when a different item is hovered, since it runs the item's select commands.
  • Hit test: the drawn text wins first, so shared rows such as Back and "More keys" pick the right item; otherwise the script box counts, so short entries (e.g. a one-letter save name) are easy to hit. Boxes without an explicit height use one text line, so neighbouring rows don't overlap. This also makes touch taps between rows more precise.
  • Journal: in a category list, hovering a quest highlights it and clicking opens it.
  • An arrow pointer is shown while a menu is open.
  • In fullscreen, mouse look restarts from the window center after closing a menu, dialogue or inventory, so the camera doesn't jump to where the pointer was left.

Dialogue choices

  • Hover highlights a choice, click picks it; clicking beside the choices does nothing. Right click still skips the current line.

Inventories

  • Hover selects a cell, left click uses or takes the item; clicking beside the grids does nothing.
  • In the player's own inventory, right click on an item drops one (repeating while held, like Space) and Shift+right click drops the stack. Elsewhere right click still closes the inventory.
  • While the inventory is open the mouse moves the pointer instead of the camera.

Gothic's [GAME] enableMouse=0 turns all of this off: no pointer, and a click confirms the current selection as before. Touch input does not depend on it.

@Solessfir

Copy link
Copy Markdown
Contributor Author

Custom pointer art needs Tempest support first: Try/Tempest#132. Until then this uses the system arrow.

@Solessfir Solessfir changed the title Add mouse support to game menus Add mouse support to menus, dialogue and inventories Oct 21, 2026
@Solessfir
Solessfir marked this pull request as ready for review October 21, 2026 12:57
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.

1 participant