# Controls Input comes from SDL3 gamepads, the keyboard and the mouse, merged into one Switch controller (`runtime/input.c`, `runtime/input_win.c`). Every connected gamepad is kept open and the game reads the one pressed last; a gamepad switched on in play is found within a second. Buttons are ORed; each stick takes the source with the larger deflection. Keys and mouse buttons count only while the game window is in the foreground. `NX2NAVI_INPUT=none` disables both (automated runs). `NX2NAVI_*` settings can also be set in `nx2navi.ini` next to the exe (`input = none`, `motion = 0`, `rumble = 0`); the environment overrides the file. `NX2NAVI_RUMBLE_STRENGTH` is the rumble strength in percent (0 to 300, default 130; 0 is the same as `rumble = 0`). `NX2NAVI_RUMBLE_CURVE` is the exponent applied to the amplitude before the strength (0.2 to 1.5, default 0.6; lower makes weak pulses stronger, 1 is linear). `NX2NAVI_RUMBLE_TRIGGERS=1` also drives the impulse triggers of an Xbox pad. `NX2NAVI_PAD_LAYOUT` (`pad_layout`, the *Button layout* row on the Controls tab, live) picks which face button is Switch A: - `nintendo`: by position, as on a Switch (the table below). - `xbox`: south A, east B, west X, north Y, as an Xbox pad labels them; on a PlayStation pad cross is A, circle B, square X, triangle Y. - `auto` (default): `nintendo` for a pad whose east button SDL reports labelled A (Switch Pro Controller, Nintendo-layout pads), `xbox` for the others. The log names the layout in effect (`input: gamepad layout ...`) and each gamepad's first press (`input: gamepad "...": first press`); the menu shows the layout under *Automatic*. The game's prompts show the Switch letters. The actions are the game's own, as its *Basic Controls* screen (Plus menu, System) names them: | Switch | Gamepad (by position, Nintendo layout) | Keyboard and mouse | Action in the world | |---|---|---|---| | Left stick | left stick | W A S D | move | | Right stick | right stick | mouse; arrow keys as a second source | camera | | A | east | E, Left Shift | actions (talk, open, pick up, climb, grab); held, dash | | B | south | Left Ctrl, Backspace | put away, cancel, back | | X | north | Space | jump | | Y | west | left mouse button | attack with the sword | | ZL | left trigger (over 50%) | right mouse button, Z | target (hold or toggle, the game's *Targeting Type* option) | | ZR | right trigger (over 50%) | F, X | use the selected item (slingshot, bow, boomerang, hookshot, bombs, bottles) | | L | left shoulder | Q | quick-select items; previous page in the game's menus | | R | right shoulder | R | quick-select items; next page in the game's menus | | Left stick click | left stick click | V | (not on the game's controls screen) | | Right stick click | right stick click | C, middle mouse button | reset the camera behind Link | | D-pad left | D-pad left | 1, O | play the ocarina | | D-pad up | D-pad up | 2 | put the accessory on or take it off | | D-pad right | D-pad right | 3, N | talk to Navi | | D-pad down | D-pad down | 4 | change boots | | Plus | Start | Tab | menu: items, equipment, collection, system | | Minus | Back | M | map | The game's *Swap Jump Controls* option trades B and X (jump on B, put away on X); the bindings stay on the Switch buttons, so Space then puts away and Left Ctrl jumps. Left Shift is A, so holding it dashes; E presses A once for talking and opening. Esc is unbound in the game; it opens the settings menu and releases the mouse cursor (see Mouse camera). Z and X duplicate ZL and ZR on neighbouring keys. The mouse wheel is unbound. The bindings are the tables of `input_map` in `runtime/input_map.c`: the keys (platform-neutral key ids) and one gamepad table per layout (gamepad inputs by position); `runtime/input_win.c` translates Win32 virtual keys and SDL buttons. ## Window keys | Key | Gamepad | Action | |---|---|---| | F1 or Esc | Minus and Plus together | open or close the settings menu; the game gets no input while it is open | | F10 | L3 + R3 (both stick clicks) | performance overlay: off, frame rate, full panel | | F11 | | borderless fullscreen on or off, saved to `nx2navi.ini` | The Minus+Plus combo never reaches the game. In the menu the arrow keys, the D-pad or the left stick move, Enter or A selects, Q and E or L and R switch tabs, Esc or B goes back (Switch button names, as in the table above). ## Remapping The *Controls* tab of the settings menu lists, under the button layout, every Switch button and the eight stick directions the keys drive (movement and camera), each with two key cells and a controller cell. Each row's description says what the button does in the game. Select a cell, press A or Enter, then press the new key, mouse button or controller button; Esc or five seconds without a press cancel, and a controller button cancels a key cell. Delete, Backspace or X clears the selected cell. A key another action has moves to the new one (the description names the action it left); a controller button swaps with the one it replaces. A remapped controller button is physical: from then on the face buttons (A B X Y) stay where they are in both layouts, until the buttons are put back as the layout in use has them or *Reset all buttons* is chosen. F1, F8, F10, F11 and Esc cannot be bound (the menu, the flight recorder and the window keep them). Punctuation keys are named by their place on a US keyboard; the menu shows the character the keyboard layout in use puts there. The tab writes `nx2navi.ini` lines, one per Switch button or stick direction: `bind_