-
-
Notifications
You must be signed in to change notification settings - Fork 6
Tutorial 01 . Label
Jean-David Moisan edited this page Feb 18, 2019
·
3 revisions
The GUI is simple to use. It's very raw.
To create a Label:
Label hello = new Label("Hello World!");
You can give it a position with:
hello.Position = new Point(20, 30);
In your update loop, call the following functions:
hello.UpdateSetup();
hello.UpdateInput();
hello.Update();
For a Label, those functions won't do anything, but it's good to know that they are there. It's also bad practice not to call them.
And in the draw loop:
GuiHelper.DrawGui(spritebatch, hello);
Note: Do not call Begin on the spritebatch that you pass.