outside room #364

Parent #6792Owner Flags Source rpg_march_2006/Dependencies/364.txt

Aliases: outside room

5 verbs · 13 properties · 1 children

Verbs

VerbSpecFlagsDefinerLines
descriptionthis none this#36417
dawn_msg night_msg dusk_msg day_msgthis none this#3641
time_of_day_msgthis none this#36416
sunthis none this#3644
is_outsidethis none this#3642

Properties

PropertyDefinerFlagsOwnerValue
dawn_msg#364rc"The sun is rising over the bay."
night_msg#364rc"In the southern skies, Mercury, Venus Mars and Jupiter form a spectacular display."
dusk_msg#364rc"The sun falls rapidly out of sight behind the Los Altos Hills"
day_msg#364rc"The sun is shining, the birds are singing."
outside_messages_enabled#364rc1
enabled#3641
residents#364{#102, #82, #259}
free_entry#3640
entrances#364not readable (E_PERM)
exits#364not readable (E_PERM)
key#364not readable (E_PERM)
aliases#364{"outside room"}
object_size#364{3898, 1141286558}

Ancestry

Ancestors (nearest first): #6792 Generic Integrating Description Room#3879 Matching Room#27777 Self-Cleaning Room

Children: #1610 RPG RDB room

Call graph

calls n364_0 #364:description n364_4 #364:is_outside n364_0->n364_4 n6792_1 #6792:description n364_0->n6792_1 n364_2 #364:time_of_day_msg n364_0->n364_2 n364_3 #364:sun n364_2->n364_3 n364_1 #364:dawn_msg n364_2->n364_1

Source

description

Spec this none thisDefiner #364

Referenced by

Source

1"This description returns the passed arguments, PLUS a message on the room which is selected according to where the sun is positioned.";
2"If this.outside_messages_enabled == 0, it simply returns its parents arguments.";
3"Modified Feb 3 1993, darkrider";
4if (!this:is_outside())
5  return pass(@args);
6endif
7"Do that funky outside messages thing.";
8mess = this:time_of_day_msg();
9foo = pass(@args);
10if ((typeof(mess) != STR) || (mess == ""))
11  return pass(@args);
12elseif (typeof(foo) == LIST)
13  return {@foo, mess};
14else
15  return (tostr(foo) + this.look_sep_msg) + mess;
16endif
17"quinn 17-oct-93 2040: put time-of-day stuff into a separate verb.";

dawn_msg night_msg dusk_msg day_msg

Spec this none thisDefiner #364

Referenced by

Source

1return this.(verb);

time_of_day_msg

Spec this none thisDefiner #364

Referenced by

Source

1":time_of_day_msg([NUM time])";
2"-> Message reflecting the appearance of this room at the current time of day.";
3time = args ? args[1] | time();
4sun = this:sun(time);
5if (sun < -1500)
6  mess = this:night_msg();
7elseif (sun > 1500)
8  mess = this:day_msg();
9elseif (tonum(ctime(time)[12..13]) < 12)
10  "not a robust test, probably give the wrong answer in northern Norway for instance.";
11  mess = this:dawn_msg();
12else
13  mess = this:dusk_msg();
14endif
15return mess;
16"quinn 17-oct-93 2041: cut code from :description into this.";

sun

Spec this none thisDefiner #364

Referenced by

Source

1":sun([NUM time]) -> Number representing the sun's position.";
2"By default passes to $time_utils.  See that verb for formulae.";
3return $time_utils:sun(@args);
4"quinn 17-oct-93 2044: allow for specialised time-of-day reporting.";

is_outside

Spec this none thisDefiner #364

Referenced by

Source

1":is_outside() -> Is the room non-enclosed, outdoors, exterior, etc...";
2return this.outside_messages_enabled;