UExperimentAgentComponent¶
Abstract base component for all MRI experiment agents (subject pawn, NPCs, etc.).
Syntax¶
Remarks¶
Attach subclasses of this component to any Actor that should be tracked and visited by the logging system. During BeginPlay, the component marks itself as registered (if bRegisterAgentComponent is true), and during EndPlay it clears the mark. The spectator controller enumerates registered agent components in the world each replay tick.
Use AcceptVisitor to let a visitor (e.g. ExperimentState ) read out the current state information for this agent each frame. UCLASS
Inheritance Hierarchy¶
USceneComponent → UExperimentAgentComponent
Derived Classes¶
UExperimentPlayerAgentComponent
Methods¶
| Method | Signature | Description | Blueprint |
|---|---|---|---|
| AcceptVisitor | void UExperimentAgentComponent::AcceptVisitor(IExperimentAgentComponentVisitor &Visitor) const |
Accepts a visitor and calls the visitor's Visit method with this component. | |
| BeginPlay | void UExperimentAgentComponent::BeginPlay() override |
Called when the game starts. | |
| EndPlay | void UExperimentAgentComponent::EndPlay(EEndPlayReason::Type EndPlayReason) override |
Called when the actor is removed from the world. | |
| GetId | uint32 UExperimentAgentComponent::GetId() const |
Returns a unique identifier for this component instance derived from its pointer hash. | |
| IsAgentRegistered | bool UExperimentAgentComponent::IsAgentRegistered() const |
Returns whether this component is currently marked for inclusion in state logging. | |
| UExperimentAgentComponent | UExperimentAgentComponent::UExperimentAgentComponent(const FObjectInitializer &ObjectInitializer) |
Constructs the component. |
Properties¶
| Property | Type | Description | Blueprint |
|---|---|---|---|
| bAgentComponentIsRegistered | bool |
Indicates whether this component is currently registered with the agent registry. | |
| bRegisterAgentComponent | bool |
If true, this component will register itself with the agent registry on BeginPlay. |