Navigation
API > API/Plugins > API/Plugins/LearningAgentsTraining > API/Plugins/LearningAgentsTraining/UPositionArraySimilarityReward
References
| Module | LearningAgentsTraining |
| Header | /Engine/Plugins/Experimental/LearningAgents/Source/LearningAgentsTraining/Public/LearningAgentsRewards.h |
| Include | #include "LearningAgentsRewards.h" |
| Source | /Engine/Plugins/Experimental/LearningAgents/Source/LearningAgentsTraining/Private/LearningAgentsRewards.cpp |
UFUNCTION&40;BlueprintCallable, Category&61;"LearningAgents", Meta&61;&40;DefaultToSelf&61;"InAgentTrainer"&41;&41;
static UPositionArraySimilarityReward &42; AddPositionArraySimilarityReward
&40;
ULearningAgentsTrainer &42; InAgentTrainer,
const FName Name,
const int32 PositionNum,
const float Scale,
const float Weight
&41;
Remarks
Adds a new position array similarity reward to the given trainer. Call during ULearningAgentsTrainer::SetupRewards event. The newly created reward.
Parameters
| Name | Description |
|---|---|
| InAgentTrainer | The trainer to add this reward to. |
| Name | The name of this new reward. Used for debugging. |
| PositionNum | The number of positions in the array. |
| Scale | Used to normalize the data for the reward. |
| Weight | Multiplier for this reward when being summed up for the total reward. |