home

articles

games

forum

contact

Monday, May 25, 2009

Back to work!

Memorial Day weekend is over, that means it's back to work!

Today, I'd like to take a look at the way the gui works for our games. A gui (graphical user interface) is one of those subtle things that people overlook. Usually, the only time people notice the gui, is when it's of poor quality. Fortunately, that's not the case with our gui ;)




label
name="title.tga" x="5" y="0" w="512" h="256"

button
name="start.tga" func="restart" x="40" y="40" w="256" h="64"

button
name="scores.tga" func="goto scores" x="38" y="60" w="256" h="64"

button
name="options.tga" func="goto options" x="37" y="80" w="256" h="64"

button
name="quit.tga" func="cmd quit" x="42" y="100" w="256" h="64"


Our gui is setup using xml scripts. The above script is used for the main menu. As of Space Smashout, the gui supports 6 different widgets. A widget is like a button or slider. The widgets our gui supports are buttons, labels, check boxes, comb boxes, sliders, and text fields. Many more widgets will be added for our next game!