Skip to main content
Glama

set_mpci_vector_parameter_value

DestructiveIdempotent

Override a vector parameter on a Material Parameter Collection Instance (MPCI) at runtime, creating the instance and pushing the value to the renderer without modifying the asset.

Instructions

Override one vector parameter on the Material Parameter Collection Instance (MPCI: the transient per-world values) of a collection on a world, the editor world by default, creating the instance when needed, and push it to the renderer. Pass rgba or r/g/b/a: r/g/b/a override the matching rgba entries, and channels given by neither are 0 (alpha 1), not the current value. Runtime only: the asset is untouched (set_collection_param_default edits it), nothing saved, no undo. Errors when parameter_name is not a vector parameter of the collection; scalars: set_mpci_scalar_parameter_value.

Returns: { collection_path: string, parameter_name: string, value_rgba: [number], readback_rgba: [number], readback_ok: bool, world_name: string }

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
aNoOptional alpha channel
bNoOptional blue channel
gNoOptional green channel
rNoOptional red channel, alternative to rgba
rgbaNoOptional [r, g, b, a] color value
world_labelNoEmpty or "editor" for the editor world (the default); otherwise the UWorld name of a live world context, compared case-insensitively (first match)
parameter_nameYesName of the vector parameter to override
collection_pathYesFull /Game path of the parent MPC

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.2.0
    • changedInput schema / properties / world_label / description
      Previous value: -"Optional world context label, default editor"New value: +"Empty or \"editor\" for the editor world (the default); otherwise the UWorld name of a live world context, compared case-insensitively (first match)"
  2. First observedv1.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Annotations give only the safety profile (readOnly=false, destructive=true, idempotent=true); the description adds the material facts: transient per-world override, instance auto-creation, renderer push, no save/undo, default editor-world targeting, and an explicit error case. There is mild tension between destructiveHint=true and 'the asset is untouched', but the description is describing runtime state mutation rather than asset destruction, so it is not a contradiction.

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 operation and densely informative; every clause (default world, instance creation, channel defaults, error condition, return shape) carries weight. The opening sentence is long with stacked parentheticals, which costs a little readability, but there is 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?

With 8 parameters, no output schema, and no sibling that performs the same override, the description covers invocation defaults (editor world), value semantics, error behavior, persistence scope, and even inlines the return shape. Nothing an agent needs to call this correctly is missing.

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 semantics the schema lacks: rgba vs r/g/b/a precedence, and that unspecified channels default to 0 (alpha 1) rather than retaining the current value. That default-value behavior is exactly the non-obvious detail an agent would otherwise get wrong.

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 precise verb and resource: overrides one vector parameter on the transient MPCI of a collection on a world, creating the instance and pushing to the renderer. It explicitly separates itself from set_collection_param_default (the asset-editing sibling) and set_mpci_scalar_parameter_value (the scalar case), so an agent can route without opening any schema.

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?

Explicit when/when-not guidance: 'Runtime only: the asset is untouched (set_collection_param_default edits it), nothing saved, no undo', plus the error condition when parameter_name is not a vector parameter. Alternatives are named by function and by condition, leaving nothing to inference.

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

Deploy Server

Other Tools