Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: Yo Mama! on Wed 04/06/2003 20:53:51

Title: How do I make GUIs appear at a certain time?
Post by: Yo Mama! on Wed 04/06/2003 20:53:51
I have 2 GUI questions that popup one after the other. The problem is that they popup on top of each other. How do I make the second one appear AFTER the first one has been answered and all the text has gone by? Here is the code I’m using:
if (game.score ==0) {DisplaySpeech (CHARID , "message 1 for score 0");
DisplaySpeech (CHARID , "message 2 for score 0");}
else if (game.score ==1) {DisplaySpeech (CHARID , "Message 1 for score 1");GUIOn (2);
DisplaySpeech (CHARID , "Message 2 for score 1");GUIOn (3);}
else {DisplaySpeech (CHARID, "Message 1 for any other score");
DisplaySpeech (CHARID , "Message 2 for any other score");}  
}
Title: Re:How do I make GUIs appear at a certain time?
Post by: Pumaman on Wed 04/06/2003 21:10:00
I don't quite understand the question but don't you just mean this:

if (game.score ==0)
DisplaySpeech (CHARID , "message 1 for score 0");
DisplaySpeech (CHARID , "message 2 for score 0");
}
else if (game.score ==1)
DisplaySpeech (CHARID , "Message 1 for score 1");
GUIOn (2);
DisplaySpeech (CHARID , "Message 2 for score 1");
GUIOff (2);
GUIOn (3);
}
else
DisplaySpeech (CHARID, "Message 1 for any other score");
DisplaySpeech (CHARID , "Message 2 for any other score");
}
Title: Re:How do I make GUIs appear at a certain time?
Post by: Yo Mama! on Wed 04/06/2003 23:44:57
Let me re-phrase the question. The Player meets up with another person, and the other person says 1 or 2 phrases (depending upon what the score is), and then it asks the player if they want to get rid of their points in order for money. It also asks if the player wants to get rid of all their inventory items for money. The second one pops up at the same time as the first one does, not letting the player have enough time to select Yes or No to the first question. How do I make it so that the second one comes up after the player presses Yes or No on the first one?
Title: Re:How do I make GUIs appear at a certain time?
Post by: Yo Mama! on Wed 04/06/2003 23:46:24
WAIT! I just had an idea that would work. I could just make the buttons on the first one open the second one when they are clicked. I don't know why I didn't think of that before.
Title: Re:How do I make GUIs appear at a certain time?
Post by: Pumaman on Thu 05/06/2003 19:15:28
Hehe yep, that's the way to do it.