summaryrefslogtreecommitdiffstats
path: root/example/clientdata/monsters.xml
blob: ba882cc84b8a2781e7bd636b82364a4cd2b88b1d (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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright 2009 The Mana World Development Team
monsters.xml parameters explanation:
This file is used to describe the monsters the players will see all around the world.
It can be used by both client and server, but some parameters are specific.

id [integer]:      It is the id of the monster. This parameter has to be unique for each monster.
                   The system will use the monster id to refer on it in many ways.
name [string]:     Tells the monster name. (Used to ease configuration ease on server.)
                   but displayed to players on the client side.
sprite [xml file]: Tells the xml file used to display the monster sprites. (Client only).
sound <TAG>:       This tag is used by the client to know which sound to play at what event.
  event [string]:  Tells the event at which the corresponding sound should be played. ('die', 'miss', 'hit', 'strike' are some examples.)
  <INNER>[string]: The ogg file to be played
drop <TAG>:        Tells what kind of item the monster can drop. See items.xml to get the id correspondence.
  item [integer]:  Tells the drop item Id.
  percent[float]:  Tells the chance (8.0 = 8%) to see the drop after monster's death.
attributes <TAG>:  Tells all the monsters attribute. These attribute, as for items, should not be left
                   in players hands.
  hp [integer]:    The monster hit points.
  size[integer]:   The monster maximal amplitude in pixels. Used to compute player's hit area.
  speed[float]:    The monster's speed in tiles per second.
                       (A tile is the smallest square map unit: by default, a tile is 32 pixel long.)
  attack-min[integer]: The minimal attack strength of the monster. If your hasn't got any armor,
                          there are the minimal hit points he will lose when hit by the monster.
  attack-delta[integer]:  The amplitude between minimal and maximal damages the monster can do.
  attack-magic[integer]:  The magical attacks are removing hp when hit but are computed against magical defense instead.
  mutation[integer]:      The mutation indicates the amplitude in percent where attributes get modified with.
                          For instance, with a mutation of 50, each attribute can be altered to become 100% to 149% of what they are.
vulnerability<TAG>:       Tells the monster specific vulnerability to an element.
  element[string]:        Tells to which element the weakness is. ('fire', 'earth', 'ice', 'metal' are some examples.)
  factor[float]:          Tells the defense against an element is reduced in percent. (A value of 0.7 indicates that the defense is lowered by 30%).
exp<TAG>:                 Tells how much experience point a monster is giving upon victory.
-->

<monsters>

    <monster id="1" name="Maggot" targetCursor="small">
        <sprite>monsters/monster-maggot.xml</sprite>
        <sound event="hit">monsters/maggot/maggot-hit1.ogg</sound>
        <sound event="hit">monsters/maggot/maggot-hit2.ogg</sound>
        <sound event="miss">monsters/maggot/maggot-miss1.ogg</sound>
        <sound event="die">monsters/maggot/maggot-dying1.ogg</sound>
        <drop item="1" percent="50"/>
        <drop item="2" percent="15"/>
        <drop item="3" percent="2.8"/>
        <drop item="4" percent="0.7"/>
        <attributes
            hp="20"
            size="4"
            speed="2.0"
            attack-min="10"
            attack-delta="2"
            attack-magic="0"
            hit="10"
            evade="5"
            magical-evade="5"
            physical-defence="5"
            magical-defence="0"
            mutation="50"
            />
        <vulnerability element="fire" factor="1.5"/>
        <vulnerability element="earth" factor="0.7"/>
        <exp>10</exp>
        <!-- average stroll- and track range-->
        <behavior
            aggressive="false"
            cowardly="false"
            track-range="5"
            stroll-range="32"
            attack-distance="32"
            />
        <attack id="1"
            priority="1"
            type="physical"
            pre-delay="10"
            aft-delay="5"
            damage-factor="1"
            range="32"
            animation="attack"
            script-function="strike"
            />
            <script>testmonster.lua</script> <!-- only Proof of Concept-->
    </monster>

    <monster id="2" name="Scorpion">
        <sprite>monsters/monster-scorpion.xml|#4d422d,826242,d8c282,ffffff</sprite>
        <sound event="hit">monsters/scorpion/scorpion-hit1.ogg</sound>
        <sound event="hit">monsters/scorpion/scorpion-hit2.ogg</sound>
        <sound event="hit">monsters/scorpion/scorpion-hit3.ogg</sound>
        <sound event="hit">monsters/scorpion/scorpion-hit4.ogg</sound>
        <sound event="miss">monsters/scorpion/scorpion-miss1.ogg</sound>
        <drop item="1" percent="7"/>
        <drop item="2" percent="1"/>
        <drop item="5" percent="0.5"/>
        <drop item="9" percent="7"/>
        <exp>20</exp>
        <attributes
            hp="20"
            size="8"
            speed="6.0"
            attack-min="10"
            attack-delta="2"
            attack-magic="0"
            hit="10"
            evade="10"
            magical-evade="10"
            physical-defence="5"
            magical-defence="0"
            />
        <!-- doesn't move much, but attacks when you are comming too close. -->
        <behavior
            aggressive="true"
            cowardly="false"
            track-range="2"
            stroll-range="64"
            attack-distance="64"
            />
        <!-- slow, strong, long-range tail attack-->
        <attack id="1"
            priority="1"
            type="physical"
            pre-delay="5"
            aft-delay="15"
            damage-factor="3"
            range="64"
            particle-effect="graphics/particles/attack.particle.xml"
            action="special1"
            />
        <!-- fast, weak, short-range scissor attack -->
        <attack id="2"
            priority="4"
            type="physical"
            pre-delay="3"
            aft-delay="3"
            damage-factor="1"
            range="32"
            />
    </monster>

    <monster id="3" name="Red Scorpion">
        <sprite>monsters/monster-scorpion.xml|#791d0a,cd5d27,f28d54,ffffff</sprite>
        <sound event="hit">monsters/scorpion/scorpion-hit1.ogg</sound>
        <sound event="hit">monsters/scorpion/scorpion-hit2.ogg</sound>
        <sound event="hit">monsters/scorpion/scorpion-hit3.ogg</sound>
        <sound event="hit">monsters/scorpion/scorpion-hit4.ogg</sound>
        <sound event="miss">monsters/scorpion/scorpion-miss1.ogg</sound>
        <drop item="2" percent="20"/>
        <drop item="3" percent="1"/>
        <drop item="4" percent="5"/>
        <drop item="6" percent="0.1"/>
        <drop item="9" percent="5.4"/>
        <exp>50</exp>
        <attributes
            hp="20"
            size="8"
            speed="6.0"
            attack-min="20"
            attack-delta="10"
            attack-magic="0"
            hit="30"
            evade="30"
            magical-evade="30"
            physical-defence="5"
            magical-defence="0"
            gender="female"
            />
        <!-- also quite lazy when unprovoked but much more territorial
        than the normal one-->
        <behavior
            aggressive="true"
            cowardly="false"
            track-range="6"
            stroll-range="32"
            attack-distance="64"
            />
        <attack id="1"
            priority="1"
            type="physical"
            element="fire"
            pre-delay="5"
            aft-delay="10"
            damage-factor="1"
            range="64"
            />
    </monster>

    <monster id="4" name="Green Slime">
        <sprite>monsters/monster-slime.xml|#72982c,ffffff</sprite>
        <sound event="hit">monsters/slime/slime-hit1.ogg</sound>
        <drop item="1" percent="2"/>
        <drop item="2" percent="1"/>
        <drop item="3" percent="1"/>
        <drop item="4" percent="1"/>
        <drop item="7" percent="1.9"/>
        <drop item="8" percent="0.1"/>
        <drop item="9" percent="7.5"/>
        <exp>60</exp>
        <attributes
            hp="200"
            size="4"
            speed="1.0"
            attack-min="2"
            attack-delta="10"
            attack-magic="0"
            hit="100"
            evade="10"
            magical-evade="10"
            physical-defence="0"
            magical-defence="0"
            />
        <!-- Is fulfilling some unknown purpose that requires it to move around
        a lot and leaves no time for pursing attackers -->
        <behavior
            aggressive="false"
            cowardly="false"
            track-range="4"
            stroll-range="24"
            attack-distance="32"
            />
    </monster>

</monsters>