set_actor_team
Assigns a team ID to an actor via IGenericTeamAgentInterface, falling back to the actor's Controller, and refreshes AI perception listeners for immediate affiliation filtering.
Instructions
Assigns a native FGenericTeamId to an actor via IGenericTeamAgentInterface, falling back to the actor's Controller when the actor itself doesn't implement the interface (e.g. an ACharacter possessed by an AAIController — the only class implementing it in vanilla UE 5.8). Refreshes any UAIPerceptionComponent listeners on the resolved agent so Sight/Hearing/Touch affiliation filtering (cached at listener-update time) reflects the new team immediately.
Returns: { actor_name, team_id, applied, resolved_on: "actor"|"controller", perception_listeners_refreshed }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| team_id | Yes | Required int in [0, 254] (255 is the engine-reserved NoTeam id) | |
| actor_name | Yes | Display label or internal name (required) |