UMeshClickTool

[USingleClickTool](API\Runtime\InteractiveToolsFramework\BaseTools\USingleClickTool) is perhaps the simplest possible interactive tool.

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

MeshPaintingToolset

Header

/Engine/Plugins/MeshPainting/Source/MeshPaintingToolset/Public/MeshSelect.h

Include

#include "MeshSelect.h"

Syntax

[UCLASS](Programming/UnrealArchitecture/Reference/Classes#classdeclaration)()
class UMeshClickTool :
    public USingleClickTool,
    public IMeshPaintSelectionInterface

Remarks

USingleClickTool is perhaps the simplest possible interactive tool. It simply reacts to default primary button clicks for the active device (eg left-mouse clicks).

The function ::IsHitByClick() determines what is clickable by this Tool. The default is to return true, which means the click will activate anywhere (the Tool itself has no notion of Actors, Components, etc). You can override this function to, for example, filter out clicks that don't hit a target object, etc.

The function ::OnClicked() implements the action that will occur when a click happens. You must override this to implement any kind of useful behavior.

Variables

Name Description

Protected variable UProperty Transient

UMeshPaintSelec...

 

SelectionMechanic

Constructors

Name Description

Public function

UMeshClickTool()

Overridden from UInteractiveTool

Name Description

Public function Virtual

void

 

Setup()

Register default primary-button-click InputBehaviors

Overridden from IClickBehaviorTarget

Name Description

Public function Virtual

FInputRayHit

 

IsHitByClick

(
    const FInputDeviceRay& ClickPos
)

Test if the Target is hit at this 2D position / 3D ray

Public function Virtual

void

 

OnClicked

(
    const FInputDeviceRay& ClickPos
)

Click the Target at this 2D position / 3D ray. Default behavior is to print debug string.

Overridden from IModifierToggleBehaviorTarget

Name Description

Public function Virtual

void

 

OnUpdateModifierState

(
    int ModifierID,
    bool bIsOn
)

Notify target of current modifier state

Overridden from IMeshPaintSelectionInterface

Constants

Name

Description

AdditiveSelectionModifier

Flags used to identify modifier keys/buttons

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss