Room Description Headings

version 1/090620 by Erwin Genstein

  • Home page
  • Beginning
  • Previous
  • Next



  • Section: New Variables

    The following new variables are provided by this extension, for use in the new activities.

    Note that these variables are not intended for use outside the new activities.

        The apparent location (a thing that varies)
        The player's enclosure (a thing that varies)
        The described enclosure (a thing that varies)
        The enclosure ancestry count (a number that varies)
        The enclosure ancestry index (a number that varies)

    "The apparent location" indicates the thing whose name appears in bold as the room description heading. This is often the location, but not always: if the player is inside a closed container, that will be the apparent location; if the player is in darkness, the apparent location will be nothing.

    "The player's enclosure" indicates the thing which most immediately encloses the player. If the player is simply standing in a room, then the player's enclosure is that room (the location). If the player is in darkness, it is set to nothing.

    "The described enclosure" varies during the course of the "listing enclosures" activity. It always indicates the enclosure which is currently being described. It is always set correctly prior to carrying out the "printing an enclosure description" activity. In the example from the previous section, it will first be the box, then the conveyor belt, then the platform.

    "The enclosure ancestry count" is set up when the "listing enclosures" activity begins. It indicates the number of things which will appear in the list of enclosures after the player's enclosure. In the example from the previous section, it will be two, since two things are listed after the player's enclosure.

    "The enclosure ancestry index" varies during the course of the "listing enclosures" activity. It is zero when describing the player's enclosure; one when describing the thing, if any, which encloses that; two when describing the thing, if any, which in turn encloses that; and so on. In the example from the previous section, it is zero when printing an enclosure description for the box; one when printing an enclosure description for the conveyor belt; and two when printing an enclosure description for the platform.