Talos docs

entity.set_component

Since next

[editor or disk] Put this component on this entity, replacing any of its type, one undo step.

Plain text

Fields are FLAT ({"type":"mesh","asset":"cube"}), not under play.query's "props"; only script has props.

TitleSet a component
Mode
Token costabout 160 tokens (in the default list, paid on every call)
Toolsetcore

Arguments

ArgumentTypeRequiredDefaultAllowed valuesDescription
agentstringnoThe name of the agent making the call, when several agents share one connection: each named agent is its own actor and plays its own game. Leave it out when there is one agent.
componentobjectyes{"type": mesh, collider, rigidbody, controller, camera, light, spawn, script, …, its fields}
entitystringyes
savebooleannotrue saves the scene afterwards.
scenestringnoThe scene file to act on. The open scene when absent.

Example

An MCP tools/call with the required arguments (placeholders in angle brackets).

{
  "name": "entity.set_component",
  "arguments": {
    "component": {},
    "entity": "<entity>"
  }
}