summaryrefslogtreecommitdiffstats
path: root/sigmodr/doc/validation.docbook
blob: 40a4c0649cc84e9c84c125b5ec35ad9bffa6041a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<chapter id="validation">

<chapterinfo>

<authorgroup>
<author>
&Ben.Boeckel;
&Ben.Boeckel.mail;
</author>
<!-- TRANS:ROLES_OF_TRANSLATORS -->
</authorgroup>

<date>2009-08-08</date>

</chapterinfo>

<title>Validation</title>

<para>When editing &sigmod;s, errors and other possible sources of complications
can occur. Validation can help to catch these errors and mistakes before they
cause problems in the game engine.</para>

<para>The validator will set the background color of the message depending on
whether it is a warning or an error. There will also be a count of the number of
warnings and errors on the validation dialog. Here  is a sample of validation
output:

<screenshot id="screen-validation">
<screeninfo>Validation dialog</screeninfo>
<mediaobject>
<imageobject>
<imagedata fileref="validation-dialog.png" format="PNG" />
</imageobject>
<textobject>
<phrase>Sample validation dialog</phrase>
</textobject>
</mediaobject>
</screenshot>

The errors will stop the &sigmod; from being run by the game engine while
warnings will not. However, warnings should be considered before being ignored;
they are there to warn when values or objects are not typical.</para>

<para>The most common sources of errors are deleting objects that are referenced
leaving the reference open. However, if a new item is created  with the same id
number after a reference is broken, the new object will  be picked up as the
reference and no errors will be given.</para>

<para>With this occurring, it is best to validate the entire &sigmod; after
deleting an object. This will help to catch any dangling references created by
deleting the object. It also means that in order to catch the errors more
easily, keeping errors low from the beginning is key. By building &sigmod;s from
the bottom up, these errors can be kept to a minimum. See the Chapter on
<!-- TODO: Uncomment when link works
<link linkend="building-sigmods">building &sigmod;s</link> for tips and
 -->
building &sigmod;s for tips and
tricks.</para>

</chapter>