HowToAddCreaturesStendhal: Difference between revisions
imported>MiguelAngelBlanchLardin No edit summary |
imported>MiguelAngelBlanchLardin No edit summary |
||
(No difference)
| |||
Revision as of 09:41, 2 March 2006
You can add new creatures to game in four very simple steps:
- Edit creature.xml
- Add GFX
- Edit Objects GFX
- Edit GameObjects
Edit creature.xml
This file contains all the description of the creatures in game. For example.
<creature name="deer"> <type class="animal" subclass="deer" tileid="36"/> <attributes> <atk value="5"/> <def value="5"/> <hp value="20"/> <speed value="1"/> <size value="1,2"/> </attributes> <level value="0"/> <experience value="0"/> <drops> <item value="meat" quantity="[1,4]" probability="80"/> <item value="ham" quantity="[1,2]" probability="40"/> </drops> <equips>
<slot name="rhand" item="leather_skin"/>
</equips> <ai> <profile name="animal"/> <profile name="non_ofensive"/> <profile name="coward"/> </ai> </creature>
It is important to understand how it works.
We must give a name to the creature and it is done in the creature tag. Then we specify the class and the subclass on the type tag. If you check the way sprites are structure at client you will realize that it is in a similar fashion to:
sprites/
monsters/
class/
subclass.png
The next attribute inside type tag is tileid that points to the position (starting from 1) of this monster sprite in the zelda_objects.png file.
Inside the attributes tag you can specify the attributes the entity has:
- atk
- def
- hp
- speed
- size