This is an old revision of the document!


items.xml file format

Basic format

items.xml
<?xml version="1.0"?>
<items>
    <item id="-1" type="hairsprite" name="Flat ponytail">
        <sprite>hairstyles/hairstyle01.xml</sprite>
    </item>
    <item id="-2" type="hairsprite" name="Bowl cut">
        <sprite>hairstyles/hairstyle02.xml</sprite>
    </item>
    ...
    <item id="-100" type="racesprite" name="Human">
        <sprite gender="male">player_male_base.xml</sprite>
        <sprite gender="female">player_female_base.xml</sprite>
    </item>
    ...
    <item id="501" name="Cactus Drink"
        image="use-potion-a.png|G:#22ff22"
        description="A fresh drink."
        effect="+15 HP"
        type="usable"
        hp="15"
        weight="4"
        max-per-slot="10"/>
    ...
 </items>

Here each item tag describe item/race/hair style.

Parameter Description
Id item identifier
type item type
name item name

Sub tag sprite used for add xml animation for item.

Different types will be described below.

Types

NameDescription
hairspriteAdd hair style
racespriteAdd race
otherUsed for magic weapons
usableItem what can be used
genericSome kind of item
equip-1handEquipment
equip-2handEquipment
equip-ammoEquipment
equip-armsEquipment
equip-charmEquipment
equip-feetEquipment
equip-headEquipment
equip-legsEquipment
equip-neckEquipment
equip-ringEquipment
equip-shieldEquipment
equip-torsoEquipment

Type hairsprite

This tag used to describe hair style. Example:

items.xml
<?xml version="1.0"?>
<items>
    <item id="-1" type="hairsprite" name="Flat ponytail">
        <sprite>hairstyles/hairstyle01.xml</sprite>
    </item>
    <item id="-2" type="hairsprite" name="Bowl cut">
        <sprite>hairstyles/hairstyle02.xml</sprite>
    </item>
    <item id="-3" type="hairsprite" name="Combed Back" colors="hairS">
        <sprite>hairstyles/hairstyle03.xml</sprite>
    </item>
    ...
</items>

Parameters

Parameters Description
Id item identifier
range0 > ID > -100
type hairsprite
name hair style name
colors set colors palette from itemcolors.xml file
If this attribute missing, for colors used palette with name “hair”

Type race

This tag add race.

Example:

items.xml
<?xml version="1.0"?>
<items>
    <item id="-100" type="racesprite" name="Human">
        <sprite gender="unisex">players/human-male.xml</sprite>
        <sprite gender="female">players/human-female.xml</sprite>
    </item>
    <item id="-101" type="racesprite" name="Ukar">
        <sprite gender="unisex">players/ukar-male.xml</sprite>
        <sprite gender="female">players/ukar-female.xml</sprite>
    </item>
    ...
</items>

Parameters

Parameter name Description
Id item identifier
range-100 >= ID
type racesprite
name race name

Game items

It can be all other types except hairsprite and racesprite

Example:

items.xml
<?xml version="1.0"?>
<items>
    <item id="617"
        image="equipment/head/piratehat.png"
        name="Pirate Hat"
        description="A pirate hat."
        effect="M. Attack -8"
        type="equip-head"
        weight="40"
        defense="4">
        <sprite>equipment/head/piratehat.xml</sprite>
        <replace sprite="hair">
            <item from="-5"/>
        </replace>
    </item>
    <item id="627"
        image="equipment/head/tophat.png"
        name="Top Hat"
        description="For the gentry of The Mana World."
        effect="M. Attack +2"
        type="equip-head"
        defense="10"
        weight="30">
        <sprite>equipment/head/tophat.xml</sprite>
        <replace sprite="hair">
            <item from="-5"/>
        </replace>
        <replace direction="upall" sprite="hair">
            <item from="-5" to="-5"/>
        </replace>
    </item>
    <item id="1234"
        image="image.png"
        name="item name"
        floor="floorimage.png"
        description="item description"
        view="1235"
        drawBefore="torso"
        drawAfter="boots"
        drawPriority="10"
        maxFloorOffset="32"
        tag="potions"
        tag1="potions"
        tag2="group2"
        tag3="group3"
        attack-range="3"
        missile-particle="graphics/particles/arrow.particle.xml"
        hit-effect-id="100"
        critical-hit-effect-id="101"
        effect="Damage +15"
        >
    </item>
</items>

Attributes

Parameter name Description
Iditem identifier
range 1 >= ID
attack-actionPart of attack action for weapons.
If was attack-action=“bow”, will be used attack_bow action for attack with this item
attack-rangeSet item attack range for item. By default 0
drawBeforeWill draw this equipped item before parameter value sprite. (before torso in example for item 1234).
drawAfterWill draw this equipped item after parameter value sprite. (after boots in example for item 1234).
drawPrioritySet priority for drawBefore/drawAfter
effectItem text about effect
floorfloor item static image. For animated floor item need use <floor> tag
If floor parameter missing fill be used value from image
imageitem icon image for inventory and fallback for floor items
maxFloorOffsetSet max floor item offset in pixels from default position. Default value 32
missile-particleSet particle effect for missile/arrow
hit-effect-idEffect id for hit. Default value from file paths.xml parameter hitEffectId
critical-hit-effect-idCritical effect id. Default value from file paths.xml parameter criticalHitEffectId
nameitem name
tag, tagXPut item in inventory group
viewuse animation sprite from other item with given id
weightitem weight text

Also in each item can be different nodes like <sprite> in example above.

Sprite node

Print/export
Languages