Skip to content

Instantly share code, notes, and snippets.

@nicoplv
Created April 16, 2025 12:06
Show Gist options
  • Save nicoplv/f315006a9b9ba7bd03646660d4abef46 to your computer and use it in GitHub Desktop.
Save nicoplv/f315006a9b9ba7bd03646660d4abef46 to your computer and use it in GitHub Desktop.
Workaround to make the ui works on console
PlayerUI.RemoveWidget(BufferCanvasA)
PlayerUI.AddWidget(CanvasA, player_ui_slot{InputMode := ui_input_mode.None })
CanvasA.SetEnabled(false)
Sleep(0.25)
CanvasB.SetEnabled(true)
BufferCanvasB := canvas{}
BufferCanvasB.AddWidget(canvas_slot:
Anchors := anchors{Minimum := vector2{X := 0.0, Y := 0.0}, Maximum := vector2{X := 1.0, Y := 1.0}}
Offsets := margin{Top := 0.0, Left := 0.0, Right := 0.0, Bottom := 0.0}
Alignment := vector2{X := 0.5, Y := 0.5}
SizeToContent := false
Widget := CanvasB
)
PlayerUI.RemoveWidget(BufferCanvasB, player_ui_slot{InputMode := ui_input_mode.All })
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment