Adventure Game Studio

AGS Support => Beginners' Technical Questions => Topic started by: Ghostlady on Sun 22/05/2005 20:57:49

Title: How to use text from player
Post by: Ghostlady on Sun 22/05/2005 20:57:49
Can someone give me an example of how to do this?  A hotspot in a room will ask a question, the player will answer the question and the game will know whether the answer is correct or not.  For example, the hotspot asks, "How many days are there in a year" and of course the correct answer would be 365, so if the player typed in 365, the player would know he had the correct answer and if he typed in 364, the player would know he had the wrong answer.  I want to do this with 10 questions in a row.  This is a first person game so there are no characters.  Any help is appreciated.
Title: Re: How to use text from player
Post by: Ishmael on Sun 22/05/2005 21:45:48
(http://koti.mbnet.fi/tk-/img/RTFM.gif) ;)

Search the manual for "Input Box", it'll give you a script function for input boxes, and look up the StrComp script function for string comparison. See the "See also"s too.
Title: Re: How to use text from player
Post by: Ghostlady on Mon 23/05/2005 01:43:15
I'm sorry.Ã,  I don't mean to be a pest.Ã,  I have my game 90% completed and I've only posted about 5 times.Ã,  That's not too bad, is it?Ã,  The AGS software is capable of doing so many things in different ways that sometimes it is confusing on what to do where.Ã,  Or sometimes you just need that one helpful person to say "input box" and the rest is easy as apple pie.Ã,  It is just knowing "input box" is the right way to go that helps.Ã,  I appreciate all the help that this forum gives, I couldn't have done it without you guys and gals.Ã,  Keep up the good work :)
Title: Re: How to use text from player
Post by: Ishmael on Mon 23/05/2005 11:28:42
Quote from: Ghostlady on Mon 23/05/2005 01:43:15
I'm sorry.  I don't mean to be a pest.

You're not a pest, notice the ;) in my post... I meant not to offend you or anything.
Title: Re: How to use text from player
Post by: TerranRich on Tue 24/05/2005 05:13:23
That's it, Ishmael. Go to your room cage. Now. ;)