Navigation
API > API/Plugins > API/Plugins/ScriptableToolsFramework > API/Plugins/ScriptableToolsFramework/UScriptableInteractiveTool
Description
Watch any Property in a PropertySet for changes. This function handles most basic properties, as well as Struct and Array properties, at some cost. The OnModified delegate cannot be passed the new property value, it must be fetched from the PropertySet.
Note also that in the case of Structs and Arrays, changes are currently detected by hashes, and there is always a small chance of hash collision.
| Name | WatchProperty |
| Type | function |
| Header File | /Engine/Plugins/Runtime/ScriptableToolsFramework/Source/ScriptableToolsFramework/Public/ScriptableInteractiveTool.h |
| Include Path | #include "ScriptableInteractiveTool.h" |
| Source | /Engine/Plugins/Runtime/ScriptableToolsFramework/Source/ScriptableToolsFramework/Private/ScriptableInteractiveTool.cpp |
UFUNCTION (BlueprintCallable, Category="ScriptableTool|PropertySets")
UScriptableInteractiveToolPropertySet * WatchProperty
(
UScriptableInteractiveToolPropertySet * PropertySet,
FString PropertyName,
const FToolPropertyModifiedDelegate & OnModified
)
Parameters
| Name | Remarks |
|---|---|
| PropertySet | the Property Set which contains the desired Property to watch. |
| PropertyName | the string name of the Property in the given Property Set |
| OnModified | this delegate will be called if the Property value changes. |