Skip to main content
Glama
playcanvas

PlayCanvas Editor MCP Server

Official
by playcanvas

inject_input

Dispatch keyboard, mouse, and touch events to the running game instance to drive interactions such as pressing keys, clicking, dragging, or tapping. Use after launch_start to test and verify behavior.

Instructions

Dispatch keyboard / mouse / touch input to the RUNNING Launch instance so you can drive end-to-end interactions ("press W to move", "click a button", "tap the screen"). Requires launch_start first. Events run in order; coordinates are CSS pixels from the canvas top-left (match capture_runtime's framing). Returns { dispatched }. Patterns: key press with holdMs to move for a duration; mouse click at (x,y); a down→move…→up sequence for dragging; touch tap for mobile UI. After injecting, use capture_runtime / read_runtime_logs / query the scene to observe the effect. When NOT to use: to change entity data directly (use modify_entities) or before launch_start.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
eventsYesOrdered list of input events to dispatch
betweenMsNoDelay between consecutive events (default 0)
Behavior4/5

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

Annotations only mark non-read-only, non-idempotent, non-destructive. The description adds useful behavior beyond that: events run in order, coordinates are CSS pixels from canvas top-left, and returns { dispatched }. No contradiction with annotations.

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

Conciseness5/5

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

Every sentence earns its place: purpose, prerequisite, coordinate framing, return shape, common patterns, follow-up observation, and exclusions. Front-loaded and well structured with no filler.

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

Completeness5/5

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

Given no output schema, the description specifies the return. It also covers prerequisites, ordering semantics, coordinate space, event patterns, how to verify effects, and when to use an alternative. This is complete for an input-injection tool.

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

Parameters3/5

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

Schema description coverage is 100% and each parameter and enum is already documented in the schema. The description adds practical usage patterns but no new parameter semantics, so a baseline 3 is appropriate.

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 and resource: dispatches keyboard/mouse/touch input to the RUNNING Launch instance. Clearly differentiates from siblings like launch_start, capture_runtime, and modify_entities.

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

Usage Guidelines5/5

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

Explicitly requires launch_start first, gives post-injection observation tools (capture_runtime / read_runtime_logs / query scene), and lists when NOT to use: for direct entity data changes use modify_entities, or before launch_start.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/playcanvas/editor-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server