Navigation
API > API/Runtime > API/Runtime/InteractiveToolsFramework
A UInteractionMechanic implements a "user interaction". This is generally a subset of an InteractiveTool, for example an interaction to draw a polygon could be used in many tools, but requires handling input events and converting them to click points on a plane, handling various cases like closing a loop, undo/redo of points, etc. Ideally all these aspects should be able to be wrapped up in an UInteractionMechanic that multiple Tools can use.
(This class is still a work in progress)
| Name | UInteractionMechanic |
| Type | class |
| Header File | /Engine/Source/Runtime/InteractiveToolsFramework/Public/InteractionMechanic.h |
| Include Path | #include "InteractionMechanic.h" |
Syntax
UCLASS (Transient, MinimalAPI)
class UInteractionMechanic : public UObject
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UInteractionMechanic
Derived Classes
UInteractionMechanic derived class hierarchy
- UMeshTopologySelectionMechanic
- UCollectSurfacePathMechanic
- UCollisionPrimitivesMechanic
- UConstructionPlaneMechanic
- UCurveControlPointsMechanic
- UDragAlignmentMechanic
- UInteractiveToolActivity
- ULatticeControlPointsMechanic
- UMeshPaintSelectionMechanic
- UPlaneDistanceFromHitMechanic
- UPolyLassoMarqueeMechanic
- URectangleMarqueeMechanic
- USpaceCurveDeformationMechanic
- USpatialCurveDistanceMechanic
- UUVEditorMeshSelectionMechanic
- UUVToolSelectionHighlightMechanic
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
UInteractionMechanic() |
InteractionMechanic.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void Render
(
IToolsContextRenderAPI* RenderAPI |
Allow the Mechanic to do any custom drawing (ie via PDI/RHI) | InteractionMechanic.h | |
virtual void Setup
(
UInteractiveTool* ParentTool |
Called to initialize the InteractionMechanic | InteractionMechanic.h | |
virtual void Shutdown() |
Called to clean up the InteractionMechanic | InteractionMechanic.h | |
virtual void Tick
(
float DeltaTime |
ALlow the Mechanic to Tick | InteractionMechanic.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void AddToolPropertySource
(
UInteractiveToolPropertySet* PropertySet |
Add a PropertySet object for this Mechanic to parent Tool | InteractionMechanic.h | |
UInteractiveTool * GetParentTool() |
InteractionMechanic.h | ||
virtual bool SetToolPropertySourceEnabled
(
UInteractiveToolPropertySet* PropertySet, |
Enable/Disable a PropertySet object for the parent tool. | InteractionMechanic.h |