UI interact in separate actor

Pop-up User interface on wrist



Create a Widget called WristUI
Add variable Text in Graph
image.png
bind Text in Content of “Pressed” layer in Designer
image.png
type Pressed in set node
image.png

Open VR Pawn, add a Widget and set its transform and widget class as follow:
image.png
Add Arrow compoent and set its transfrom (for what direction player needs to be facing to trigger UI)
image.png

Set WidgetInteraction right trace channel to Visibility, show debug
image.png

Go to event graph, create event tick node, and a new function name as DetectHandWidget (to detect when playaer hand and face face to each other)

image.png
== node value 0.35, if higher value makes pop up more sensitive, lower opposite

Duplicate all nodes, but swap input between arrow and camera this time, set == value form 0.35 to 0.7:
image.png
Finish the graph as this:
image.png

Back to event graph, drag newly created function, set visible of debug as below:
image.png
Duplicate the 4 nodes, change visible and debug opposite, connect to false branch
image.png

Plug out Inputaction trigger right node, connect as below:
image.png

Drag the VR pawn in scene, set player 0 at:
image.png
Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.