Navigation
API > API/Plugins > API/Plugins/ScriptableToolsFramework > API/Plugins/ScriptableToolsFramework/UScriptableModularBehaviorTool
Description
AddMouseWheelBehavior will run the event "OnMouseWheelScrollUp" and "OnMouseWheelScrollDown" each time the mouse wheel is rotated. It is up to the user to record these in variables or otherwise react to these events.
| Name | AddMouseWheelBehavior |
| Type | function |
| Header File | /Engine/Plugins/Runtime/ScriptableToolsFramework/Source/ScriptableToolsFramework/Public/BaseTools/ScriptableModularBehaviorTool.h |
| Include Path | #include "BaseTools/ScriptableModularBehaviorTool.h" |
| Source | /Engine/Plugins/Runtime/ScriptableToolsFramework/Source/ScriptableToolsFramework/Private/BaseTools/ScriptableModularBehaviorTool.cpp |
UFUNCTION (BlueprintCallable, Category="ScriptableTool|Input",
Meta=(AdvancedDisplay="CaptureCheck, CapturePriority"))
void AddMouseWheelBehavior
(
FTestShouldRespondToMouseWheelDelegate TestShouldRespondToMouseWheel,
FOnMouseWheelScrollUpDelegate OnMouseWheelScrollUp,
FOnMouseWheelScrollDownDelegate OnMouseWheelScrollDown,
FMouseBehaviorModiferCheckDelegate CaptureCheck,
int CapturePriority
)
Parameters
| Name | Remarks |
|---|---|
| TestShouldRespondToMouseWheel | The result's bHit property determines whether the mouse wheel action will be captured. (Perhaps the mouse wheel only does something when mousing over some part of a mesh) |
| OnMouseWheelScrollUp | CurrentPos device position/ray at point where mouse wheel is engaged |
| OnMouseWheelScrollDown | CurrentPos device position/ray at point where mouse wheel is engaged |
| CaptureCheck | Only enable capture if returns true |
| CapturePriority | The priority is used to resolve situations where multiple behaviors want the same capture. Lower values, including negative, have higher priority. |