-
Notifications
You must be signed in to change notification settings - Fork 178
SMODS.Keybind
N edited this page Mar 24, 2026
·
3 revisions
-
Required parameters:
-
key_pressed: The key that needs to be pressed for this keybind to activate. Keycodes are documented here. -
action(self): Function to be called when the keybind is triggered.
-
-
Optional parameters (defaults):
-
prefix_config, dependencies(reference) -
event = 'pressed': Defines when the keybind should trigger.-
'pressed': When the key is pressed. -
'released': When the key is released. -
'held': When the key has been held for a specified amount of time.
-
-
held_duration = 1: How long (in seconds) the key must be held before triggering whenevent == 'held'. -
held_keys = {}: Set of keycodes that must also be pressed for the keybind to activate. -
key: Because there is no need to explicitly refer to a keybind elsewhere, it is not required to specify an object key here. The default value is the amount of previously registered keybinds as a string.
-
Game Objects
- API Documentation
- SMODS.Achievement
- SMODS.Atlas
- SMODS.Attribute
- SMODS.Blind
- SMODS.CanvasSprite
- SMODS.Center
- SMODS.Challenge
- SMODS.DeckSkin
- SMODS.DrawStep
- SMODS.DynaTextEffect
- SMODS.Font
- SMODS.Gradient
- SMODS.https
- SMODS.JimboQuip
- SMODS.Keybind
- SMODS.Language
- SMODS.ObjectType and SMODS.ConsumableType
- SMODS.PokerHand
- SMODS.Rank and SMODS.Suit
- SMODS.Rarity
- SMODS.Scoring_Parameter and SMODS.Scoring_Calculation
- SMODS.Seal
- SMODS.Shader and SMODS.ScreenShader
- SMODS.Sound
- SMODS.Stake
- SMODS.Sticker
- SMODS.Tag
Guides
- Your First Mod
- Mod Metadata
- The Mod Object
- Calculate Functions
- Perma-bonuses
- Object Weights
- Logging
- Event Manager
- Localization
- Text Styling
- UI Structure
- Utility Functions
- All About
G - Internal Documentation
Release Notes
Found an issue, or want to add something? Submit a PR to the Wiki repo.