Rip Van Winkle
Example 355
★There are times when, for greater elegance of prose, we'd like to mention an object in the main body text of a room. For instance:
Here is a lovely, secluded fold in the mountains, far from civilization: as though to prove it, Rip Van Winkle is sleeping under a tree.
As we've already seen, that's no problem if Rip is scenery. He'll stay there motionless.
But what if something in the game allows Rip to wake up? Or what if we want to use the same technique on a portable object that the player should be allowed to take? Clearly in that case it's not appropriate to make the mentioned thing be scenery, and at the same time, we need to keep Inform from adding a superfluous
You can see Rip Van Winkle here.
to the end of our description.
Here is how:
"Rip Van Winkle"
A person can be asleep.
The Catskills is a room. "Here is a lovely, secluded fold in the mountains, far from civilization[if Rip Van Winkle is asleep]: as though to prove it, Rip Van Winkle is sleeping under a tree[end if]."
A tree is scenery in the Catskills.
Rip Van Winkle is a man in the Catskills. Rip Van Winkle is asleep.
Before listing nondescript items of the Catskills:
if Rip Van Winkle is marked for listing:
now Rip Van Winkle is not marked for listing;
if Rip Van Winkle is not asleep,
say "Rip Van Winkle stands here, looking mightily confused."
Instead of waiting:
say "Rip Van Winkle wakes up with a snort.";
now Rip Van Winkle is not asleep.
Test me with "look / z / look".
Test me with "look / z / look".
Catskills
Here is a lovely, secluded fold in the mountains, far from civilization: as though to prove it, Rip Van Winkle is sleeping under a tree.
>(Testing.)
>[1] look
Catskills
Here is a lovely, secluded fold in the mountains, far from civilization: as though to prove it, Rip Van Winkle is sleeping under a tree.
>[2] z
Rip Van Winkle wakes up with a snort.
>[3] look
Catskills
Here is a lovely, secluded fold in the mountains, far from civilization.
Rip Van Winkle stands here, looking mightily confused.
Here is a lovely, secluded fold in the mountains, far from civilization: as though to prove it, Rip Van Winkle is sleeping under a tree.
>(Testing.)
>[1] look
Catskills
Here is a lovely, secluded fold in the mountains, far from civilization: as though to prove it, Rip Van Winkle is sleeping under a tree.
>[2] z
Rip Van Winkle wakes up with a snort.
>[3] look
Catskills
Here is a lovely, secluded fold in the mountains, far from civilization.
Rip Van Winkle stands here, looking mightily confused.