set_component_parameter_override
Set a per-instance override for a single StateTree root parameter on a placed actor's UStateTreeComponent, replacing the asset default at runtime; clear overrides or auto-bind a tree when needed.
Instructions
Override a single UStateTree root parameter on a UStateTreeComponent living on a placed actor. CRITICAL: the implementation calls UStateTreeStateTreeReference::SetPropertyOverridden(ParamGuid, true) — without this, the runtime reads from the asset default and the per-instance value is silently dropped. The value is written via FInstancedPropertyBag::SetValueSerializedString so the engine parses the string into the parameter's actual type (Bool/Int/Float/Vector/Struct/...). The tree must already declare the parameter; add it with add_tree_parameter first. Use clear_overrides=true to remove the override (asset default takes over again) without writing a value. If the component has no bound tree, pass state_tree_path to auto-bind before overriding (cold-start convenience); the public UStateTreeComponent::SetStateTree(UStateTree*) handles the bind through reflection on the protected StateTreeRef member.
Returns: { actor_label, component_class, parameter_name, parameter_id, value, was_overridden, cleared, saved, bound_tree }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| value | Yes | Optional string-encoded value; type-driven by the parameter's FPropertyBagPropertyDesc | |
| actor_label | Yes | Actor label/name that owns the UStateTreeComponent (resolved against the editor world) | |
| parameter_name | Yes | Root parameter name to override (must exist on the bound tree) | |
| clear_overrides | No | If true, drop all per-instance overrides on the component (asset defaults take over); value is ignored | |
| state_tree_path | No | Optional path to a UStateTree to bind the component to if no tree is already bound |