§3.4. Continuous Spaces and The Outdoors

Suppose we want to blur the boundaries between rooms, in an environment where there are no walls: out of doors, for instance?

The simplest cases involve making something exceptional visible in more than one place. Carnivale features an exceptionally large landmark seen by day; Eddystone an exceptionally bright one by night. Waterworld allows a very distant object (the Sun) to be seen throughout many rooms, but never approached. View of Green Hills gives the player an explicit command for looking through into an adjacent room.

Three systematic examples then present outdoor landscapes with increasing sophistication. Tiny Garden gives the multiple rooms of an extended lawn descriptions which automatically adapt to say which directions lead into further lawn area. Rock Garden provides a relation, "connected with", between rooms, allowing items in one to be seen from the other: an attempt to interact with a visible item in a different area of the garden triggers an implicit going action first. Stately Gardens provides a much larger outdoor area, where larger landmarks are visible from further away, and room descriptions are highly adaptive.

In an outdoor environment, the distinction between a one-move journey and a multiple-move journey is also blurred. Hotel Stechelberg shows a signpost which treats these equally.

* See Position Within Rooms for making the space within a room continuous

* See Windows for another way to see between locations

* See Doors, Staircases, and Bridges for still a third way to be told at least what lies adjacent

* See Passers-By, Weather and Astronomical Events for more on describing the sky


arrow-up.pngStart of Chapter 3: Place
arrow-left.pngBack to §3.3. Position Within Rooms
arrow-right.pngOnward to §3.5. Doors, Staircases, and Bridges

It's tempting to handle the player's inability to interact with something with a simple instead rule:

paste.png "Waterworld 1"

A view is a kind of backdrop. Instead of doing something other than examining to a view, say "You are too far from [the noun] to do anything but look."

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun".

Unfortunately, the rule does not address the case where the object in question is the second noun; so for instance the following example reveals the difficulty:

paste.png "Waterworld 2"

A view is a kind of backdrop. Instead of doing something other than examining to a view, say "You are too far from [the noun] to do anything but look."

The player carries a rope.

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun / tie rope to the sun".

...where the response here behaves as though the sun is in reach. If we had a fully implemented tying action, the player would (even more disastrously) be allowed to lasso celestial objects.

We could add a second instead rule as well:

paste.png "Waterworld 3"

A view is a kind of backdrop.

Instead of doing something other than examining when the noun is a view:
    say "You are too far from [the noun] to do anything but look."
Instead of doing something other than examining when the second noun is a view:
    say "You are too far from [the second noun] to do anything but look."

The player carries a rope.

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun / tie rope to sun".

This produces acceptable output again, but there is a more elegant way, one that works better with Inform's existing world model. Currently the default model assumes that accessibility -- whether the player can reach something or not -- is checked between the Before... rules and the Instead... rules. We can add our own accessibility rules, including this one to govern whether views are accessible. So for instance:

paste.png "Waterworld 4"

A view is a kind of backdrop.

The can't touch views rule is listed before the access through barriers rule in the accessibility rulebook.

Accessibility rule (this is the can't touch views rule):
    if the action requires a touchable noun and the noun is a view:
        say "You are too far from [the noun] to do anything but look." instead;
    if the action requires a touchable second noun and the second noun is a view:
        say "You are too far from [the second noun] to do anything but look." instead;

The player carries a rope.

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun / tie rope to sun".

Now our new accessibility rule fits into its proper stage.

*ExampleWaterworld
A backdrop which the player can examine, but cannot interact with in any other way.

It's tempting to handle the player's inability to interact with something with a simple instead rule:

paste.png "Waterworld 1"

A view is a kind of backdrop. Instead of doing something other than examining to a view, say "You are too far from [the noun] to do anything but look."

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun".

Unfortunately, the rule does not address the case where the object in question is the second noun; so for instance the following example reveals the difficulty:

paste.png "Waterworld 2"

A view is a kind of backdrop. Instead of doing something other than examining to a view, say "You are too far from [the noun] to do anything but look."

The player carries a rope.

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun / tie rope to the sun".

...where the response here behaves as though the sun is in reach. If we had a fully implemented tying action, the player would (even more disastrously) be allowed to lasso celestial objects.

We could add a second instead rule as well:

paste.png "Waterworld 3"

A view is a kind of backdrop.

Instead of doing something other than examining when the noun is a view:
    say "You are too far from [the noun] to do anything but look."
Instead of doing something other than examining when the second noun is a view:
    say "You are too far from [the second noun] to do anything but look."

The player carries a rope.

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun / tie rope to sun".

This produces acceptable output again, but there is a more elegant way, one that works better with Inform's existing world model. Currently the default model assumes that accessibility -- whether the player can reach something or not -- is checked between the Before... rules and the Instead... rules. We can add our own accessibility rules, including this one to govern whether views are accessible. So for instance:

paste.png "Waterworld 4"

A view is a kind of backdrop.

The can't touch views rule is listed before the access through barriers rule in the accessibility rulebook.

Accessibility rule (this is the can't touch views rule):
    if the action requires a touchable noun and the noun is a view:
        say "You are too far from [the noun] to do anything but look." instead;
    if the action requires a touchable second noun and the second noun is a view:
        say "You are too far from [the second noun] to do anything but look." instead;

The player carries a rope.

The sun is a view. It is everywhere. The description is "A blazing sun makes you wish you had never been born."

The Sahara is a room. North of the Sahara is More Sahara. North of More Sahara is Yet Further Sahara.

Test me with "x sun / get sun / n / x sun / n / x sun / tie rope to sun".

Now our new accessibility rule fits into its proper stage.

**ExampleTiny Garden
A lawn made up of several rooms, with part of the description written automatically.

**ExampleHotel Stechelberg
Signposts such as those provided on hiking paths in the Swiss Alps, which show the correct direction and hiking time to all other locations.

**ExampleCarnivale
An alternative to backdrops when we want something to be visible from a distance but only touchable from one room.

**ExampleEddystone
Creating new commands involving the standard compass directions.

**ExampleRock Garden
A simple open landscape where the player can see between rooms and will automatically move to touch things in distant rooms.

***ExampleA View of Green Hills
A LOOK [direction] command which allows the player to see descriptions of the nearby landscape.

***ExampleStately Gardens
An open landscape where the player can see landmarks in nearby areas, with somewhat more complex room descriptions than the previous example, and in which we also account for size differences between things seen at a distance.