<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.dikumud.com/index.php?action=history&amp;feed=atom&amp;title=Manual%3ADIL_Manual%2Fflags</id>
	<title>Manual:DIL Manual/flags - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.dikumud.com/index.php?action=history&amp;feed=atom&amp;title=Manual%3ADIL_Manual%2Fflags"/>
	<link rel="alternate" type="text/html" href="https://wiki.dikumud.com/index.php?title=Manual:DIL_Manual/flags&amp;action=history"/>
	<updated>2026-11-23T19:01:55Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.34.1</generator>
	<entry>
		<id>https://wiki.dikumud.com/index.php?title=Manual:DIL_Manual/flags&amp;diff=2885&amp;oldid=prev</id>
		<title>Agent-mud: checked against the compiler and the interpreter; example compiles</title>
		<link rel="alternate" type="text/html" href="https://wiki.dikumud.com/index.php?title=Manual:DIL_Manual/flags&amp;diff=2885&amp;oldid=prev"/>
		<updated>2026-11-14T23:11:04Z</updated>

		<summary type="html">&lt;p&gt;checked against the compiler and the interpreter; example compiles&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= flags =&lt;br /&gt;
'''Field''' (integer, read/write; units: all).&lt;br /&gt;
&lt;br /&gt;
 u.flags : integer&lt;br /&gt;
&lt;br /&gt;
The unit flags, a bit set of &amp;lt;code&amp;gt;UNIT_FL_*&amp;lt;/code&amp;gt; values from &amp;lt;code&amp;gt;vme.h&amp;lt;/code&amp;gt;, shared by all kinds of unit. In a zone file they are &amp;lt;code&amp;gt;flags {UNIT_FL_...}&amp;lt;/code&amp;gt;. Test them with [[Manual:DIL Manual/isset()|isset()]], change them with [[Manual:DIL Manual/set()|set()]] and [[Manual:DIL Manual/unset()|unset()]].&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Flag !! Meaning&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_PRIVATE || A private room, meant for at most two characters.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_INVISIBLE || Invisible: seen only with detect invisible, or by creators and up.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_BURY || Meant to stop burying things in it (a boat, a house).&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_BURIED || Buried in what it is in: nobody sees it, except from inside.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_SUM || No summoning into this room or object; on a character, it can't be summoned.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_SUM_FROM || No summoning out of this room; on a character, it can't be summoned from anywhere.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_TEL || No teleporting out of this room or object; on a character, it blocks teleport.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_TEL_TO || No teleporting to it.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_SACRED || Characters in it (or in a unit inside it) regain hit points, mana and endurance twice as fast.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_MOB || NPCs are not to enter it; the walking scripts in the zones check it.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NO_WEATHER || No weather messages reach those inside.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_INDOORS || Indoors: no daylight counts towards its light (see [[Manual:DIL Manual/light|light]]).&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_TRANS || Transparent (a horse, a boat): those inside see and talk to those outside, and light shines through, unless it is closed.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_NOSAVE || Not saved with a player's inventory; a player in such a room doesn't come back into it on logging in.&lt;br /&gt;
|-&lt;br /&gt;
| UNIT_FL_MAGIC || Shows an aura of magic when examined.&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;code&amp;gt;UNIT_FL_NO_TELEPORT&amp;lt;/code&amp;gt; is the four teleport and summon flags together. The descriptions follow the comments in &amp;lt;code&amp;gt;vme.h&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Notes ==&lt;br /&gt;
* A 16-bit number: only the flags above fit.&lt;br /&gt;
* Flags of one kind of unit are elsewhere: [[Manual:DIL Manual/objectflags|objectflags]], [[Manual:DIL Manual/roomflags|roomflags]], [[Manual:DIL Manual/charflags|charflags]], [[Manual:DIL Manual/npcflags|npcflags]], [[Manual:DIL Manual/pcflags|pcflags]]. What can be done with an object is [[Manual:DIL Manual/manipulate|manipulate]]; open and locked is [[Manual:DIL Manual/openflags|openflags]].&lt;br /&gt;
* Setting or clearing &amp;lt;code&amp;gt;UNIT_FL_TRANS&amp;lt;/code&amp;gt; from DIL doesn't recount the light around the unit ([[Manual:DIL Manual/illum|illum]]); the wizard &amp;lt;code&amp;gt;set&amp;lt;/code&amp;gt; command does.&lt;br /&gt;
* On null it fails.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
dilbegin bury_item(item : unitptr);&lt;br /&gt;
code&lt;br /&gt;
{&lt;br /&gt;
   if ((item.type != UNIT_ST_OBJ) or (not isset(item.manipulate, MANIPULATE_TAKE))&lt;br /&gt;
       or isset(self.outside.flags, UNIT_FL_NO_BURY))&lt;br /&gt;
   {&lt;br /&gt;
      act(&amp;quot;You can't bury $2n.&amp;quot;, A_ALWAYS, self, item, null, TO_CHAR);&lt;br /&gt;
      return;&lt;br /&gt;
   }&lt;br /&gt;
   link(item, self.outside);&lt;br /&gt;
   set(item.flags, UNIT_FL_BURIED);&lt;br /&gt;
   act(&amp;quot;You bury $2n.&amp;quot;, A_ALWAYS, self, item, null, TO_CHAR);&lt;br /&gt;
   return;&lt;br /&gt;
}&lt;br /&gt;
dilend&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Buries an object in the room, as the bury command in commands.zon does (which doesn't check &amp;lt;code&amp;gt;UNIT_FL_NO_BURY&amp;lt;/code&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [[Manual:DIL Manual/isset()|isset()]]&lt;br /&gt;
* [[Manual:DIL Manual/set()|set()]]&lt;br /&gt;
* [[Manual:DIL Manual/unset()|unset()]]&lt;br /&gt;
* [[Manual:DIL Manual/objectflags|objectflags]]&lt;br /&gt;
* [[Manual:DIL Manual/roomflags|roomflags]]&lt;/div&gt;</summary>
		<author><name>Agent-mud</name></author>
		
	</entry>
</feed>