Navigation
API > API/Plugins > API/Plugins/MLAdapter > API/Plugins/MLAdapter/Agents
Inheritance Hierarchy
- UObjectBase
- UObjectBaseUtility
- UObject
- UMLAdapterAgentElement
- UMLAdapterActuator
- UMLAdapterActuator_Camera
- UMLAdapterActuator_EnhancedInput
- UMLAdapterActuator_InputKey
- UMLAdapterSensor
- UMLAdapterSensor_AIPerception
- UMLAdapterSensor_Attribute
- UMLAdapterSensor_Camera
- UMLAdapterSensor_EnhancedInput
- UMLAdapterSensor_Input
- UMLAdapterSensor_Movement
References
| Module | MLAdapter |
| Header | /Engine/Plugins/AI/MLAdapter/Source/MLAdapter/Public/Agents/MLAdapterAgentElement.h |
| Include | #include "Agents/MLAdapterAgentElement.h" |
Syntax
UCLASS&40;Abstract&41;
class UMLAdapterAgentElement : public UObject
Remarks
An agent element is any object that can be attached to an agent. Base class for UMLAdapterSensor and UMLAdapterActuator.
Variables
| Type | Name | Description | |
|---|---|---|---|
| FString | Description | Can be queried by remote clients. | |
| uint32 | ElementID | This is not a common counter, meaning Sensors and Actuators (for example) track the ID separately. | |
| FString | Nickname | User-configured name for this element, mostly for debugging purposes but comes in handy when fetching observation/action spaces descriptions. | |
| TSharedRef< FMLAdapter::FSpace > | SpaceDef |
Constructors
| Type | Name | Description | |
|---|---|---|---|
UMLAdapterAgentElement
(
const FObjectInitializer& ObjectInitializer |
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | |||
| TSharedPtr< FMLAdapter::FSpace > | |||
| const UMLAdapterAgent & | GetAgent () |
Get the agent this element is attached to. | |
| AActor * | GetAvatar () |
||
| AController * | |||
| FString | |||
| uint32 | GetElementID () |
Get the ID of this element. | |
| const FString & | GetNickname () |
Get nickname of this element. | |
| bool | GetPawnAndControllerAvatar
(
APawn*& OutPawn, |
Fetches both the pawn and the controller associated with the current agent. It's like both calling | |
| APawn * | |||
| const FMLAdapter::FSpace & | GetSpaceDef () |
||
| void | OnAvatarSet
(
AActor* Avatar |
||
| void | SetNickname
(
const FString& NewNickname |
||
| void | Shutdown () |
Called before object's destruction. | |
| void |
Overridden from UObject
| Type | Name | Description | |
|---|---|---|---|
| void | Called after the C++ constructor and after the properties have been initialized, including those loaded from config. |