<?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%2Fbaseweight</id>
	<title>Manual:DIL Manual/baseweight - 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%2Fbaseweight"/>
	<link rel="alternate" type="text/html" href="https://wiki.dikumud.com/index.php?title=Manual:DIL_Manual/baseweight&amp;action=history"/>
	<updated>2026-11-23T20:56:26Z</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/baseweight&amp;diff=2893&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/baseweight&amp;diff=2893&amp;oldid=prev"/>
		<updated>2026-11-14T23:11:28Z</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;= baseweight =&lt;br /&gt;
'''Field''' (integer, read-only; units: all).&lt;br /&gt;
&lt;br /&gt;
 u.baseweight : integer&lt;br /&gt;
&lt;br /&gt;
The weight of the unit itself, in pounds, without anything it carries or contains: an empty bag, a character's body. It is the &amp;lt;code&amp;gt;weight&amp;lt;/code&amp;gt; line of the unit in the zone file. The total, with contents, is the [[Manual:DIL Manual/weight|weight]] field, so &amp;lt;code&amp;gt;u.weight - u.baseweight&amp;lt;/code&amp;gt; is what the unit holds.&lt;br /&gt;
&lt;br /&gt;
== Notes ==&lt;br /&gt;
* Read-only: vmc refuses an assignment (&amp;quot;Illegal lvalue&amp;quot;). Use [[Manual:DIL Manual/set weight base|set_weight_base()]], which also changes the weight of the unit and of everything it is in.&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 size_part(part : unitptr, corpse : unitptr);&lt;br /&gt;
var&lt;br /&gt;
   w : integer;&lt;br /&gt;
code&lt;br /&gt;
{&lt;br /&gt;
   w := corpse.baseweight / 30;&lt;br /&gt;
   if (w &amp;gt; 100)&lt;br /&gt;
      w := 100;&lt;br /&gt;
   if (w &amp;lt; 1)&lt;br /&gt;
      w := 1;&lt;br /&gt;
   set_weight_base(part, w);&lt;br /&gt;
   return;&lt;br /&gt;
}&lt;br /&gt;
dilend&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Makes a body part weigh a thirtieth of the corpse it was cut from, between 1 and 100 pounds, as in death.zon.&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
* [[Manual:DIL Manual/weight|weight]]&lt;br /&gt;
* [[Manual:DIL Manual/set weight base|set_weight_base()]]&lt;br /&gt;
* [[Manual:DIL Manual/capacity|capacity]]&lt;/div&gt;</summary>
		<author><name>Agent-mud</name></author>
		
	</entry>
</feed>