Struct FUxtPointerFocus
Utility class that is used by components to manage different pointers and their focus targets.
Namespace:
Assembly: .dll
Syntax
public: struct FUxtPointerFocus
Constructors
|
Improve this Doc
View Source
~FUxtPointerFocus()
Declaration
public: virtual ~FUxtPointerFocus()
Methods
|
Improve this Doc
View Source
ClearFocus(UUxtNearPointerComponent *Pointer)
Clear the focused target.
Declaration
public: void ClearFocus(UUxtNearPointerComponent *Pointer)
Parameters
|
Improve this Doc
View Source
FindClosestPointOnComponent(UActorComponent *Target, const FVector &Point)
Find the closest primitive and point on the owner of the given component.
Declaration
protected: FUxtPointerFocusSearchResult FindClosestPointOnComponent(UActorComponent *Target, const FVector &Point) const
Parameters
Type |
Name |
Description |
UActorComponent * |
Target |
|
const FVector & |
Point |
|
Returns
|
Improve this Doc
View Source
FindClosestTarget(const TArray<FOverlapResult> &Overlaps, const FVector &Point)
Find the closest target object, primitive, and point among the overlaps.
Declaration
protected: FUxtPointerFocusSearchResult FindClosestTarget(const TArray<FOverlapResult> &Overlaps, const FVector &Point) const
Parameters
Type |
Name |
Description |
const TArray<FOverlapResult> & |
Overlaps |
|
const FVector & |
Point |
|
Returns
|
Improve this Doc
View Source
FindInterfaceComponent(AActor *Owner)
Find a component of the actor that implements the required interface.
Find a component of the actor that implements the given interface type.
Declaration
public: UActorComponent * FindInterfaceComponent(AActor *Owner) const
Parameters
Type |
Name |
Description |
AActor * |
Owner |
|
Returns
Type |
Description |
UActorComponent * |
|
|
Improve this Doc
View Source
GetClosestPointOnTarget(const UActorComponent *Target, const UPrimitiveComponent *Primitive, const FVector &Point, FVector &OutClosestPoint)
Find the closest point on the given primitive using the distance function of the target interface.
Declaration
protected: virtual bool GetClosestPointOnTarget(const UActorComponent *Target, const UPrimitiveComponent *Primitive, const FVector &Point, FVector &OutClosestPoint) const =0
Parameters
Type |
Name |
Description |
const UActorComponent * |
Target |
|
const UPrimitiveComponent * |
Primitive |
|
const FVector & |
Point |
|
FVector & |
OutClosestPoint |
|
Returns
|
Improve this Doc
View Source
GetClosestTargetPoint()
Get the closest point on the surface of the focused target
Declaration
public: const FVector & GetClosestTargetPoint() const
Returns
Type |
Description |
const FVector & |
|
|
Improve this Doc
View Source
GetFocusedPrimitive()
Get the currently focused primitive component
Declaration
public: UPrimitiveComponent * GetFocusedPrimitive() const
Returns
Type |
Description |
UPrimitiveComponent * |
|
|
Improve this Doc
View Source
GetFocusedTarget()
Get the currently focused target object.
Declaration
public: UObject * GetFocusedTarget() const
Returns
Type |
Description |
UObject * |
|
|
Improve this Doc
View Source
GetFocusedTargetChecked()
Get the currently focused target object. Returns null if the target does not implement the expected interface.
Declaration
public: UObject * GetFocusedTargetChecked() const
Returns
Type |
Description |
UObject * |
|
|
Improve this Doc
View Source
GetInterfaceClass()
Get the interface class that targets for the pointer must implement.
Declaration
protected: virtual UClass * GetInterfaceClass() const =0
Returns
Type |
Description |
UClass * |
|
|
Improve this Doc
View Source
ImplementsTargetInterface(UObject *Target)
Returns true if the given object implements the required target interface.
Declaration
protected: virtual bool ImplementsTargetInterface(UObject *Target) const =0
Parameters
Type |
Name |
Description |
UObject * |
Target |
|
Returns
|
Improve this Doc
View Source
RaiseEnterFocusEvent(UObject *Target, UUxtNearPointerComponent *Pointer)
Notify the target object that it has entered focus.
Declaration
protected: virtual void RaiseEnterFocusEvent(UObject *Target, UUxtNearPointerComponent *Pointer) const =0
Parameters
|
Improve this Doc
View Source
RaiseExitFocusEvent(UObject *Target, UUxtNearPointerComponent *Pointer)
Notify the target object that it has exited focus.
Declaration
protected: virtual void RaiseExitFocusEvent(UObject *Target, UUxtNearPointerComponent *Pointer) const =0
Parameters
|
Improve this Doc
View Source
RaiseUpdateFocusEvent(UObject *Target, UUxtNearPointerComponent *Pointer)
Notify the focused target object that the pointer has been updated.
Declaration
protected: virtual void RaiseUpdateFocusEvent(UObject *Target, UUxtNearPointerComponent *Pointer) const =0
Parameters
|
Improve this Doc
View Source
Select the closest primitive from the owner of the given target component. The target component will be the new focus, unless no usable primitive can be found.
Declaration
public: void SelectClosestPointOnTarget(UUxtNearPointerComponent *Pointer, const FTransform &PointerTransform, UActorComponent *NewTarget)
Parameters
Type |
Name |
Description |
UUxtNearPointerComponent * |
Pointer |
|
const FTransform & |
PointerTransform |
|
UActorComponent * |
NewTarget |
|
|
Improve this Doc
View Source
Select and set the focused target among the list of overlaps.
Declaration
public: void SelectClosestTarget(UUxtNearPointerComponent *Pointer, const FTransform &PointerTransform, const TArray<FOverlapResult> &Overlaps)
Parameters
Type |
Name |
Description |
UUxtNearPointerComponent * |
Pointer |
|
const FTransform & |
PointerTransform |
|
const TArray<FOverlapResult> & |
Overlaps |
|
|
Improve this Doc
View Source
Set the focus to the given target object, primitive, and point on the target.
Declaration
protected: void SetFocus(UUxtNearPointerComponent *Pointer, const FTransform &PointerTransform, UObject *NewTarget, UPrimitiveComponent *NewPrimitive, const FVector &NewClosestPointOnTarget)
Parameters
Type |
Name |
Description |
UUxtNearPointerComponent * |
Pointer |
|
const FTransform & |
PointerTransform |
|
UObject * |
NewTarget |
|
UPrimitiveComponent * |
NewPrimitive |
|
const FVector & |
NewClosestPointOnTarget |
|
|
Improve this Doc
View Source
Update the ClosestTargetPoint while focus is locked
Declaration
public: void UpdateClosestTarget(const FTransform &PointerTransform)
Parameters
Type |
Name |
Description |
const FTransform & |
PointerTransform |
|
|
Improve this Doc
View Source
UpdateFocus(UUxtNearPointerComponent *Pointer)
Notify the focused target of a pointer update.
Declaration
public: void UpdateFocus(UUxtNearPointerComponent *Pointer) const
Parameters