Does anyone know how the achieve this? I’m calculating the angle in Verse, but can’t find a way to rotate an image?
This is my code for now, but I can’t change the angle for any variable or class available.
var VisualCueImage: texture_block = texture_block{ DefaultImage:= Image.arrow, DefaultDesiredSize:=vector2{X:=200.0, Y:=200.0}}
var MyUI: overlay = overlay{}
InitializeUI(Agent: ?agent):void=
Print("UI Initialized", ?Duration:=5.0)
if:
ThisAgent:= Agent?
ThisPlayer:= player[ThisAgent]
PlayerUI:= GetPlayerUI[ThisPlayer]
then:
set MyUI = CreateMyUI()
PlayerUI.AddWidget(MyUI)
CreateMyUI():overlay=
Print("UI Created", ?Duration:=5.0)
MyOverlay: overlay = overlay:
Slots := array:
overlay_slot:
Widget := VisualCueImage
HorizontalAlignment := horizontal_alignment.Center
VerticalAlignment := vertical_alignment.Center
return MyOverlay
UpdateMyUI(Angle: float):void=
Print("UI Updated", ?Duration:=5.0)