Relative Placement And Direction by Jeff Nyman

Version 1.3

allowing relative directional movement as well as locationally relative descriptions.

You should create a "When play begins:" rule and make sure you have a phrase like this:

The player is facing <direction>.

Here <direction> is a cardinal compass direction.

This extension allows the player to make relative direction references for movement. For example, instead of saying a cardinal direction ("north", "east", etc), the player can say "go forward" or "go backward".

This will move the player in the direction that they are facing.

The player can also turn to face a relative direction by saying "turn left" or "turn right". It's also possible for the player to "turn around".

Directions allowed are "forward" or "f", "back" or "b", "left" or "l", and "right" or "r". There are some new verbs established that allow these relative directions to be used:

"turn left"
"turn right"
"turn around"

When the player moves to a new room, he will face the way he is traveling. So if the player is facing north in a given room but goes east (or left) they will be facing to the left when they get to the new room.

This extension provides a relation about "facing." So something can be set up as "to be facing [a direction]". For example, you could have this:

The statue is facing east.

Let's say this refers to a statue in a room where the player just entered it from the south and is facing north. If the player now examines that statue, the player will be facing west, as if they turned toward the statue to look at it. This is purely optional as no objects (or people) are required to have an orientation set in the story.

As part of the descriptions for objects or rooms, you can use a construct like this:

"[north facing]"

Here "north" can be replaced by any cardinal compass direction. (Or, rather, any of the straight compass directions: north, south, east, west. Currently diagnoal directions do not really work for this.) What this substitution does is produce text that provides a relative direction, such as "to your left", "to your right", "in front of you", or "behind you" depending on the direction the player is facing when the description is produced.

One downside is that, currently, the diagonal directions (northwest, northeast, southwest, southesat) are not fully supported. The directional commands should work in those contexts but a visual facing indicator is not possible in the status line display, as its unclear what symbol to use. So if the player is facing a diagonal direction, the visual indicator will simply be a bullet/point display.

For any rooms that use in / out or enter / exit), this can get tricky but you can allow the player to face a particular way upon leaving or entering. The extension makes sure that each room has a default-facing property and this can be set as such:

The default-facing of Long Water is east.

This will provide a default way for the player to be facing when one of the cardinal or relative directions is not used. If this value isn't specified, the default facing direction is north.

It's important to note that any of the directional information, movement, and orientation references are for the player character. There are no provisions to handle any of this for non-player characters.


A
 Example A Relative Stroll Through a Park

"A Relative Stroll Through a Park"

Include Relative Placement and Direction by Jeff Nyman.

Part

Locations