Navigation
API > API/Plugins > API/Plugins/SmartObjectsModule
Struct that can be used to pass data to the find or filtering methods. Properties will be used as user data to fill values expected by the world condition schema specified by the smart object definition. e.g. FilterSlotsBySelectionConditions(SlotHandles, FConstStructView::Make(FSmartObjectActorUserData(Pawn)));
It can be inherited from to provide additional data to another world condition schema inheriting from USmartObjectWorldConditionSchema. e.g. UCLASS() class USmartObjectWorldConditionExtendedSchema : public USmartObjectWorldConditionSchema { ... USmartObjectWorldConditionExtendedSchema(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer) { OtherActorRef = AddContextDataDesc(TEXT("OtherActor"), AActor::StaticClass(), EWorldConditionContextDataType::Dynamic); }
FWorldConditionContextDataRef OtherActorRef; };
USTRUCT() struct FSmartObjectActorExtendedUserData : public FSmartObjectActorUserData { TWeakObjectPtr
The struct can also be used to be added to a Smart Object slot when it gets claimed. e.g. Claim(SlotHandle, FConstStructView::Make(FSmartObjectActorUserData(Pawn)));
| Name | FSmartObjectActorUserData |
| Type | struct |
| Header File | /Engine/Plugins/Runtime/SmartObjects/Source/SmartObjectsModule/Public/SmartObjectTypes.h |
| Include Path | #include "SmartObjectTypes.h" |
Syntax
USTRUCT ()
struct FSmartObjectActorUserData
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
| SmartObjectTypes.h | |||
FSmartObjectActorUserData
(
const AActor* InUserActor |
SmartObjectTypes.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| UserActor | TWeakObjectPtr< const AActor > | SmartObjectTypes.h |