the-infocom-files / witness

The Witness
3 stars 4 forks source link

You can turn on the water anywhere #10

Open eriktorbjorn opened 4 years ago

eriktorbjorn commented 4 years ago
>LOOK
You are now on the driveway.
The driveway, paved with peastone, runs from the entrance at the south end in a
curve to a two-car garage at the east end. North of you is the front porch, the
entrance to the house.

>TURN ON WATER
You turn the handle and lo! The water starts to run. Impressed with yourself,
you turn the handle again, and the water stops running! You try it again, just
to make sure. Bravo!

That's because V-LAMP-ON does this:

<ROUTINE V-LAMP-ON ()
     <COND (<DOBJ? SINK GLOBAL-WATER>
        <TELL
"You turn the handle and lo! The water starts to run. Impressed
with yourself, you turn the handle again, and the water stops
running! You try it again, just to make sure. Bravo!" CR>)

I'm not sure what the best solution here is. Perhaps the least intrusive way would be to check if there is a local global SINK in the room?