Navigation
API > API/Plugins > API/Plugins/LearningAgents > API/Plugins/LearningAgents/ULearningAgentsManager
Description
Gets all added agents. Calling this from blueprint with the appropriate AgentClass will automatically cast the object to the given type.
| Name | GetAllAgents |
| Type | function |
| Header File | /Engine/Plugins/Experimental/LearningAgents/Source/LearningAgents/Public/LearningAgentsManager.h |
| Include Path | #include "LearningAgentsManager.h" |
| Source | /Engine/Plugins/Experimental/LearningAgents/Source/LearningAgents/Private/LearningAgentsManager.cpp |
UFUNCTION (BlueprintPure=false, Category="LearningAgents",
Meta=(DeterminesOutputType="AgentClass", DynamicOutputParam="OutAgents"))
void GetAllAgents
(
TArray < UObject * > & OutAgents,
TArray < int32 > & OutAgentIds,
const TSubclassOf < UObject > AgentClass
) const
Parameters
| Name | Remarks |
|---|---|
| AgentClass | The class to cast the agent objects to (in blueprint). |
| OutAgents | The output array of agent objects. |
| OutAgentIds | The output array of agent ids. |