Word input

Started by kantor_98, Wed 01/03/2006 10:32:59

Previous topic - Next topic

kantor_98

I want to ask the main character for something and I don't want if predefined (I will check in the game if what he give is OK). Has anybody a small script for introducing words (not more than 10 letters) ?

Ashen

If you're using 2.7 (which I guess you are), you could use InputBox(),  e.g.:
Code: ags

string temp;
InputBox("Who are you?", temp);
Display ("Hello, %s", temp);

For 2.71, that's been replaced with Game.InputBox, but works similarly.

If you want to customise the input box GUI, you're going to have to make your own using a TextBox GUI object. (Online manual entries refer to 2.71 - look them up yourself for 2.7)
I know what you're thinking ... Don't think that.

SMF spam blocked by CleanTalk