Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: ThunderStorm on Sun 15/06/2003 18:20:05

Title: Dialog interferes with GUIOff [solved]
Post by: ThunderStorm on Sun 15/06/2003 18:20:05
Hi there, I've got the following problem:

I have a verb coin gui with three buttons for look, talk and interact. When a button is pressed, the corresponding action is triggered by a code similar to this:

if (button ==1){ // Look
GUIOff(COIN);
ProcessClick(mouse.x, mouse.y, MODE_LOOK);
}

This works fine except for the TALK action, when a characters 'talk to character' script runs a dialog. The coin stays on screen until a dialog option has been clicked, then it vanishes. I have tried to put a GUIOff command right before the RunDialog command as well as running it from a run-script command - it always results in the same.

Is there a way to make the coin GUI disappear before the dialog options are displayed?
Title: Re:Dialog interferes with GUIOff
Post by: Pumaman on Sun 15/06/2003 18:44:54
Something like this should work:

GUIOff(COIN);
Wait(1);
ProcessClick(mouse.x, mouse.y, MODE_TALK);

Good point though, the dialog system should really redraw the screen before displaying the options.
Title: Re:Dialog interferes with GUIOff
Post by: ThunderStorm on Sun 15/06/2003 18:51:36
Good solutions can be that simple...

Thanks Chris, I will try that right now.
Title: Re:Dialog interferes with GUIOff
Post by: ThunderStorm on Mon 16/06/2003 16:58:25
Yeah, now it works just as I expected.
Thanks again!