A Handy KitAn interactive fiction by Andrew Plotkin (2006) - the Inform 7 source text | |
Home page Contents Previous Next Complete text | Chapter 2 - The Environs
[This unimportant stuff declaration is my favorite part of the whole program.] Unimportant stuff is a kind of thing. Unimportant stuff is scenery. Instead of examining unimportant stuff, say "Nice, don't you think?" Instead of doing something other than examining or smelling unimportant stuff, say "For the sake of argument, let's say you'd rather play with your toolcase." [The smell system is straight from the "Art of Noise" example. But we add in perfume as a special case, because lots of things get perfumized at once. Having a perfumey object present summons the perfume cloud.] Understand the command "inhale" as "smell". A thing has a property called scent. The scent of a thing is usually "nothing". A thing can be perfumey. A thing can be perfumizable. Things are usually perfumizable. Unimportant stuff is never perfumizable. Scenery is always not perfumizable. Definition: a thing is scented if its scent is not "nothing". [but not if it's perfumey.] Instead of smelling a room (called locale): If a scented thing is in locale, say "You breathe in [the list of scented things in locale]."; otherwise say "The air is dead.". Rule for printing the name of something while smelling a room: say "[scent]" Instead of smelling something which is scented: say "You smell the [scent]." Instead of smelling something which is perfumey: say "It reeks of cheap perfume." Instead of smelling the toolcase when the toolcase is open and the toolcase encloses something perfumey: say "It reeks of cheap perfume." Instead of smelling the player when the player is perfumey: say "You've got cheap perfume all over you." [A cloud of perfume that hangs around after the stink bomb goes off. I can't make this a backdrop because I7 doesn't support condition-defined backdrops. Feature request filed.] The perfume cloud is scenery. Understand "nasty" or "reek" or "cheap" or "wave" as the perfume cloud. The scent of the perfume cloud is "lingering reek of perfume". Instead of examining the perfume cloud: try smelling the perfume cloud. The cloud-oneshot is a oneshot. Instead of doing something other than examining or smelling the perfume cloud, say "The reek is intangible[if first trying the cloud-oneshot]. (Never mind the distinct feeling that it is clawing at your soft palate.)[otherwise].[end if]". Every turn (this is the perfume backdrop rule): if a perfumey thing is touchable, move the perfume cloud to the location of the player; otherwise remove the perfume cloud from play. [The listening system is simpler, because only one thing in the game can make noise. Okay, except for the palms. Sorry.] Before listening to a room (called locale): if locale encloses the active relaxer, instead say "Gentle frog sounds fill the room." [And now, actual rooms.] The Arboretum is a room. "A nice place, if you do say so yourself who designed it. The scents of toxic Korean orchids blend with the rattling of the force-grown palms. An ivied arch to the north leads to your control center." The toxic Korean orchids are unimportant stuff in the Arboretum. Understand "orchid" or "flower" or "flowers" or "scent" as the orchids. The scent of the orchids is "thick, livid sweetness of orchids". The palm trees are unimportant stuff in the Arboretum. Understand "palms" or "tree" or "rattling" or "force-grown" as the palm trees. The ivied arch is scenery in the Arboretum. Understand "archway" as the ivied arch. Instead of entering the ivied arch, try going north. The Control Room is a room. It is north of the Arboretum. "The air is chill and dim beneath the high metal dome. Control panels stand here and there. To the south is an archway." The control panels are unimportant stuff in the Control Room. Understand "controls" as the control panels. The archway is scenery in the Control Room. Understand "arch" as the archway. Instead of entering the archway, try going south. |