Game Development Community

A quick question

by Yin Yi Jia · in Technical Issues · 07/30/2005 (8:18 am) · 5 replies

How to display a variable in a gui text control, it seems the text property do not accept variable.

thanks!

#1
07/30/2005 (9:30 am)
Function fpsHudUpdate(){
   MyfpsGUI.setText("FPS: " SPC $fps::real);
   schedule(1000, 0, "fpsHudUpdate");
}
#2
07/30/2005 (10:25 am)
GuiTextCtrls have a variable field specifically for this purpose. Just put '$myVariable' in that field and the control will always display the value of '$myVariable'.
#3
08/01/2005 (10:13 am)
I take it that variable must be a global?
#4
08/01/2005 (10:21 am)
Indeed
#5
08/08/2005 (9:27 am)
Thanks, guys.