Navigation
API > API/Plugins > API/Plugins/SmartObjectsModule > API/Plugins/SmartObjectsModule/USmartObjectSubsystem
Description
Runs the entrance validation logic for all the slots in the smart object definition and returns all validated locations. This method can be used to a smart object definition before it is added to the simulation, for example to show some UI visualization while placing an actor with smart object. The method is static so it can be used even if the smart object subsystem is not present.
| Name | QueryAllValidatedEntranceLocations |
| Type | function |
| Header File | /Engine/Plugins/Runtime/SmartObjects/Source/SmartObjectsModule/Public/SmartObjectSubsystem.h |
| Include Path | #include "SmartObjectSubsystem.h" |
| Source | /Engine/Plugins/Runtime/SmartObjects/Source/SmartObjectsModule/Private/SmartObjectSubsystem.cpp |
static bool QueryAllValidatedEntranceLocations
(
const UWorld * World,
const USmartObjectDefinition & SmartObjectDefinition,
const FTransform & SmartObjectTransform,
const AActor * SkipActor,
const FSmartObjectSlotEntranceLocationRequest & Request,
TArray < FSmartObjectSlotEntranceLocationResult > & Results
)
True if any entrances were found.
Parameters
| Name | Remarks |
|---|---|
| World | World to use for validation tracing. |
| SmartObjectDefinition | Smart object definition to validate. |
| SmartObjectTransform | World transform of the smart object definition (e.g. smart object Component transform). |
| SkipActor | An actor to skip during validation (this could be an actor representing the smart object during placement). |
| Request | Request describing how to validate the entries. |
| Results | All entrance locations, FSmartObjectSlotEntranceLocationResult::bIsValid can be used to check if a specific result is valid. |