[MUD-Dev] Dynamically changing room descriptions

Christopher Allen GMFangs at ASMRB.org
Mon May 17 16:12:59 CEST 1999


I wrote an "adjective" facility that allowed text descriptions to be
different based on time of day.

>From the DartMUD timeline() man page:

timeline(7) -- adjective giving text for different times of the day

timeline() is an adjective in the adjective server
"/std/serv/adjective.c" that allows you to add variety to your
descriptions by allowing you to have having minor differences
depending on the time of day as given by the time server.

Basically timeline() will chose from phrases separated by vertical
bars "|" one phrase in order LATENIGHT|SUNRISE|MORNING|NOON|
AFTERNOON|SUNSET|NIGHT, based on current time value returned by the
the time server.

Example:

return "{w}{timeline:The streetlights flicker. |The sunrise is nice. |"+
       "You smell breakfast. |The sun is high. |Children play here. |"+
       "The sunset is pretty.|Its a spooky night. }";

>From midnight until an hour before dawn:             The streetlights
flicker.
>From an hour before dawn 'til an hour after dawn:    The sunrise is nice.
>From an hour after dawn 'til hour before noon:       You smell breakfast.
>From an hour before noon 'til an hour after noon:    The sun is high.
>From an hour after noon 'til an hour before sunset:  Children play here.
>From an hour before sunset 'til an hour after sunset:The sunset is pretty.
>From an hour after sunset 'til midnight:             Its a spooky night.

NOTE: It is not possible to have phrases that include colons or vertical
bars! This is because the parser uses that colons to break up arguements in
adjectives, and timeline() only accepts one arguement and parses the
vertical
bars into separate phrases.

----- Original Message -----
Ronan Farrell <rfarrell at ssldesign.com> wrote:
> I am considering implementing a system where the room descriptions
> and properties change according to the weather, time of year and day.
> For example, we've all seen street lamps in Midgard, and nothing
> changes from day to night, surely they come on at night.  Similarly
> the idea that in winter, mountain passes may not be passable due to
> snow and weather, but in summer they are.
>
> I can think of several ways of doing this, but I am wondering if
> anyone has done anything similar, and whether people think it
> would be worth doing in the first place.




_______________________________________________
MUD-Dev maillist  -  MUD-Dev at kanga.nu
http://www.kanga.nu/lists/listinfo/mud-dev




More information about the mud-dev-archive mailing list