Skip to main content
The BetterHud Cursor Menu entry displays a visual menu where the player controls a cursor by looking around (pitch/yaw). This allows for free-form layouts that mimic a mouse-driven interface without actual mouse capture.

interactions

  1. Cursor Control: Player gaze controls the cursor. Looking right/left moves X, up/down moves Y.
  2. Detection: The cursor hits buttons defined by X/Y/Width/Height.
  3. Click: Pressing the confirmation key (default: Shift/Drop) clicks the button.

Configuration

This entry requires a corresponding BetterHud configuration (Image/Layout/Popup) to render the visuals. The extension provides cursor_x and cursor_y variables (0-100) to position the cursor image dynamically.
popupId
String
default:"cursor_menu"
The ID of the BetterHud popup to display.
buttons
List<Button>
Definitions of interactable buttons.
cursorSensitivity
Double
default:"1.0"
Multiplier for cursor movement speed relative to head movement.
yawRange
Double
default:"60.0"
Degrees of horizontal rotation for full screen width.
pitchRange
Double
default:"40.0"
Degrees of vertical rotation for full screen height.
showCursor
Boolean
default:"true"
Whether to calculate/show the cursor (true by default).
text
String
Optional title text to display.

Button Definition

buttonId
String
required
Unique ID for the button.
x
Double
Center X position (0-100%).
y
Double
Center Y position (0-100%).
width
Double
Size of the hit area width (percentage).
height
Double
Size of the hit area height (percentage).
text
String
Display text for the button.
triggers
List<Ref<TriggerableEntry>>
Actions to run when clicked.

BetterHud Setup

You must create valid BetterHud images, layouts, and popups that respond to the variables:
  • [cursor_x], [cursor_y]
  • [hovered_button] (ID of hovered button)
  • [button_ID_hovered] (1 if true, 0 if false)
cursor_layout:
  images:
    1:
      name: cursor_icon
      gui:
        x: "[cursor_x]"
        y: "[cursor_y]"
      conditions:
        - condition: "[hovered_button] != ''"
          image: cursor_hover_icon