I am fairly new to using tables in Inform 7 and I was wondering how one can use items as topics, so that the player can “ask man about golden watch” and get a reply. I figured I can use the [thing] token:
[code]Table of Answers
“[bourbon]” “Yes, you are encouraged to drink as much as you like”
“[crystal glass]” “I filled it up for you, I can fill it up again”
“[bedside table]” “Mi casa es tu casa”
“[refrigerator]” “Mi queso es tu queso”
“[drawer]” “Mi casa es tu casa”
“[cupboard]” “Mi casa es tu casa”
Instead of asking Colin about a topic listed in the Table of Answers:
say “’[Answer entry],’ Colin replies.”[/code]
The good thing with this is that, if I have already included an
Understand "fridge" as the refrigerator
I can “ask Colin about fridge” and still get the right answer.
The problem is that I don’t know how to combine multiple items in order to get the same answer (eg “Mi casa es tu casa”) without repeating the reply for each different item row. The structure “topic/topic/topic” or “topic” doesn’t seem to work with [tokens].
I am also wondering whether I could use more general rules, along the lines of:
Instead of asking Colin about a container