Skip to main content
Glama

Add ANY component to a saved R3 project

r3_component_add

Add one component of ANY registered type — a collider, a rigid body, a joint, a light, a material, a geometry … — to a saved R3 project, with its values and references set before it is created. Kept at once in the project's live copy: every R3 tab with the project open shows it now, no editor needed and nothing to save (r3_editor_add_component is the same tool). Use r3_factory_run for a ready-made object (a cube, a physics sphere …).

type is the short type name, e.g. "ColliderCuboid" (an unknown type is refused with the list). values take r3_component_set's shapes: a plain value {"friction": 0.2}; a value component as the keys to set {"halfExtents": {"x": 2, "y": 0.5, "z": 1}}; a reference as the target's entityRef or id {"rigidBody": "rigidbody_dynamic_1"} — a component of THIS project, of a type the slot accepts; "name" names it. A type that cannot exist without an option (an Audio / AudioPositional / Texture's "url") takes it in values too, and is refused without it. A Code component's code is r3_code_write's. A VehicleWheel added with a mesh is measured from it (Configure from Mesh: radius, connectionPoint, axle), and a ColliderCuboid / Sphere / Cylinder / Capsule with a mesh (its own or its rigid body's) is fitted to it (Fit to Mesh: size, and position on the mesh's centre), only the values you did not pass; the answer says what (PHYSICS_USAGE.md → Vehicles).

Input Schema

NameRequiredDescriptionDefault
typeYesThe component type, e.g. "ColliderCuboid", "RigidBodyFixed", "LightPoint".
valuesNoIts values, e.g. {"rigidBody": "rigidbody_dynamic_1", "halfExtents": {"x": 2}, "friction": 0.2}.
projectIdYesThe project to add to (r3_project_list).

Output Schema

NameRequiredDescriptionDefault
seqNo
typeYes
savedYes
answerYesThis answer in words: what was done, what R3 measured, decided or refused, and what to do next. The same text as the result's text block. Read it: the fields beside it are the data, this is the guidance.
createdYes
physicsYes
entityRefYes
projectIdYes
componentIdYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedOutput schema / properties / physics
      Added value: +{
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "code": {
      +        "type": "string"
      +      },
      +      "collider": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "message": {
      +        "type": "string"
      +      },
      +      "rigidBody": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "code",
      +      "collider",
      +      "rigidBody",
      +      "message"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "projectId",
      -  "type",
      -  "componentId",
      -  "entityRef",
      -  "created",
      -  "saved",
      -  "answer"
      -]New value: +[
      +  "projectId",
      +  "type",
      +  "componentId",
      +  "entityRef",
      +  "created",
      +  "saved",
      +  "physics",
      +  "answer"
      +]
  2. Changed2 schema fields changed
    • addedOutput schema / properties / answer
      Added value: +{
      +  "description": "This answer in words: what was done, what R3 measured, decided or refused, and what to do next. The same text as the result's text block. Read it: the fields beside it are the data, this is the guidance.",
      +  "type": "string"
      +}
    • changedOutput schema / required
      Previous value: -[
      -  "projectId",
      -  "type",
      -  "componentId",
      -  "entityRef",
      -  "created",
      -  "saved"
      -]New value: +[
      +  "projectId",
      +  "type",
      +  "componentId",
      +  "entityRef",
      +  "created",
      +  "saved",
      +  "answer"
      +]
  3. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint=false, openWorldHint=true, destructiveHint=false), it discloses real behavioral traits: the component is kept immediately in the project's live copy and visible in every open tab with nothing to save, unknown types are refused with the type list, types requiring a mandatory option are refused without it, and mesh-linked components are auto-fitted only for values not passed.

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

Conciseness3/5

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

Purpose is front-loaded, but the body is a long run-on sentence dense with em-dash and parenthetical asides (VehicleWheel/Configure from Mesh, Fit to Mesh, PHYSICS_USAGE.md) that make it hard to scan. The content largely earns its place given the tool's edge cases, but the packaging is heavy and under-structured.

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?

An output schema exists, so return values need not be documented, yet the description still notes 'the answer says what' was auto-fitted. For a 3-parameter mutation tool with nested open-object values, it covers the type format, the value/reference encodings, mandatory-option types, and Code component ownership, leaving no obvious gap.

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 100% so the baseline is 3, but the description adds meaning the schema does not: `type` is the short type name and unknown values are rejected with a list, and `values` may be a plain value, a value component, or a reference expressed as the target's entityRef or id, with 'name' naming the component. The exact shape vocabulary is still delegated to r3_component_set rather than defined here.

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?

The first sentence gives a specific verb (add) and resource (component) plus the broad scope ('ANY registered type'), then enumerates examples (collider, rigid body, joint, light, material, geometry). It actively distinguishes itself from siblings by noting r3_editor_add_component is the same tool and routing ready-made objects to r3_factory_run.

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?

It names an alternative with its selecting condition ('Use r3_factory_run for a ready-made object (a cube, a physics sphere …)') and aliases r3_editor_add_component, which is genuinely useful routing. However it gives no explicit when-not-to-use guidance and never contrasts against the closely related r3_component_set, leaving that boundary to be inferred.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources