MCPInstall

godot-input-handling

Expert patterns for input handling covering InputMap actions, InputEvent processing, controller support, rebinding, deadzones, and input buffering. Use when setting up player controls, implementing input systems, or adding gamepad/accessibility features. Keywords InputMap, InputEvent, gamepad, controller, rebinding, deadzone, input buffer.

Installs
515
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/thedivergentai/game-dev-agentic-skills --skill godot-input-handling
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads godot-input-handling automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

Input Handling

Handle keyboard, mouse, gamepad, and touch input with proper buffering and accessibility support.

MANDATORY script triggers (by scenario)

ScenarioLoad before coding
Jump/dash/coyote feelinput_buffer.gd (physics-tied decay) + advanced_input_buffer.gd for multi-action priority
Settings remapping UIsafe_runtime_rebind.gd (ConfigFile persist to user://)
Analog stick movementanalog_deadzone_manager.gd — never raw axis without radial deadzone
"Press X / Press E" promptsglyph_prompt_manager.gd
UI nav vs gameplay confirminput_echo_filter.gd — echoes move menus, not Confirm/Back
Gameplay vs menu clicksunhandled_input_priority.gd

Do-NOT-Load (by scenario)

ScenarioLoadDo NOT load
Settings remapping UIsafe_runtime_rebind.gdmulti_touch_gestures.gd, mouse_capture_manager.gd, combo/replay injectors
Mobile / touch gesturesmulti_touch_gestures.gdmouse_capture_manager.gd, desktop remapper persistence
Jump/dash buffer onlyinput_buffer.gd / advanced_input_buffer.gdRemapper, multi-touch, replay, combo validator
FPS mouse lookmouse_capture_manager.gd + deadzone/glyph as neededmulti_touch_gestures.gd, combo/replay
Combo / fighting sequencescombo_validator.gd + buffersTouch gestures, mouse capture
Replay / virtual injection testsinput_replay_buffer.gd / virtual_input_injector.gdRemapper UI, multi-touch

Available Scripts

advanced_input_buffer.gd

Frame-perfect input buffering system for responsive jumps, dashes, and combo chains.

input_buffer.gd

Timed action buffer with _physics_process decay so windows match CharacterBody consumption, not render FPS.

safe_runtime_rebind.gd

Dynamic input rebinding with conflict detection and user://input_rebinds.cfg persistence.

analog_deadzone_manager.gd

Radial deadzone management for analog sticks to eliminate drift while maintaining natural follow-through.

multi_touch_gestures.gd

Handling touch, drags, and pinch-to-zoom gestures for mobile and touchscreen compatibility.

input_echo_filter.gd

Filtering echo events to distinguish between hold-to-navigate (UI) and one-time gameplay actions.

mouse_capture_manager.gd

Robust mouse capture and sensitivity scaling logic for FPS and mouse-intensive systems.

hold_toggle_accessibility.gd

Software-side support for user-defined 'Hold' vs 'Toggle' accessibility preferences.

glyph_prompt_manager.gd

Real-time switching between Keyboard and Gamepad UI prompts based on the last active device.

action_state_machine.gd

Tracking the lifecycle of an action ('Just Pressed', 'Held', 'Released') for complex state logic.

unhandled_input_priority.gd

Demonstrating the correct use of _unhandled_input to prevent gameplay logic from leaking into UI.

virtual_input_injector.gd

Input.parse_input_event injection for CI tutorials / AI assistance — not physical hardware.

combo_validator.gd

Rolling timed sequence buffer for special-move validation (fighting / action RPG).

input_replay_buffer.gd

Frame-tagged capture + deterministic replay via parse_input_event.

NEVER Do in Input Handling

  • NEVER poll input in _process() for gameplay actions — Use _physics_process() or _unhandled_input(). _process() is frame-rate dependent, causing dropped inputs at low FPS [22].
  • NEVER use hardcoded key checks (e.g., KEY_W) — Always use InputMap actions. Hardcoded keys prevent rebinding and break compatibility with non-QWERTY layouts [23].
  • NEVER ignore analog stick deadzones — Drifting sticks at 0.05 magnitude will cause unintended movement. Implement a radial deadzone (not axial) in code or settings [24].
  • NEVER assume a single input device — Players may switch between Keyboard and Controller mid-session. Use Input.joy_connection_changed to update UI prompts dynamically [25].
  • NEVER use _input() for gameplay actions — _input() fires for ALL events (including UI). Use _unhandled_input() so gameplay logic doesn't trigger while clicking menus [26].
  • NEVER omit input buffering in fast-paced games — If a player presses jump 50ms before landing, the input is lost without a buffer. Implement a 100-150ms buffer for a "tight" feel [27].
  • NEVER use Input.is_action_pressed() for one-time triggers — It returns true every frame the key is held. Use _just_pressed for jumps, attacks, and toggles to avoid logic spam.
  • NEVER implement manual 'Hold vs Toggle' logic in multiple places — Centralize it in a setting or input wrapper to ensure accessibility consistency across the whole game.
  • NEVER forget to handle InputEvent.is_echo() in UI navigation — Echo events (keyboard repeat) should move menus but rarely should they trigger "Confirm" or "Back" actions.
  • NEVER capture the mouse without a 'Release' shortcut — If your game crashes or blocks ui_cancel, the user is trapped. Always provide a fallback escape for mouse capture.

Input Propagation & Isolation

Godot propagates input events in a specific order. Understanding this is key to isolating UI from gameplay.

  1. _input(event): High-priority global intercept. Use for dev consoles or debug overlays.
  2. _gui_input(event): Handled by Control nodes (UI). If a UI element consumes the event (e.g., clicking a button), it calls accept_event(), stopping further propagation.
  3. _unhandled_input(event): Reached ONLY if no UI element consumed the event. Expert Pattern: Put all gameplay logic (jump, shoot) here to prevent accidental triggers while interacting with menus.

InputMap Best Practices

Avoid physical key checks. Define semantic actions (e.g., move_left, interact) in Project Settings > Input Map.

1. Analog Deadzones

Analog sticks suffer from drift. MANDATORY: analog_deadzone_manager.gd. Prefer Input.get_vector() for circular deadzones — never subtract axes into a square deadzone.

2. Expert polling delta (no hardcoded keys)

Gameplay samples actions in _physics_process / _unhandled_input — never KEY_* / MOUSE_BUTTON_* branches. Pause/cancel must be InputMap actions (e.g. ui_cancel) so rebinds and non-QWERTY layouts work. See unhandled_input_priority.gd.

Multi-Modal Input & UI Glyphs

Modern games must handle simultaneous Controller and Keyboard/Mouse input smoothly.

1. Handling Input Modes

  • Mouse Aiming: Process InputEventMouseMotion in _unhandled_input() for relative movement (mouse_capture_manager.gd).
  • Stick Movement: Poll vectors in _physics_process() after analog_deadzone_manager.gd.

2. Dynamic Glyph Swapping

MANDATORY: glyph_prompt_manager.gd for last-device prompt swaps. Do not hand-roll event is InputEventJoypadButton detectors in every HUD widget.

Expert Input Extensions (script sole-source)

  • Input buffering — MANDATORY: input_buffer.gd + advanced_input_buffer.gd. Do not paste jump-timer tutorials inline.
  • Coyote time — Owned by movement skills: godot-characterbody-2d (frame_perfect_coyote_time.gd) and godot-genre-platformer. Pair with buffers from this skill; do not re-implement coyote here.
  • Multiplayer input sync — Do not RPC sync_input here. Route to godot-multiplayer-networking for authoritative action snapshots / get_remote_sender_id validation.
  • Virtual injection — MANDATORY: virtual_input_injector.gd (Input.parse_input_event).
  • Combo sequences — MANDATORY: combo_validator.gd; fighting fiction stays in godot-genre-fighting.
  • Deterministic replay — MANDATORY: input_replay_buffer.gd.

Deep recipes (on demand)

TopicReference / script
Buffering / coyote / MP syncinput-event-processing.md
Virtual injection / combos / replayexpert-input-extensions.md
InputMap & device IDsinputmap-best-practices.md

Reference

Progressive disclosure: open Official Documentation links only when researching a specific API; load Related Skills when routing to a peer domain — do not preload the whole lattice.

Official Documentation

  • Using InputEvent — Event propagation order (_input → GUI → _unhandled_input) and why gameplay belongs after UI consumes events.
  • Input examples — Practical InputMap action polling, mouse buttons, and keyboard patterns this skill builds on.
  • Controllers, gamepads, and joysticks — Joypad connection, button/axis events, and multi-device mapping for remappers and glyph swaps.
  • Controller vibration and features — Extended pad capabilities beyond basic buttons when shipping console-style feedback.
  • Mouse and input coordinates — Viewport vs screen coordinates for clicks, aim, and capture-relative motion.
  • Customizing the mouse cursor — Cursor shapes alongside Input.mouse_mode capture/release flows.
  • Handling quit requests — Safe ESC / back / quit paths so mouse capture never traps the player.
  • Input — Singleton API: is_action_*, get_vector, mouse_mode, parse_input_event, and joy connection signals.
  • InputMap — Runtime action_add_event / erase / conflict checks for safe rebinding.
  • InputEvent — Base event API including is_echo(), is_action_pressed(), and device IDs.
  • Idle and Physics Processing — Why hold/poll gameplay input in _physics_process, not frame-tied _process.
  • Control — _gui_input / accept_event so menus stop events before _unhandled_input gameplay.

Related Skills

Prerequisites

  • godot-project-foundations — Project Settings Input Map, scene boot, and Autoload registration that host remappers and glyph managers.
  • godot-gdscript-mastery — Typed InputEvent branches, StringName actions, and safe signal/await patterns used in buffers and device routers.

Complements

Downstream / consumers

  • godot-genre-platformer — Coyote time and jump buffers are the primary consumer of input buffering.
  • godot-genre-shooter-fps — Captured mouse aim, fire just-pressed, and gamepad look rely on this skill’s capture/deadzone stack.
  • godot-genre-fighting — Combo sequence validators and frame-perfect buffers feed special-move detection.
  • godot-multiplayer-networking — Authoritative peers need sanitized action snapshots / RPC’d input, not raw local keycodes.

Master

  • godot-master — Library router and mirrored module entry; open when discovering which Domain Skill owns a cross-cutting input concern.

FAQ

What does the godot-input-handling skill do?

Expert patterns for input handling covering InputMap actions, InputEvent processing, controller support, rebinding, deadzones, and input buffering. Use when setting up player controls, implementing input systems, or adding gamepad/accessibility features. Keywords InputMap, InputEvent, gamepad, controller, rebinding, deadzone, input buffer.

How do I install godot-input-handling?

Run npx skills add https://github.com/thedivergentai/game-dev-agentic-skills --skill godot-input-handling in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/godot-input-handling/ (personal) or .claude/skills/godot-input-handling/ (project).

Which AI agents can use godot-input-handling?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is godot-input-handling safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains godot-input-handling?

It is published by thedivergentai in thedivergentai/game-dev-agentic-skills. It has 515 recorded installs.

More from thedivergentai/game-dev-agentic-skills

View all →

godot-master

thedivergentai/game-dev-agentic-skills

Consolidated expert library for professional Godot 4.7+ game and application development. Orchestrates 92 Domain Skills through architectural workflows, anti-pattern catalogs, performance budgets, and Server API patterns. Use when: (1) starting a new Godot project, (2) designing game or app architecture, (3) building entity/component systems, (4) debugging performance or physics issues, (5) choosing between 2D/3D approaches, (6) implementing multiplayer, (7) optimizing draw calls or script time, (8) porting between platforms, (9) migrating from 4.6 to 4.7. Primary entry point for ALL Godot development tasks. Keywords: Godot 4.7, AreaLight3D, HDR, Asset Store, godot-master.

godot-shaders-basics

thedivergentai/game-dev-agentic-skills

Expert Godot shader patterns for batch-safe hitflash, alpha-scissor foliage/dissolve, screenspace postFX, depth reconstruction, triplanar, and instance uniforms — not first-shader tutorials. Trigger on draw-call batching breaks, discard vs depth-prepass, foliage shadows, post-process quads, or world-position FX. Keywords: instance uniform, ALPHASCISSOR, hintscreentexture, hintdepthtexture, global uniform, sampler2DArray, canvasitem, spatial, post-processing.

AI & Agents691 installs

godot-2d-animation

thedivergentai/game-dev-agentic-skills

Expert patterns for 2D animation in Godot using AnimatedSprite2D and skeletal cutout rigs. Use when implementing sprite frame animations, procedural animation (squash/stretch), cutout bone hierarchies, or frame-perfect timing systems. Trigger keywords: AnimatedSprite2D, SpriteFrames, animationfinished, animationlooped, framechanged, frameprogress, setframeandprogress, cutout animation, skeletal 2D, Bone2D, procedural animation, animation state machine, advance(0).

Frontend & Design688 installs

godot-ui-theming

thedivergentai/game-dev-agentic-skills

Expert blueprint for UI themes using Theme resources, StyleBoxes, custom fonts, and theme overrides for consistent visual styling. Covers StyleBoxFlat/Texture, theme inheritance, dynamic theme switching, and font variations. Use when implementing consistent UI styling OR supporting multiple themes. Keywords Theme, StyleBox, StyleBoxFlat, addthemeoverride, font, theme inheritance, dark mode.

Frontend & Design623 installs

godot-gdscript-mastery

thedivergentai/game-dev-agentic-skills

Expert GDScript landmine guidance: static typing opcodes, signal-up/call-down, %UniqueName/@onready lifecycle, Callable bind/unbind, await sequences, typed collections, and safe Dictionary iteration. Use for code review, refactoring hot paths, or project standards. Trigger keywords: statictyping, signalarchitecture, uniquenodes, @onready, classname, signalupcalldown, Callable.bind, typedcollections, awaitsequence.

godot-particles

thedivergentai/game-dev-agentic-skills

Expert blueprint for GPU particle systems (explosions, magic effects, weather, trails) using GPUParticles2D/3D, ParticleProcessMaterial, gradients, sub-emitters, and custom shaders. Use when creating VFX, environmental effects, or visual feedback. Keywords GPUParticles2D, ParticleProcessMaterial, emissionshape, colorramp, subemitter, oneshot.

Media & Creative614 installs

Popular frontend & design skills

View category →

setup-matt-pocock-skills

mattpocock/skills

Configure this repo for the engineering skills: set up its issue tracker, triage label vocabulary, and domain doc layout. Run once before first use of the other engineering skills.

Frontend & Design1.1M installs

frontend-design

anthropics/skills

Guidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults.

OfficialFrontend & Design1M installs

hyperframes-animation

heygen-com/hyperframes

All animation knowledge for HyperFrames — atomic motion rules, multi-phase scene blueprints, scene transitions, broader motion-design techniques, AND the seven runtime adapters (GSAP default, plus Lottie, Three.js, Anime.js, CSS keyframes, Web Animations API, TypeGPU). Use for any motion or animation task: pick 2-4 rules and compose, or load a blueprint, or look up runtime-specific API (e.g. GSAP eases / Lottie player / Three.js mixer). Also covers auditing an existing composition's choreography (animation map) and 24 named text-animation effects. HyperFrames-native: single paused timeline, seek-safe, deterministic.

prototype

mattpocock/skills

Build a throwaway prototype to answer a design question. Use when the user wants to sanity-check whether a state model or logic feels right, or explore what a UI should look like.

Frontend & Design999.2K installs

hyperframes-core

heygen-com/hyperframes

The HyperFrames composition contract — build one renderable project. Use for composition structure, the data- timing attributes, class="clip", tracks, sub-compositions, variables, framework-owned media playback, deterministic-render rules, and validation. Read before writing composition HTML.

Frontend & Design930.5K installs

vercel-react-best-practices

vercel-labs/agent-skills

React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React/Next.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.

OfficialFrontend & Design843.1K installs