Skip to main content
Glama

runtime_input

Simulate a player pressing an Input Map action in a running game, hold it for frames, then release, so is_action_just_pressed returns true and _unhandled_input receives it.

Instructions

Press an input action in a running game, as a player would: pressed for the given number of frames, then released, through the normal input path, so is_action_just_pressed and _unhandled_input see it. Actions come from the project's Input Map (project_config lists them). Returns: once released.

Input Schema

NameRequiredDescriptionDefault
actionYesInput Map action, e.g. jump
framesNoFrames to hold it (default 2)
strengthNo0..1 for analog actions (default 1)
session_idNoSession from runtime_run. Required only when several games run.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.2.0

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Adds substantial behavior beyond the annotations: the action is held for N frames then released, it flows through the normal input pipeline so is_action_just_pressed and _unhandled_input fire, and the call returns only once released. These are non-obvious mechanics (timing, return gating) that annotations alone could not convey.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core action and the most decision-relevant fact (it simulates a real player input path), then a terse 'Returns: once released.' Slightly run-on, but no wasted sentences.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 4-parameter mutation-like tool with no output schema, it sufficiently covers where actions come from, timing, and return behavior; annotations cover the safety profile. A little more on failure cases (unknown action, no running session) would complete it.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3. The description adds value by clarifying that the 'action' value comes from the project's Input Map and pointing at project_config to enumerate valid actions, easing correct parameterization.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource (press an input action in a running game) and precisely scopes it as player-like input. It distinguishes itself cleanly from neighbors like runtime_set and runtime_eval by describing simulated input rather than state mutation, so an agent can select it without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives clear context: use it against a running game, driving the normal input path; and it routes the agent to project_config for the list of valid actions. It does not explicitly name when NOT to use it versus alternatives like runtime_eval, so it stops short of full 5-level routing.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.