PKmud - Rooms


#ROOMS
#1100
A dimly lit path~
You tread through the deep, dark forest on a dimly lit path. Up ahead you
can hear the faint sounds of a village.
~
11 0 3
D2
The dimly lit path leads south through the light forest.
~
~
0 -1 6000
D0
The dimly lit path leads north through the dense forest.
~
~
0 -1 1101
S
#1101
A dimly lit path~
You tread through the deep, dark forest on a dimly lit path. Up ahead you
can hear the faint sounds of a village.
~
11 0 3
D0
The dimly lit path leads north through the dense forest.
~
~
0 -1 1102
D2
The dimly lit path leads south through the dense forest.
~
~
0 -1 1100
S
.
.
.
#0

The above is a portion of the room section of The Shire.

"#ROOMS" denotes the beginning of the room section and is required.

"#1100" is the room's virtual number (VNUM) and must be unique among all rooms in the game. Good area building suggests using vnums QQ00 through QQ99, to allow the admin to use a cut and paste utility to replace the QQs with an available number block.

"A dimly lit path" is the room's name. This is what is shown when a player has brief on, types where on a player, etc. The tilde (~) is required.

The longer description after that is the full description, which is seen when a player types look, or has brief off and is moving. The tilde is required. Because this is PKmud, and not a normal MUD, the description need not be long, in fact, it is recommended it be no longer than a line.

"11" is the zone number. It isn't used, but in order to be consistant, use QQ just as in the vnum.

"0" is the room flags. It is a bitvector with values as denoted in the table below.

"3" is the sector type. It is an integer with values as denoted in the table below. This value is mostly not used; only water types matter, as they require boats. On normal MUDs, this value affects movement cost.

"S" denotes the end of a room's entry. Before "S", there may be multiple optional exits or additional descriptions.

"D" is for an exit. The format is:

D<direction>
<exit description>
~
<exit keywords>~
<locks> <key> <to_vnum>

The direction is an integer between 0 and 5 as follows:

number direction
0 north
1 east
2 south
3 west
4 up
5 down

The exit description is a string, and the tilde is required.

The exit keywords are additional words (beyond the direction) which a player can type "look <keyword>" with. The tilde is required.

locks is an integer which determines whether the exit is a door. It should be 1 if it is a door, 0 if it is not.

key is an integer which is the VNUM of the key object which can unlock the door. It should be 0 or -1 if the exit is not a door.

to_vnum is the VNUM of the room the exit goes to.

"E" is for additional descriptions:

E
<keywords>~
<description>
~

keywords and description are strings thus the tildes are required.

Room Flags table.

bit #define description
1 ROOM_DARK players need a light to see in this room
4 ROOM_NO_MOB Mobiles can not enter this room randomly.
8 ROOM_INDOORS Room is not affected by daylight, weather affects.
8192 ROOM_NO_RECALL Word of recall spell does not function.
16384 ROOM_NO_START Players can not start the war in this room.

Sector types table.

number #define
0 SECT_INSIDE
1 SECT_CITY
2 SECT_FIELD
3 SECT_FOREST
4 SECT_HILLS
5 SECT_MOUNTAIN
6 SECT_WATER_SWIM
7 SECT_WATER_NOSWIM
8 SECT_UNUSED
9 SECT_AIR
10 SECT_DESERT