Game Development Community

Dialog onWake

by Howard Dortch · in Torque Game Engine · 01/12/2005 (8:25 am) · 5 replies

I have a dialog that is activated by setContent() from there I have another dialog set using pushDialog() When the second dialog is pushed and the onWake function is called it immediately returns to the first one after all the functions in the onWake are finished. Any way to stop this? There are selections to be made and it just bypasses everything and returns.

#1
01/13/2005 (2:54 am)
Are you maybe returning false? You can use trace() to see the return values and order of execution of script functions.
#2
01/13/2005 (7:03 am)
It doesn't return anything far as I can tell and it works fine as long as I dont call it from withing the join game dialog

Here is where the selectPlayer dialog is called
function JoinServerGui::join(%this)
{
cancelServerQuery();
Canvas.pushDialog(selectPlayer);
...... removed other code from fps demo for space
}

Wake up function in the dialog

function selectPlayer::onWake(%this)
{
view.race = "BlueClone";
view.setObject("Blue", "game/data/shapes/player/sarge/player.dts", "", 0);
view.loadDSQ("Blue","game/data/shapes/player/sarge/player_root.dsq");

selectPlayer.setBlue();
}
#3
01/13/2005 (7:06 am)
Oh forgot to add the fact that after selectPlayer.setBlue() is called it returns to the JoinServerGui::join and launched the game immediately so the user dont have a chance to select other player models.
#4
01/17/2005 (4:52 pm)
I hate to bump this up again but it's really becoming a problem. I have tried to push it, set content etc but it just exits without letting me make a choice.
#5
01/17/2005 (6:30 pm)
Not enough info. Email me your script file that handles these functions and I'll get you an answer.