1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
4
<title>DM4 §A1: Library attributes</title>
5
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
6
<link rel="stylesheet" type="text/css" href="dm4.css">
7
<style type="text/css">
8
dd {text-align: justify; margin-bottom: 0.5em; }
13
<a href="index.html">home</a> /
14
<a href="contents.html">contents</a> /
15
<a href="app.html">appendices</a> /
16
<a href="app.html" title="Appendices">prev</a> /
17
<a href="sa2.html" title="§A2: Library properties">next</a> /
18
<a href="dm4index.html">index</a>
21
<a id="p418" name="p418"></a>
22
<h2>§A1 Library attributes</h2>
25
<dt><code>absent</code></dt>
26
<dd>A ‘floating object’ (one with a <code>found_in</code>
27
property, which can appear in many different rooms) which is <code>absent</code>
28
will in future no longer appear in the game. Note that you cannot make
29
a floating object disappear merely by giving it <code>absent</code>,
30
but must explicitly <code>remove</code> it as well.</dd>
32
<dt><code>animate</code></dt>
33
<dd>“Is alive (human or animal).” Can be spoken to in
34
“richard, hello” style; matches the <code>creature</code> token
35
in grammar; picks up “him” or “her” (according
36
to gender) rather than “it”, likewise “his”;
37
an object the player is changed into becomes <code>animate</code>; some
38
messages read “on whom”, etc., instead of “on
39
which”; can't be taken; its subobjects “belong to”
40
it rather than “are part of” it; messages don't assume
41
it can be “touched” or “squeezed” as an
42
ordinary object can; the actions <code>Attack</code>, <code>ThrowAt</code>
43
are diverted to <code>life</code> rather than rejected as being
44
‘futile violence’.</dd>
46
<dt><code>clothing</code></dt>
47
<dd>“Can be worn.”</dd>
49
<dt><code>concealed</code></dt>
50
<dd>“Concealed from view but present.” The player object
51
has this; an object which was the player until <code>ChangePlayer</code>
52
happened loses this property; a <code>concealed door</code> can't
53
be entered; does not appear in room descriptions.</dd>
55
<dt><code>container</code></dt>
56
<dd>Affects scope and light; object lists recurse through it if <code>open</code>
57
(or <code>transparent</code>); may be described as closed, open, locked,
58
empty; a possession will give it a <code>LetGo</code> action if the
59
player tries to remove it, or a <code>Receive</code> if something is
60
put in; things can be taken or removed from it, or inserted into it,
61
but only if it is <code>open</code>; likewise for “transfer”
62
and “empty”; room descriptions describe using <code>when_open</code>
63
or <code>when_closed</code> if given; if there is no defined description,
64
an <code>Examine</code> causes the contents to be searched (i.e. written
65
out) rather than a message “You see nothing special about…”;
66
<code>Search</code> only reveals the contents of containers, otherwise
67
saying “You find nothing”. <em>Note:</em> an object cannot
68
be both a <code>container</code> and a <code>supporter</code>.</dd>
70
<dt><code>door</code></dt>
71
<dd>“Is a door or bridge.” Room descriptions describe using
72
<code>when_open</code> or <code>when_closed</code> if given; and an
73
<code>Enter</code> action becomes a <code>Go</code> action. If a
74
<code>Go</code> has to go through this object, then: if <code>concealed</code>,
75
the player “can't go that way”; if not <code>open</code>, then
76
the player is told either that this cannot be ascended or descended (if
77
the player tried “up” or “down”), or that it is in
78
the way (otherwise); but if neither, then its <code>door_to</code> property is
79
<a id="p419" name="p419"></a>
80
consulted to see where it leads; finally, if this is zero,
81
then it is said to “lead nowhere” and otherwise the player
82
actually moves to the location.</dd>
84
<dt><code>edible</code></dt>
85
<dd>“Can be eaten” (and thus removed from game).</dd>
87
<dt><code>enterable</code></dt>
88
<dd>Affects scope and light; only an <code>enterable</code> on the
89
floor can be entered. If an <code>enterable</code> is also a <code>container</code>
90
then it can only be entered or exited if it is <code>open</code>.</dd>
92
<dt><code>female</code></dt>
93
<dd>This object has a feminine name. In games written in English, this
94
makes her a female person, though in other languages it might be inanimate.
95
The parser uses this information when considering pronouns like “her”.
96
(In English, anything <code>animate</code> is assumed to be male
97
unless <code>female</code> or <code>neuter</code> is set.)</dd>
99
<dt><code>general</code></dt>
100
<dd>A general-purpose attribute, defined by the library but never
101
looked at or altered by it. Available for designers to use if they
102
choose to do so.</dd>
104
<dt><code>light</code></dt>
105
<dd>“Is giving off light.” (See <a href="s19.html">§19</a>.)
106
Also: the parser understands “lit”, “lighted”,
107
“unlit” using this; inventories will say “(providing
108
light)” of it, and so will room descriptions if the current
109
<code>location</code> is ordinarily dark; it will never be automatically
110
put away into the player's <code>SACK_OBJECT</code>, as it might plausibly
111
be inflammable or the main light source.</dd>
113
<dt><code>lockable</code></dt>
114
<dd>Can be locked or unlocked by a player holding its key object,
115
which is given by the property <code>with_key</code>; if a <code>container</code>
116
and also <code>locked</code>, may be called “locked” in
119
<dt><code>locked</code></dt>
120
<dd>Can't be opened. If a <code>container</code> and also <code>lockable</code>,
121
may be called “locked” in inventories.</dd>
123
<dt><code>male</code></dt>
124
<dd>This object has a masculine name. In games written in English, this
125
makes him a male person, though in other languages it might be inanimate.
126
The parser uses this information when considering pronouns like
127
“him”. (In English, anything <code>animate</code> is assumed
128
to be male unless <code>female</code> or <code>neuter</code> is set.)</dd>
130
<dt><code>moved</code></dt>
131
<dd>“Has been or is being held by the player.” Objects
132
(immediately) owned by the player after <code>Initialise</code> has run
133
are given it; at the end of each turn, if an item is newly held by
134
the player and is <code>scored</code>, it is given <code>moved</code>
135
and <code>OBJECT_SCORE</code> points are awarded; an object's
136
<code>initial</code> message only appears in room descriptions if it
137
is un<code>moved</code>.</dd>
139
<dt><code>neuter</code></dt>
140
<dd>This object's name is neither masculine nor feminine. (In English,
141
anything without <code>animate</code> is assumed neuter, because only
142
people and higher animals have gender. Anything <code>animate</code> is
143
assumed <code>male</code> unless <code>female</code> or <code>neuter</code>
144
is set. A robot, for instance, might be an <code>animate</code>
145
object worth making <code>neuter</code>.)</dd>
147
<dt><code>on</code></dt>
148
<dd>“Switched on.” A <code>switchable</code> object
149
with <code>on</code> is described by <code>with_on</code> in room
150
descriptions; it will be called “switched on” by <code>Examine</code>.</dd>
152
<dt><code>open</code></dt>
153
<dd>“Open door or container.” Affects scope and light;
154
lists (such as inventories) recurse through an <code>open
155
container</code>; if a <code>container</code>, called
156
<a id="p420" name="p420"></a>
157
“open” by some descriptions; things can be taken or removed from an <code>open
158
container</code>; similarly inserted, transferred or emptied. A
159
<code>container</code> can only be entered or exited if it is both
160
<code>enterable</code> and <code>open</code>. An <code>open door</code>
161
can be entered. Described by <code>when_open</code> in room
164
<dt><code>openable</code></dt>
165
<dd>Can be opened or closed, unless <code>locked</code>.</dd>
167
<dt><code>pluralname</code></dt>
168
<dd>This single object's name is in the plural. For instance, an
169
object called “seedless grapes” should have <code>pluralname</code>
170
set. The library will then use the pronoun “them” and
171
the indefinite article “some” automatically.</dd>
173
<dt><code>proper</code></dt>
174
<dd>Its short name is a proper noun, and never preceded by “the”
175
or “The”. The player's object must have this (so something
176
changed into will be given it).</dd>
178
<dt><code>scenery</code></dt>
179
<dd>Not listed by the library in room descriptions; “not portable”
180
to be taken; “you are unable to” pull, push, or turn it.</dd>
182
<dt><code>scored</code></dt>
183
<dd>The player gets <code>OBJECT_SCORE</code> points for picking it
184
up for the first time; or, if a room, <code>ROOM_SCORE</code> points
185
for visiting it for the first time.</dd>
187
<dt><code>static</code></dt>
188
<dd>“Fixed in place” if player tries to take, remove, pull,
191
<dt><code>supporter</code></dt>
192
<dd>“Things can be put on top of it.” Affects scope and
193
light; object lists recurse through it; a possession will give it
194
a <code>LetGo</code> action if the player tries to remove it, or
195
a <code>Receive</code> if something is put in; things can be taken
196
or removed from it, or put on it; likewise for transfers; a player
197
inside it is said to be “on” rather than “in”
198
it; room descriptions list its contents in separate paragraphs
199
if it is itself listed. <em>Note:</em> an object cannot be both
200
a <code>container</code> and a <code>supporter</code>.</dd>
202
<dt><code>switchable</code></dt>
203
<dd>Can be switched on or off; listed as such by <code>Examine</code>;
204
described using <code>when_on</code> or <code>when_off</code> in
205
room descriptions.</dd>
207
<dt><code>talkable</code></dt>
208
<dd>Player can talk to this object in “thing, do this”
209
style. This is useful for microphones and the like, when
210
<code>animate</code> is inappropriate.</dd>
212
<dt><code>transparent</code></dt>
213
<dd>“Contents are visible.” Affects scope and light;
214
a <code>transparent</code> container is treated as if it were
215
<code>open</code> for printing of contents.</dd>
217
<dt><code>visited</code></dt>
218
<dd>“Has been or is being visited by the player.” Given
219
to a room immediately after a <code>Look</code> first happens there:
220
if this room is <code>scored</code> then <code>ROOM_SCORE</code> points
221
are awarded. Affects whether room descriptions are abbreviated or not.</dd>
223
<dt><code>workflag</code></dt>
224
<dd>Temporary flag used by Inform internals, also available to outside
225
routines; can be used to select items for some lists printed by
226
<code>WriteListFrom</code>.</dd>
228
<dt><code>worn</code></dt>
229
<dd>“Item of clothing being worn.” Should only be an object
230
being immediately carried by player. Affects inventories; doesn't
231
count towards the limit of <code>MAX_CARRIED</code>; won't be automatically
232
put away into the <code>SACK_OBJECT</code>; a <code>Drop</code> action
233
will cause a <code>Disrobe</code> action first; so will <code>PutOn</code>
234
or <code>Insert</code>.</dd>
238
<a id="p421" name="p421"></a>
239
<p class="aside"><i>Note.</i> The only library attributes which
240
it's useful to apply to locations are <code>light</code>,
241
<code>scored</code> and <code>visited</code>.</p>
245
<a href="index.html">home</a> /
246
<a href="contents.html">contents</a> /
247
<a href="app.html">appendices</a> /
248
<a href="app.html" title="Appendices">prev</a> /
249
<a href="sa2.html" title="§A2: Library properties">next</a> /
250
<a href="dm4index.html">index</a>