add-keyboard-support
Installation
SKILL.md
Add Keyboard Support
Wire up the Puzzmo on-screen keyboard so mobile players can type without a hardware keyboard.
The runtime shows the keyboard automatically on touch devices when the game calls sdk.keyboard.show().
Steps
-
Import
defaultKeyboardConfigalongside the SDK:import { createPuzzmoSDK, defaultKeyboardConfig } from "@puzzmo/sdk" import type { KeyboardConfig } from "@puzzmo/sdk" const sdk = createPuzzmoSDK() -
Show the keyboard when the player focuses an input (e.g. selects a tile or cell). Start from
defaultKeyboardConfigand customize for your game: