Manual:DIL Manual/roomflags
Jump to navigation
Jump to search
Contents
roomflags
Field (integer, read/write; units: rooms).
room.roomflags : integer
Bit flags of a room, set with romflags in the zone file. The server saves them with the room but nothing in it reads them: no room flag constants are defined in vme.h, and no zone in this repository tests them. The set command (set.zon) can change them. Most of what a room's flags might be expected to do (no teleport, no weather, no mobiles, ...) is in the unit flags (UNIT_FL_...).
Notes
- On anything that is not a room, and on null, it fails.
- Stored as an unsigned 8-bit number: values outside 0 to 255 wrap around. No access level is needed to assign it.
Example
dilbegin integer has_roomflag(room : unitptr, bit : integer);
code
{
if (room.type != UNIT_ST_ROOM)
return (FALSE);
return (isset(room.roomflags, bit));
}
dilend
Tests a bit of a room's flags, for a zone that gives the bits a meaning of its own.