Game Development Community

Popup error in the TSE gui

by David \"lp\" Rosen · in Torque Game Engine Advanced · 06/14/2007 (8:35 am) · 1 replies

Hi! I'm coding a new options gui for the game Dreamlords thats using Torque.

I'm unable to set a value for GuiPopUpMenuCtrl - it automatically selects "" -1, instead of what im trying to make it select.

There's a popup error in the TSE where we (I, but i've asked around in the office) where we create a GuiPopUpMenuCtrl, we add some menuitems, and then try to use the classes function "setSelected(S32)" to make it automatically select the first option - except it won't, whatever we try to throw at it. We have accessed the ID for the popupctrl successfully within the setSelected function.

Anyway, I'm stumped and don't really know how to progress.

#1
06/15/2007 (1:22 am)
Resolved, by putting it in the onWake() function instead of the onAdd() constructor.