static String Parser.SaidUnknownWord()
If a word not in the game dictionary was submitted to the last ParseText
call, then the word is returned by this command. This allows you to display a
message like "Sorry, this game doesn't recognise 'XXXX'."
If all the words were recognised, this returns null.
Example:
String badWord = Parser.SaidUnknownWord();
if (badWord != null)
Display("You can't use '%s' in this game.", badWord);
will display the message if the player types a word that's not in the vocabulary.
See Also: Parser.ParseText, Parser.Said
|