Prototype/CustomInput
Basics
Used for custom keyboard shortcuts/keybindings in mods.
Properties
Inherits all properties from Prototype.
name
- See Prototype#name
Inherited from Prototype. It is also the name for the event that is raised when they key (combination) is pressed, see Tutorial:Script interfaces.
key_sequence
Type: Types/string
The default key sequence for this custom input.
- " + " is used to seperate two keys:
"ALT + G"
- "CONTROL" works, "CTRL" doesnt.
- "mouse-button-2" etc for mouse buttons
linked_game_control
Type: Types/string
Default: ""
When a custom-input is linked to a game control it won't show up in the control-settings GUI and will fire when the linked control is pressed. [1]
List of internal names of game controls
alt-zoom-in alt-zoom-out build build-ghost cancel-craft cancel-craft-5 cancel-craft-all change-active-quickbar clean-cursor close-gui confirm-message connect-train copy-entity-settings craft craft-5 craft-all cursor-split cycle-blueprint-backwards cycle-blueprint-forwards debug-reset-zoom debug-toggle-atlas-gui debug-toggle-autoplace-gui debug-toggle-basic debug-toggle-debug-settings debug-toggle-detailed debug-toggle-full disconnect-train drag-map drop-cursor editor-edit-entity-details editor-remove-entity editor-show-all-difficulties editor-show-easy-difficulty editor-show-hard-difficulty editor-show-normal-difficulty editor-tool-primary-action editor-tool-secondary-action fast-entity-split fast-entity-transfer focus-search inventory-split inventory-transfer kill-statistics larger-terrain-building-area logistic-networks mine mouse-button-1 mouse-button-2 mouse-button-3 mouse-button-n mouse-wheel-down mouse-wheel-left mouse-wheel-right mouse-wheel-up move-down move-left move-right move-up next-weapon open-character-gui open-gui open-item open-technology-gui paste-entity-settings pause-game pick-item pick-items place-tag previous-technology production-statistics quickbar-1 quickbar-10 quickbar-2 quickbar-3 quickbar-4 quickbar-5 quickbar-6 quickbar-7 quickbar-8 quickbar-9 remove-pole-cables reverse-rotate rotate select-for-blueprint select-for-cancel-deconstruct shoot-enemy shoot-selected show-info smaller-terrain-building-area smart-pipette stack-split stack-transfer toggle-blueprint-library toggle-console toggle-driving toggle-filter toggle-gui-debug toggle-map toggle-menu toggle-tips-and-tricks zoom-in zoom-out
Example to use the same key sequence as the clean-cursor hotkey:
key_sequence = ""
linked_game_control = "clean-cursor"
consuming
Type: Types/ConsumingType
Default: "none"
enabled
Type: Types/bool
Default: true
If this custom input is enabled. Disabled custom inputs exist but are not used by the game.