1
0
Fork 0
mirror of https://github.com/ganelson/inform.git synced 2024-07-05 16:44:21 +03:00
inform7/resources/Documentation/Examples/Inquisitions.txt
2019-03-16 13:12:11 +00:00

35 lines
2.2 KiB
Plaintext

* Reading and talking
(Sybil: 1. ASK, TELL, and ANSWER conflated--ASK, TELL, and ANSWER commands rolled into one)
Direct all ASK, TELL, and ANSWER commands to ASK, and accept multiple words for certain cases.
Sometimes we do not particularly want to deal with all the variations on asking, telling, or answering someone something, but want to direct everything to a single conversational command:
{*}"Consulting the Oracle"
The Grove is a room. In the Grove is a woman called the Sybil.
Instead of telling someone about something, try asking the noun about it. Instead of answering the noun that something, try asking the noun about it.
Instead of asking the Sybil about "persians", say "She nods gravely."
And similarly, a difference between GIVE and SHOW is sometimes overkill:
{**}Instead of showing something to someone, try giving the noun to the second noun.
The player carries a coin. Instead of giving the coin to the Sybil: move the coin to the Sybil; say "She accepts with a smile."
It is also often the case that we want to accept more than one form of a term. For instance
{**}Instead of asking the Sybil about "Darius/king", say "Her smile unnerves you."
will match either "Darius" or "king". If necessary, we can go a step further and define our own token to match a variety of phrases, like this:
{**}Understand "Athenians/Spartans/Greeks" or "hoplite army/forces" as "[Greeks]". Instead of asking the Sybil about "[Greeks]", say "She looks encouraging."
The token "[Greeks]" will match all of "Athenians", "Spartans", "Greeks", "hoplite army", or "hoplite forces". It will not match "hoplite" or "forces" alone; it is important to note that the / divides individual words which are understood equivalently, but does not define entire phrases as equivalent. More about how Inform understands specific phrases can be found in the chapter on Understanding.
{**}Test me with "test one / test two".
Test one with "ask sybil about persians / tell sybil about persians / sybil, persians / ask sybil about darius / ask sybil about king".
Test two with "ask sybil about greeks / ask sybil about athenians / ask sybil about hoplite army / ask sybil about hoplite forces / give the coin to the sybil".