Changes

Jump to navigation Jump to search
no edit summary
Line 1: Line 1: −
{{../header}}
+
{{modding player guide header}}
   −
Some mods let you edit key bindings, which are controller/keyboard/mouse buttons which do something in-game. This page explains how to configure them.
+
Some mods let you edit key bindings, which are controller/keyboard/mouse buttons which do something in-game. This page explains how to configure them. (This works for any mod using SMAPI's standard APIs.)
    
==How to…==
 
==How to…==
 
===Configure a mod's bindings===
 
===Configure a mod's bindings===
# Install the mod ([[Modding:Player Guide/Getting Started|see help]]).
+
# Install the mod ([[Modding:Player Guide/Getting Started|see player guide]]).
 
# Run SMAPI at least once with the mod to let it generate its config file.
 
# Run SMAPI at least once with the mod to let it generate its config file.
# Edit <tt>config.json</tt> in the mod's folder with a text editor.
+
# Edit <samp>config.json</samp> in the mod's folder with a text editor.
# Change the key options using [[#Available bindings|the values below]]. (On Mac, make sure it doesn't change to curly quotes.)
+
# Change the key options using [[#Button codes|the values below]]. (On macOS, make sure it doesn't change to curly quotes.)
    
Note that some mods may not be configurable.
 
Note that some mods may not be configurable.
    
===Disable a mod's key binding===
 
===Disable a mod's key binding===
For mods using SMAPI 2.0+ features, you can use <tt>None</tt> to disable a key binding.
+
You can use <samp>"None"</samp> to disable a key binding.
    
===Find the code for a key===
 
===Find the code for a key===
[[#Available bindings|''Available bindings'']] below shows all available key codes, but sometimes it's not clear which one applies (e.g. for non-English keyboards). Here's how to check:
+
[[#Button codes|''Button codes'']] below shows all available codes, but sometimes it's not clear which one applies (''e.g.,'' for non-English keyboards). Here's how to check:
    
# Launch the game.
 
# Launch the game.
# In the SMAPI console window, enter the <tt>test_input</tt> command.
+
# In the SMAPI console window, enter the <samp>test_input</samp> command.
 
# In the game, press the keys you want to test.
 
# In the game, press the keys you want to test.
 
# The SMAPI console will list the codes for the keys it received.
 
# The SMAPI console will list the codes for the keys it received.
Line 32: Line 32:     
To add a new key:
 
To add a new key:
# Run the game once to generate the default <tt>config.json</tt> file.
+
# Run the game once to generate the default <samp>config.json</samp> file.
# Open the <tt>Mods/VirtualKeyboard/config.json</tt> file in a text editor.
+
# Open the <samp>Mods/VirtualKeyboard/config.json</samp> file in a text editor.
# Add new buttons to the <tt>buttons</tt> field in the same format.<br />''Tip: when you add a button, set its <tt>X</tt> value to the previous button + 96.''
+
# Add new buttons to the <samp>buttons</samp> field in the same format.<br />''Tip: when you add a button, set its <samp>X</samp> value to the previous button + 96.''
   −
==Reserved bindings==
+
==Button codes==
You can't use the key bound to the chat box in multiplayer (default {{key|T}}).
  −
 
  −
==Available bindings==
   
===Keyboard===
 
===Keyboard===
Keyboard bindings are supported by virtually all configurable mods.
  −
   
; common keys
 
; common keys
 
: {| class="wikitable"
 
: {| class="wikitable"
Line 49: Line 44:  
! description
 
! description
 
|-
 
|-
| <tt>A</tt> through <tt>Z</tt>
+
| <samp>A</samp> through <samp>Z</samp>
 
| The letter keys.
 
| The letter keys.
 
|-
 
|-
| <tt>D0</tt> through <tt>D9</tt>
+
| <samp>D0</samp> through <samp>D9</samp>
 
| The number keys.
 
| The number keys.
 
|-
 
|-
| <tt>Down</tt>, <tt>Left</tt>,<br /><tt>Right</tt>, <tt>Up</tt>
+
| <samp>Down</samp>, <samp>Left</samp>,<br /><samp>Right</samp>, <samp>Up</samp>
 
| The arrow keys.
 
| The arrow keys.
 
|-
 
|-
| <tt>F1</tt> through <tt>F24</tt>
+
| <samp>F1</samp> through <samp>F24</samp>
 
| The function keys.
 
| The function keys.
 
|-
 
|-
| <tt>Apps</tt>
+
| <samp>Apps</samp>
 
| The applications or menu ({{key|▤}}) key, typically located next to your right {{key|CTRL}} key.
 
| The applications or menu ({{key|▤}}) key, typically located next to your right {{key|CTRL}} key.
 
|-
 
|-
| <tt>Back</tt>
+
| <samp>Back</samp>
 
| The backspace ({{key|⌫}} or {{key|⟵}}) key.
 
| The backspace ({{key|⌫}} or {{key|⟵}}) key.
 
|-
 
|-
| <tt>CapsLock</tt>
+
| <samp>CapsLock</samp>
 
| The {{key|CAPS LOCK}} or {{key|⇪}} key.
 
| The {{key|CAPS LOCK}} or {{key|⇪}} key.
 
|-
 
|-
| <tt>Enter</tt>
+
| <samp>Enter</samp>
 
| The {{key|ENTER}} or {{key|↵}} key.
 
| The {{key|ENTER}} or {{key|↵}} key.
 
|-
 
|-
| <tt>Escape</tt>
+
| <samp>Escape</samp>
 
| The {{key|ESC}} key.
 
| The {{key|ESC}} key.
 
|-
 
|-
| <tt>LeftAlt</tt>, <tt>RightAlt</tt>
+
| <samp>LeftAlt</samp>, <samp>RightAlt</samp>
 
| The {{key|ALT}} keys.
 
| The {{key|ALT}} keys.
 
|-
 
|-
| <tt>LeftControl</tt>, <tt>RightControl</tt>
+
| <samp>LeftControl</samp>, <samp>RightControl</samp>
| The {{key|CTRL}} key.
+
| The {{key|CTRL}} keys.
 
|-
 
|-
| <tt>LeftShift</tt>, <tt>RightShift</tt>
+
| <samp>LeftShift</samp>, <samp>RightShift</samp>
 
| The {{key|SHIFT}} or {{key|⇧}} keys.
 
| The {{key|SHIFT}} or {{key|⇧}} keys.
 
|-
 
|-
| <tt>LeftWindows</tt>, <tt>RightWindows</tt>
+
| <samp>LeftWindows</samp>, <samp>RightWindows</samp>
 
| The Windows keys.
 
| The Windows keys.
 
|-
 
|-
| <tt>OemCloseBrackets</tt>
+
| <samp>OemCloseBrackets</samp>
 
| The {{key|]}} key.
 
| The {{key|]}} key.
 
|-
 
|-
| <tt>OemComma</tt>
+
| <samp>OemComma</samp>
 
| The {{key|,}} key.
 
| The {{key|,}} key.
 
|-
 
|-
| <tt>OemMinus</tt>
+
| <samp>OemMinus</samp>
 
| The {{key|-}} key.
 
| The {{key|-}} key.
 
|-
 
|-
| <tt>OemOpenBrackets</tt>
+
| <samp>OemOpenBrackets</samp>
 
| The {{key|[}} key.
 
| The {{key|[}} key.
 
|-
 
|-
| <tt>OemPeriod</tt>
+
| <samp>OemPeriod</samp>
 
| The {{key|.}} key.
 
| The {{key|.}} key.
 
|-
 
|-
| <tt>OemPipe</tt>
+
| <samp>OemPipe</samp>
 
| The {{key|&#124;}} key.
 
| The {{key|&#124;}} key.
 
|-
 
|-
| <tt>OemPlus</tt>
+
| <samp>OemPlus</samp>
 
| The {{key|+}} key.
 
| The {{key|+}} key.
 
|-
 
|-
| <tt>OemQuestion</tt>
+
| <samp>OemQuestion</samp>
 
| The {{key|?}} key on a US standard keyboard.
 
| The {{key|?}} key on a US standard keyboard.
 
|-
 
|-
| <tt>OemQuotes</tt>
+
| <samp>OemQuotes</samp>
 
| The {{key|'}} or {{key|"}} key on a US standard keyboard.
 
| The {{key|'}} or {{key|"}} key on a US standard keyboard.
 
|-
 
|-
| <tt>OemSemicolon</tt>
+
| <samp>OemSemicolon</samp>
 
| The {{key|;}} key on a US standard keyboard.
 
| The {{key|;}} key on a US standard keyboard.
 
|-
 
|-
| <tt>OemTilde</tt>
+
| <samp>OemTilde</samp>
 
| The {{key|~}} key on a US standard keyboard.
 
| The {{key|~}} key on a US standard keyboard.
 
|-
 
|-
| <tt>Space</tt>
+
| <samp>Space</samp>
 
| The space bar.
 
| The space bar.
 
|-
 
|-
| <tt>Tab</tt>
+
| <samp>Tab</samp>
| The {{key|TAB}} or {{key|
+
| The {{key|TAB}} key.
Subtract Subtract key
  −
Tab TAB key
  −
 
   
|}
 
|}
   Line 137: Line 129:  
! description
 
! description
 
|-
 
|-
| <tt>Numpad0</tt> through <tt>Numpad9</tt>
+
| <samp>Numpad0</samp> through <samp>Numpad9</samp>
 
| The numpad number keys.
 
| The numpad number keys.
 
|-
 
|-
| <tt>Add</tt>
+
| <samp>Add</samp>
 
| The {{key|+}} numpad key.
 
| The {{key|+}} numpad key.
 
|-
 
|-
| <tt>Subtract</tt>
+
| <samp>Subtract</samp>
 
| The {{key|-}} numpad key.
 
| The {{key|-}} numpad key.
 
|-
 
|-
| <tt>Divide</tt>
+
| <samp>Divide</samp>
 
| The {{key|/}} numpad key.
 
| The {{key|/}} numpad key.
 
|-
 
|-
| <tt>Multiply</tt>
+
| <samp>Multiply</samp>
 
| The {{key|*}} numpad key.
 
| The {{key|*}} numpad key.
 
|-
 
|-
| <tt>NumLock</tt>
+
| <samp>NumLock</samp>
 
| The numeric lock, {{key|NUMLOCK}}, {{key|NUMLK}}, or {{key|NUM}} key.
 
| The numeric lock, {{key|NUMLOCK}}, {{key|NUMLK}}, or {{key|NUM}} key.
 
|}
 
|}
Line 162: Line 154:  
! description
 
! description
 
|-
 
|-
| <tt>Delete</tt>
+
| <samp>Delete</samp>
 
| The {{key|DEL}} key.
 
| The {{key|DEL}} key.
 
|-
 
|-
| <tt>End</tt>
+
| <samp>End</samp>
 
| The {{key|END}} key.
 
| The {{key|END}} key.
 
|-
 
|-
| <tt>Insert</tt>
+
| <samp>Insert</samp>
 
| The {{key|INS}} key.
 
| The {{key|INS}} key.
 
|-
 
|-
| <tt>PageDown</tt>, <tt>PageUp</tt>
+
| <samp>PageDown</samp>, <samp>PageUp</samp>
 
| The {{key|PAGE UP}} and {{key|PAGE DOWN}} keys.
 
| The {{key|PAGE UP}} and {{key|PAGE DOWN}} keys.
 
|-
 
|-
| <tt>Pause</tt>
+
| <samp>Pause</samp>
 
| The {{key|PAUSE}} key.
 
| The {{key|PAUSE}} key.
 
|-
 
|-
| <tt>PrintScreen</tt>
+
| <samp>PrintScreen</samp>
 
| The {{key|PRT SCR}} key.
 
| The {{key|PRT SCR}} key.
 
|-
 
|-
| <tt>Scroll</tt>
+
| <samp>Scroll</samp>
 
| The {{key|SCR LK}} key.
 
| The {{key|SCR LK}} key.
 
|}
 
|}
Line 192: Line 184:  
! description
 
! description
 
|-
 
|-
| <tt>BrowserBack</tt>
+
| <samp>BrowserBack</samp>
 
| The browser back key.
 
| The browser back key.
 
|-
 
|-
| <tt>BrowserFavorites</tt>
+
| <samp>BrowserFavorites</samp>
 
| The browser favorites key.
 
| The browser favorites key.
 
|-
 
|-
| <tt>BrowserForward</tt>
+
| <samp>BrowserForward</samp>
 
| The browser forward key.
 
| The browser forward key.
 
|-
 
|-
| <tt>BrowserHome</tt>
+
| <samp>BrowserHome</samp>
 
| The browser start and home key.
 
| The browser start and home key.
 
|-
 
|-
| <tt>BrowserRefresh</tt>
+
| <samp>BrowserRefresh</samp>
 
| The browser refresh key.
 
| The browser refresh key.
 
|-
 
|-
| <tt>BrowserSearch</tt>
+
| <samp>BrowserSearch</samp>
 
| The browser search key.
 
| The browser search key.
 
|-
 
|-
| <tt>BrowserStop</tt>
+
| <samp>BrowserStop</samp>
 
| The browser stop key.
 
| The browser stop key.
 
|-
 
|-
| <tt>ChatPadGreen</tt>
+
| <samp>ChatPadGreen</samp>
 
| The green ChatPad key.
 
| The green ChatPad key.
 
|-
 
|-
| <tt>ChatPadOrange</tt>
+
| <samp>ChatPadOrange</samp>
 
| The orange ChatPad key.
 
| The orange ChatPad key.
 
|-
 
|-
| <tt>Crsel</tt>
+
| <samp>Crsel</samp>
 
| The cursor select key.
 
| The cursor select key.
 
|-
 
|-
| <tt>Decimal</tt>
+
| <samp>Decimal</samp>
 
| The decimal key.
 
| The decimal key.
 
|-
 
|-
| <tt>EraseEof</tt>
+
| <samp>EraseEof</samp>
 
| The erase EOF key.
 
| The erase EOF key.
 
|-
 
|-
| <tt>Execute</tt>
+
| <samp>Execute</samp>
 
| The execute key.
 
| The execute key.
 
|-
 
|-
| <tt>Exsel</tt>
+
| <samp>Exsel</samp>
 
| The execute selection key.
 
| The execute selection key.
 
|-
 
|-
| <tt>Help</tt>
+
| <samp>Help</samp>
 
| The help key.
 
| The help key.
 
|-
 
|-
| <tt>Home</tt>
+
| <samp>Home</samp>
 
| The home key.
 
| The home key.
 
|-
 
|-
| <tt>ImeConvert</tt>
+
| <samp>ImeConvert</samp>
 
| The IME convert key.
 
| The IME convert key.
 
|-
 
|-
| <tt>ImeNoConvert</tt>
+
| <samp>ImeNoConvert</samp>
 
| The IME no-convert key.
 
| The IME no-convert key.
 
|-
 
|-
| <tt>Kana</tt>
+
| <samp>Kana</samp>
 
| The Kana key on Japanese keyboards.
 
| The Kana key on Japanese keyboards.
 
|-
 
|-
| <tt>Kanji</tt>
+
| <samp>Kanji</samp>
 
| The Kanji key on Japanese keyboards.
 
| The Kanji key on Japanese keyboards.
 
|-
 
|-
| <tt>LaunchApplication1</tt>
+
| <samp>LaunchApplication1</samp>
 
| The Start Application 1 key.
 
| The Start Application 1 key.
 
|-
 
|-
| <tt>LaunchApplication2</tt>
+
| <samp>LaunchApplication2</samp>
 
| The Start Application 2 key.
 
| The Start Application 2 key.
 
|-  
 
|-  
| <tt>LaunchMail</tt>
+
| <samp>LaunchMail</samp>
 
| The Start Mail key.
 
| The Start Mail key.
 
|-
 
|-
| <tt>MediaNextTrack</tt>
+
| <samp>MediaNextTrack</samp>
 
| The Next Track key.
 
| The Next Track key.
 
|-
 
|-
| <tt>MediaPlayPause</tt>
+
| <samp>MediaPlayPause</samp>
 
| The Play/Pause Media key.
 
| The Play/Pause Media key.
 
|-
 
|-
| <tt>MediaPreviousTrack</tt>
+
| <samp>MediaPreviousTrack</samp>
 
| The Previous Track key.
 
| The Previous Track key.
 
|-
 
|-
| <tt>MediaStop</tt>
+
| <samp>MediaStop</samp>
 
| The Stop Media key.
 
| The Stop Media key.
 
|-
 
|-
| <tt>Oem8</tt>
+
| <samp>Oem8</samp>
 
| Varies by keyboard.
 
| Varies by keyboard.
 
|-
 
|-
| <tt>OemAuto</tt>
+
| <samp>OemAuto</samp>
 
| OEM Auto key.
 
| OEM Auto key.
 
|-
 
|-
| <tt>OemBackslash</tt>
+
| <samp>OemBackslash</samp>
 
| The The OEM angle bracket or backslash key on the RT 102 key keyboard.
 
| The The OEM angle bracket or backslash key on the RT 102 key keyboard.
 
|-
 
|-
| <tt>OemClear</tt>
+
| <samp>OemClear</samp>
 
| The OEM clear key.
 
| The OEM clear key.
 
|-
 
|-
| <tt>OemCopy</tt>
+
| <samp>OemCopy</samp>
 
| The OEM copy key.
 
| The OEM copy key.
 
|-
 
|-
| <tt>OemEnlW</tt>
+
| <samp>OemEnlW</samp>
 
| The OEM Enlarge Window key.
 
| The OEM Enlarge Window key.
 
|-
 
|-
| <tt>PA1</tt>
+
| <samp>PA1</samp>
 
| The PA1 key.
 
| The PA1 key.
 
|-
 
|-
| <tt>Play</tt>
+
| <samp>Play</samp>
 
| The play key.
 
| The play key.
 
|-
 
|-
| <tt>Print</tt>
+
| <samp>Print</samp>
 
| The {{key|PRINT}} key.
 
| The {{key|PRINT}} key.
 
|-
 
|-
| <tt>ProcessKey</tt>
+
| <samp>ProcessKey</samp>
 
| The IME process key.
 
| The IME process key.
 
|-
 
|-
| <tt>Select</tt>
+
| <samp>Select</samp>
 
| The select key.
 
| The select key.
 
|-
 
|-
| <tt>SelectMedia</tt>
+
| <samp>SelectMedia</samp>
 
| The select media key.
 
| The select media key.
 
|-
 
|-
| <tt>Separator</tt>
+
| <samp>Separator</samp>
 
| The separator key.
 
| The separator key.
 
|-
 
|-
| <tt>Sleep</tt>
+
| <samp>Sleep</samp>
 
| The computer sleep key.
 
| The computer sleep key.
 
|-
 
|-
| <tt>VolumeDown</tt>, <tt>VolumeUp</tt>
+
| <samp>VolumeDown</samp>, <samp>VolumeUp</samp>
 
| The volume down/up keys.
 
| The volume down/up keys.
 
|-
 
|-
| <tt>VolumeMute</tt>
+
| <samp>VolumeMute</samp>
 
| The volume mute keys.
 
| The volume mute keys.
 
|-
 
|-
| <tt>Zoom</tt>
+
| <samp>Zoom</samp>
 
| The zoom key.
 
| The zoom key.
 
|}
 
|}
    
===Controller===
 
===Controller===
Controller bindings are supported by mods using SMAPI 2.0+ features, and some older mods.
  −
   
{| class="wikitable"
 
{| class="wikitable"
 
|-
 
|-
Line 333: Line 323:  
! description
 
! description
 
|-
 
|-
| <tt>ControllerA</tt>, <tt>ControllerB</tt>,<br /><tt>ControllerX</tt>, <tt>ControllerY</tt>
+
| <samp>ControllerA</samp>, <samp>ControllerB</samp>,<br /><samp>ControllerX</samp>, <samp>ControllerY</samp>
 
| The main buttons.
 
| The main buttons.
 
|-
 
|-
| <tt>ControllerBack</tt>
+
| <samp>ControllerBack</samp>
 
| The 'BACK' button on an XBox controller.
 
| The 'BACK' button on an XBox controller.
 
|-
 
|-
| <tt>ControllerStart</tt>
+
| <samp>ControllerStart</samp>
 
| The 'START' button.
 
| The 'START' button.
 
|-
 
|-
| <tt>BigButton</tt>
+
| <samp>BigButton</samp>
 
| The 'big button' on the XBox Big Button controller.
 
| The 'big button' on the XBox Big Button controller.
 
|-
 
|-
| <tt>DPadDown</tt>, <tt>DPadLeft</tt><br /><tt>DPadRight</tt>, <tt>DPadUp</tt>
+
| <samp>DPadDown</samp>, <samp>DPadLeft</samp><br /><samp>DPadRight</samp>, <samp>DPadUp</samp>
 
| The directional pad buttons.
 
| The directional pad buttons.
 
|-
 
|-
| <tt>LeftShoulder</tt>, <tt>RightShoulder</tt>
+
| <samp>LeftShoulder</samp>, <samp>RightShoulder</samp>
| The bumper (shoulder) buttons.
+
| The bumper (shoulder) buttons.
 +
|-
 +
| <samp>LeftTrigger</samp>, <samp>RightTrigger</samp>
 +
| The trigger buttons.
 
|-
 
|-
| <tt>LeftStick</tt>, <tt>RightStick</tt>
+
| <samp>LeftStick</samp>, <samp>RightStick</samp>
| The left/right thumbsticks when pressed as a button.
+
| The left/right thumbsticks when clicked or pressed as a button.
 
|-
 
|-
| <tt>LeftThumbstickDown</tt>, <tt>LeftThumbstickLeft</tt>,<br /><tt>LeftThumbstickRight</tt>, <tt>LeftThumbstickUp</tt>
+
| <samp>LeftThumbstickDown</samp>, <samp>LeftThumbstickLeft</samp>,<br /><samp>LeftThumbstickRight</samp>, <samp>LeftThumbstickUp</samp>
 
| The left thumbstick when pushed in a direction.
 
| The left thumbstick when pushed in a direction.
 
|-
 
|-
| <tt>LeftTrigger</tt>, <tt>RightTrigger</tt>
+
| <samp>RightThumbstickDown</samp>, <samp>RightThumbstickLeft</samp>,<br /><samp>RightThumbstickRight</samp>, <samp>RightThumbstickUp</samp>
| The trigger buttons.
  −
|-
  −
| <tt>RightThumbstickDown</tt>, <tt>RightThumbstickLeft</tt>,<br /><tt>RightThumbstickRight</tt>, <tt>RightThumbstickUp</tt>
   
| The right thumbstick when pushed in a direction.
 
| The right thumbstick when pushed in a direction.
 
|}
 
|}
    
===Mouse===
 
===Mouse===
Mouse bindings are supported by mods using SMAPI 2.0+ features.
  −
   
{| class="wikitable"
 
{| class="wikitable"
 
|-
 
|-
Line 372: Line 360:  
! description
 
! description
 
|-
 
|-
| <tt>MouseLeft</tt>
+
| <samp>MouseLeft</samp>
 
| The left mouse button.
 
| The left mouse button.
 
|-
 
|-
| <tt>MouseRight</tt>
+
| <samp>MouseRight</samp>
 
| The right mouse button.
 
| The right mouse button.
 
|-
 
|-
| <tt>MouseMiddle</tt>
+
| <samp>MouseMiddle</samp>
 
| The middle mouse button.
 
| The middle mouse button.
 
|-
 
|-
| <tt>MouseX1</tt>, <tt>MouseX2</tt>
+
| <samp>MouseX1</samp>, <samp>MouseX2</samp>
 
| The extended mouse buttons (varies by mouse).
 
| The extended mouse buttons (varies by mouse).
 
|}
 
|}
    
===Mobile===
 
===Mobile===
Mobile device bindings are supported by mods using SMAPI 2.0+ features.
  −
   
{| class="wikitable"
 
{| class="wikitable"
 
|-
 
|-
Line 393: Line 379:  
! description
 
! description
 
|-
 
|-
| <tt>VolumeUp</tt>, <tt>VolumeDown</tt>
+
| <samp>VolumeUp</samp>, <samp>VolumeDown</samp>
 
| The volume up/down buttons.
 
| The volume up/down buttons.
 
|}
 
|}
   −
==For modders==
+
==Device mappings==
These constants are part of the [[Modding:Modder Guide/APIs/Input|SMAPI input events]], specifically SMAPI's <tt>SButton</tt> enum which unifies controller, keyboard, and mouse buttons.
+
===Steam Deck===
 +
The Steam deck is mapped as a controller (see [[#Controller|controller codes]]), and you can remap buttons using Steam Input. Here's how the different Steam Deck buttons are mapped by default:
 +
 
 +
{| class="wikitable"
 +
|-
 +
! button
 +
! mapped as
 +
|-
 +
| A, B, X, Y<br />left/right shoulder<br />left/right trigger buttons<br />left/right thumbstick<br />D-Pad<br />Start<br />Select
 +
| Sends the equivalent controller codes.
 +
|-
 +
| left touchpad
 +
| Sends equivalent D-Pad codes when touching the edges (e.g. left edge is <samp>DPadLeft</samp>).
 +
|-
 +
| right touchpad
 +
| Sends right thumbstick codes.
 +
|-
 +
| 'Back grip' buttons (L4, L5, R4, R5)
 +
| Not sent to the game by default, unless mapped to a key in Steam Input.
 +
|-
 +
| {{key|Steam}}<br />{{key|...}}
 +
| Not sent to the game.
 +
|}
 +
 
 +
You can also rebind physical keys in the Steam Deck settings:
 +
# Go to ''Controller Settings > Edit Layout''.
 +
# Choose the button to rebind.
 +
# Choose ''Command Page > Keyboard''.
 +
# Choose the keyboard button to bind it to.
 +
# Now when you press that physical button in-game, it'll send the new keyboard code instead.
 +
 
 +
==Multi-key bindings==
 +
Mods using SMAPI 3.9+ features can support multi-key bindings. That lets you combine multiple [[#Button codes|button codes]] into a combo keybind, and list alternate keybinds. For example, <code>"LeftShoulder, LeftControl + S"</code> will apply if <samp>LeftShoulder</samp> is pressed, ''or'' if both <samp>LeftControl</samp> and <samp>S</samp> are pressed.
 +
 
 +
Some things to keep in mind:
 +
* The order doesn't matter, so <code>"LeftControl + S"</code> and <code>"S + LeftControl"</code> are equivalent.
 +
* SMAPI doesn't prevent mods from using overlapping hotkeys. For example, if one mod uses <code>"S"</code> and the other mod uses <code>"LeftControl + S"</code>, pressing <samp>LeftControl</samp> and <samp>S</samp> will activate both.
    
==See also==
 
==See also==
 
* [[Controls]] for the game's default bindings
 
* [[Controls]] for the game's default bindings
 +
* [[Modding:Modder Guide/APIs/Input|SMAPI input events]] for mod authors
 +
 +
[[Category:Modding]]
    
[[de:Modding:Spieleranleitung/Tastenbelegung]]
 
[[de:Modding:Spieleranleitung/Tastenbelegung]]
 +
[[es:Modding:Guía del jugador/Enlaces de teclas]]
 +
[[zh:模组:使用指南/按键绑定]]
105,831

edits

Navigation menu