I’m trying to set a check that checks is the result is no text, but I’m not sure how to say “no text” in terms Inform understands. “Blank” seemed likely, but no-go…
What about “”? (I did not test it, but it seems like the most natural representation of the empty text string.)
Victor’s right:[code]Lab is a room. The bat is in Lab.
The ball is in Lab. The description is “Here’s a great description of a ball.”
Instead of examining:
if the description of the noun is “”,
say “The author of this game was to lazy to write a description.”;
otherwise continue the action.
test me with “x ball / x me / x bat / showme bat”.[/code]
The easiest way of finding out the default value of a kind or kind of value is to look under the Index --> Kinds tab. Not every kind of value in Inform has an equivalent to “nothing,” but if not they have a starting value. (Note that in the above example, the player (actually “yourself”) has a default description built into the standard rules.)
That’s correct: “”
If you go to the Kinds tab in the index, it lists the “default value” of every kind. This is is what gets filled in for properties or variables of that kind if you don’t set another value. It’s also the result of “to decide which…” phrases if you don’t decide on a value.
I think “empty” works too.
I can confirm this works in the above example: changing
if the description of the noun is "",
if the description of the noun is empty,
I didn’t know about this syntax. Thanks Cap.