1 |
<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook V4.1//EN" [ |
2 |
<!ENTITY copyrightDates '2002,2003'> |
3 |
<!ENTITY % METACOSM SYSTEM "en.metacosm.ent"> |
4 |
%METACOSM; |
5 |
]> |
6 |
|
7 |
<article lang="EN"> |
8 |
<articleinfo> |
9 |
<title>Low level description v0.1</title> |
10 |
<corpauthor>&author;</corpauthor> |
11 |
<revhistory> |
12 |
<revision> |
13 |
<revnumber>CVS</revnumber> |
14 |
<date>$Date: 2002/11/08 20:05:58 $</date> |
15 |
</revision> |
16 |
</revhistory> |
17 |
<abstract><simpara>This document describes the Metacosm low level |
18 |
description system v0.1.</simpara></abstract> |
19 |
</articleinfo> |
20 |
|
21 |
&license; |
22 |
|
23 |
&project; |
24 |
|
25 |
<sect1><title>Low level description?</title> |
26 |
|
27 |
<glosslist> |
28 |
<glossentry id="lowleveldescription"> |
29 |
<glossterm>Low level description</glossterm> |
30 |
<glossdef> |
31 |
<para>The low level description (LLD) is the set of attributes used to |
32 |
describe Creatures, Items, Places and Actions, the possible values, |
33 |
etc. in the server's memory ( internal format of descriptions before |
34 |
it is served to players and transformed by Metacosm clients to text, |
35 |
sound, graphics, etc.). The protocol between the server and multimedia |
36 |
clients will feature a subset of the LLDs.</para> |
37 |
</glossdef> |
38 |
</glossentry> |
39 |
<glossentry id="lowleveldescriptionsystem"> |
40 |
<glossterm>Low level description system</glossterm> |
41 |
<glossdef> |
42 |
<para>A low level description system describes the list of attributes |
43 |
used for the low level descriptions, their values but also the way to |
44 |
display them. It manages a library of documents (pictures, videos, |
45 |
texts, sounds), a library of object types with their attributes and |
46 |
provides code (rules) to manage these types and documents |
47 |
(rules).</para> |
48 |
</glossdef> |
49 |
</glossentry> |
50 |
</glosslist> |
51 |
</sect1> |
52 |
|
53 |
<sect1><title>What we need?</title> |
54 |
<para>The 0.1 version is intended for milestone M2 and should at least |
55 |
fulfill needs for this version. We try to keep things simple and voluntarily |
56 |
forgot some points. This document supersedes info about descriptions in |
57 |
Perceptions-RFC.</para> |
58 |
|
59 |
<para>Needs:</para> |
60 |
<itemizedlist> |
61 |
<listitem><para>Creatures: human, baker, parrot, ox, pig, saw, piglet, |
62 |
chicken</para></listitem> |
63 |
<listitem><para>Items: piece of bread, chalkboard, pin's, clothes, blue |
64 |
pumpkin, chicken sausage, fountain, silver coin</para></listitem> |
65 |
<listitem><para>Places: street, rural, cliff, bakery, market street, |
66 |
shops, bridge, docks, rivers, guard tower, chasm</para></listitem> |
67 |
<listitem><para>Actions: go, talk, write, read, buy, sell, |
68 |
rock/paper/scissor attack, rock/paper/scissor defense</para></listitem> |
69 |
</itemizedlist> |
70 |
|
71 |
<sect1><title>Visible light media</title> |
72 |
|
73 |
<itemizedlist> |
74 |
<listitem> |
75 |
<para>shape: id int, always defined in the description. The following tree |
76 |
is ordered by shapes, not functionalities or types.</para> |
77 |
|
78 |
<para>If the Stimuli reception is bad, you could perceive a human only as a |
79 |
biped, or misperceive a chicken and a parrot, or even a human and a pig if |
80 |
you're drunk enough. This can be implemented by associating a minimum |
81 |
perception level with each node of the tree (the root excepted). For Example |
82 |
: human 1, humanoid 0.5, biped 0, animal -1</para> |
83 |
|
84 |
<programlisting> |
85 |
unknown -- other (fountain, clothes) |
86 |
|- animal -- avian -- chicken |
87 |
| | \- parrot |
88 |
| |- biped -- humanoid -- human |
89 |
| \- quadruped -- porcine -- pig |
90 |
| \- bovine -- ox |
91 |
|- geometrical -- arch -- bridge |
92 |
| |- flat -- wall |
93 |
| |- rectangular -- chalkboard |
94 |
| |- ball -- piece of bread |
95 |
| | \- pumpkin |
96 |
| |- opening -- door |
97 |
| |- stick -- sausage |
98 |
| \- disc -- coin |
99 |
| \- pin' |
100 |
\- landscape -- path -- road |
101 |
| \- waterstream |
102 |
|- mountain -- cliff |
103 |
\- chasm |
104 |
</programlisting></listitem> |
105 |
<listitem><para>height: float (meters), always defined in the |
106 |
description</para></listitem> |
107 |
<listitem><para>colors: type byte (uniform color or texture), id int (color |
108 |
number or texture id), always defined in the description</para></listitem> |
109 |
<listitem><para id="visible-breathing">breathing: flag (if available, it's |
110 |
breathing)</para></listitem> |
111 |
<listitem><para id="visible-environment">environment: byte (possible values: |
112 |
urban and rural)</para></listitem> |
113 |
<listitem><para id="visible-activity">activity: id (see the tree below), |
114 |
actors (empty or Entities list), victims (empty or Entities list), success: |
115 |
boolean, method: byte (possibles values: expert, clumsy). Actors, victims, |
116 |
success and method are optional in the perceptions.</para> |
117 |
<programlisting> |
118 |
unknown -- to go |
119 |
|- to play Rock-Paper-Scissors -- to RPS-attack |
120 |
| \- to RPS-defense |
121 |
|- to trade -- to buy |
122 |
| \- to sell |
123 |
|- to read |
124 |
|- to write |
125 |
\- to talk |
126 |
</programlisting></listitem> |
127 |
</itemizedlist> |
128 |
<para>Actors and Victims may be sets of multiple entities. In the multiple |
129 |
Actors case, there will usually be a leading entity which gives the |
130 |
impulsion of the action. If the action has been planned in advance or |
131 |
happens in reaction to an event, no leader entity is required. Similarly, in |
132 |
the multiple victims case, some entities could be the tool with which the |
133 |
action is performed on the (strictly speaking) victims. This information is |
134 |
specified as an additional attribute associated with the entity in the |
135 |
list.</para> |
136 |
<para></para> |
137 |
<note><para>Unused ideas: weather(temperature, wind, humidity, pressure), |
138 |
position, corpulence, skin color, eyes color, hair length, hair color, ears |
139 |
shape</para></note> |
140 |
</sect1> |
141 |
|
142 |
<sect1><title>Sound media</title> |
143 |
|
144 |
<itemizedlist> |
145 |
<listitem><para>raw: dialogs between players, etc</para></listitem> |
146 |
<listitem><para>breathing: see <link linkend="visible-breathing">Visible |
147 |
light/breathing</link></para></listitem> |
148 |
<listitem><para>heartbeat: flag (if available, it's beating)</para></listitem> |
149 |
<listitem><para>environment: see <link linkend="visible-environment">Visible |
150 |
light/environment</link></para></listitem> |
151 |
<listitem><para>activity: see <link linkend="visible-activity">Visible |
152 |
light/activity</link></para> |
153 |
<example><title>'Change into rat' spell</title> |
154 |
<para>Activity: id(animal change), actors: magician, victims: magician. |
155 |
After the spell, we need a rat description.</para></example> |
156 |
<example><title>Bow shooting</title> |
157 |
<para>Activity: id(bow shooting), actors: shooter, victims: |
158 |
victim.</para></example> |
159 |
<example><title>Lift a piano</title> |
160 |
<para>Activity: id(lift), actors: furniture removers, victims: |
161 |
piano</para></example> |
162 |
<example><title>Raining</title> |
163 |
<para>Activity: id(rain), actors: the place, victims: EMPTY</para> |
164 |
</example> |
165 |
<programlisting> |
166 |
unknown -- to go |
167 |
|- to play Rock-Paper-Scissors -- to RPS-attack |
168 |
| \- to RPS-defense |
169 |
|- to trade -- to buy |
170 |
| \- to sell |
171 |
|- to read |
172 |
|- to write |
173 |
\- to talk |
174 |
</programlisting> |
175 |
</listitem> |
176 |
</itemizedlist> |
177 |
<note><para>Unused ideas: direction, distance</para></note> |
178 |
</sect1> |
179 |
|
180 |
|
181 |
<sect1><title>Objects, Places and Actions library</title> |
182 |
<para>An LLD object will contain two attributes types:</para> |
183 |
<itemizedlist> |
184 |
<listitem><para>Numerical attributes, which corresponds to measurable |
185 |
physical properties like mass, length, speed and color.</para></listitem> |
186 |
<listitem><para>Reference to object classes and enumerated types defined |
187 |
in the libraries.</para></listitem> |
188 |
</itemizedlist> |
189 |
<para> Object classes and Types will be organized in trees (or graphs). Such |
190 |
trees are in fact representation of knowledge and are called ontologies. An |
191 |
API to create and manage these ontologies trees will be provided. Ontologies |
192 |
will be loaded and saved as XML document. When a game is running, no change |
193 |
can be made on the tree.</para> |
194 |
<para>Numerical attributes defined for M2: |
195 |
<itemizedlist> |
196 |
<listitem><para>Height: unit=meter, as float.</para></listitem> |
197 |
<listitem><para>Color: unit=RGBA system (Red Green Blue Alpha), as 4 |
198 |
bytes.</para></listitem> |
199 |
</itemizedlist> |
200 |
</para> |
201 |
<para>Ontologies required for M2:</para> |
202 |
<para> |
203 |
<itemizedlist> |
204 |
<listitem><para>Physical appearances / Shapes</para></listitem> |
205 |
<listitem><para>Objects Types</para></listitem> |
206 |
<listitem><para>Creatures Families</para></listitem> |
207 |
<listitem><para>Action Families</para></listitem> |
208 |
<listitem><para>Meteorological environments</para></listitem> |
209 |
<listitem><para>Geographical environments (2 nodes: urban & |
210 |
rural)</para></listitem> |
211 |
</itemizedlist> |
212 |
</para> |
213 |
</sect1> |
214 |
|
215 |
<sect1><title>Transmission</title> |
216 |
<para>Entities have their own description, defined with low level |
217 |
description attributes, so do activities. The perception system (as |
218 |
described in Perceptions-RFC) will transmit information defined like a |
219 |
triplet (medium, intensity, attribute).</para> |
220 |
<para>Simple telnet is a special case, described in <link |
221 |
linkend="sect-display">Display</link>.</para> |
222 |
<para>For M2, data are transmitted in the following format: (beginning of |
223 |
the line) @ (medium) (intensity) (attribute name) (values or parameters) @ |
224 |
(end of line). '@' character is used as delimiter. Others transmitted lines |
225 |
are debug or administrative data (like asking for password, notifying a |
226 |
reboot in 10min, etc).</para> |
227 |
<para>Unused ideas: plain text, XML, binary, etc?</para> |
228 |
</sect1> |
229 |
|
230 |
<sect1 id="sect-display"><title>Display</title> |
231 |
<para>Each low level description attribute should always have an alternative |
232 |
text value for poor telnet clients. Moreover, the attribute value can be an |
233 |
id referring to a picture, a video, a sound, etc. If the client is unable to |
234 |
play it, it'll default to text value.</para> |
235 |
<programlisting> |
236 |
Telnet client ---- text ----[converter thread]---- triplet ----[server] |
237 |
Client protocol ---- triplet ----[server] |
238 |
</programlisting> |
239 |
<para>The converter thread is server-side. If invalid triplets are |
240 |
encountered, they should be ignored or displayed as errors, and |
241 |
logged.</para> |
242 |
<note><para>Implementation hint: The converter thread can be designed as a |
243 |
stand alone application server, which would allow to run it on a different |
244 |
host.</para></note> |
245 |
|
246 |
<para>For client protocol, it should begin with a low level description |
247 |
version test. If invalid triplets are encountered, they should be ignored or |
248 |
displayed, and eventually logged for further reports by player.</para> |
249 |
<para>'raw' attribute value is displayed directly. For others attributes, |
250 |
there should be rules for displaying.</para> |
251 |
<para>There should be a rule to convert an attribute into basic text (please |
252 |
note this rule can support i18n).</para> |
253 |
<example><title>Height</title> |
254 |
<para>(visible light, height, 1.82): converted into '1.82m tall' in English |
255 |
(please not in inches, foot and co...) and 'haut de 1,82m' in |
256 |
French</para> |
257 |
</example> |
258 |
<example><title>Colors</title> |
259 |
<para>(visible light, colors, type=texture id=scottish): 'blue, red and |
260 |
green tartan' in English</para> |
261 |
</example> |
262 |
<para>There can be several rules for a given attributes. For example, a |
263 |
human shape can be displayed as a human 3D model rotating (video), human |
264 |
2D-shape (picture), etc.</para> |
265 |
<para>The rules also used the intensity. For text display, font size can be |
266 |
used to indicate the intensity. Upper case (YOU SHOUT) or stars (you |
267 |
*shout*) can also be used. For sound, volume can be used, etc.</para> |
268 |
</sect1> |
269 |
|
270 |
<!-- Keep this comment at the end of the file |
271 |
Local variables: |
272 |
mode: sgml |
273 |
sgml-omittag:t |
274 |
sgml-shorttag:t |
275 |
sgml-namecase-general:t |
276 |
sgml-general-insert-case:lower |
277 |
sgml-minimize-attributes:nil |
278 |
sgml-always-quote-attributes:t |
279 |
sgml-indent-step:2 |
280 |
sgml-indent-data:t |
281 |
sgml-parent-document:nil |
282 |
sgml-exposed-tags:nil |
283 |
sgml-local-catalogs:nil |
284 |
sgml-local-ecat-files:nil |
285 |
End: |
286 |
--> |