Difference between revisions of "Xml editing"

From 7 Days to Die Wiki
Jump to: navigation, search
(Created page with "= Introduction = In the xml files are all of the items and entitys of the game defined. How much damage they do, what you can do with them, how they are named, their behavior...")
 
Line 3: Line 3:
 
However, doing this in an uncorrect manner can result in erros, ctd or simple wrong use of items in the game. To prevent that and to give a little help to everyone trying to alter their gameplay to their wishes, this section provides some explanations to the attributes in the xml files.<br />
 
However, doing this in an uncorrect manner can result in erros, ctd or simple wrong use of items in the game. To prevent that and to give a little help to everyone trying to alter their gameplay to their wishes, this section provides some explanations to the attributes in the xml files.<br />
 
It is recommended to copy the xml and edit the copies, not the originals, in case something goes wrong. Alternatively one can usually download the latest xmls [http://7d2d.rocks/xml-defaults.php here].<br /><br />
 
It is recommended to copy the xml and edit the copies, not the originals, in case something goes wrong. Alternatively one can usually download the latest xmls [http://7d2d.rocks/xml-defaults.php here].<br /><br />
  +
  +
= xmls related to items =
  +
  +
== items.xml ==
  +
  +
Here are the properties of every item in the game defined. Damage, material, critical-strike chance and so on.<br />
  +
  +
  +
=== General ===
  +
* item id="NUMBER"
  +
The id is to differentiate each item. There is room for many items (over 4000), but normally only items up to a specific ID are shown in the creative-menu. The others are still in game though.
  +
* name=”ITEMNAME”
  +
The name of the item. If you create a custom item from scratch, this is the name that appears in game unless you also edit the localization.txt. It is not allowed to use space between two parts of a name.
  +
* property name="Group" value="GROUPNAME"
  +
Groupname can either be one of the standard-groups or you can create a custom group in groups.xml and use that. The standard groups are:<br />
  +
Basic,Ammo/Weapon, Tools/Traps, Building, Resources, Forging/Molds, Decor, Medicine, Chemicals, Food/Cooking, Clothing, Miscellaneous, Special Items
  +
* property name="Meshfile" value="FILEPATH"
  +
The look of an item in the game. The filepath is where the mesh is found inside the .dlls of the game. If you want your custom item to look like another item, just copy it from there.
  +
*property name="DropMeshfile" value="FILEPATH"
  +
The look of an item dropped on the ground.
  +
*property name="HandMeshfile" value="FILEPATH"
  +
The look of an item if held in hand. Needed if it normally would not be held in hand, such as crossbowbolts.
  +
*property name="Material" value="MATERIALNAME"
  +
Some items get a damage mulitplier against certain materials. Is also used to determine what the item is dismantled into. Which materials are possible is defined in materials.xml.
  +
*property name="HoldType" value="NUMBER"
  +
The way the item is held in hands, i.e. 36 is like a knife, 32 is like bolts. These are defined in misc.xml.
  +
*property name="Stacknumber" value="NUMBER"
  +
How much of this item can stack in one field of your belt/backpack.
  +
*property name="SoundDestroy" value="NAMEOFSOUND"
  +
In case the item is destroyed, which sound is played. There are other events like this:
  +
:Sound_start, Sound_repeat, Sound_end, SoundJammed, Sound_empty, Sound_reload, SoundIdle, Sound_warning, Sound_draw, Sound_cancel, Upgrade_action_sound, Repair_action_sound
  +
*property name="Weight" value="NUMBER"
  +
Effecting how much you get as output if you smelt it in your forge or how much you can scrape it for.
  +
*property name="Degradation" value="NUMBER" param1="true"
  +
If the item degrades with use.
  +
*property name="DegradationBreaksAfter" value="false"
  +
If the item breaks after reaching 0 durability.

Revision as of 14:40, 16 July 2015

Some items' or groups' chance to drop changes according to the player's gamestage. Here you can see those values for any gamestage you want using the little box below. Just type the gamestage you want in the box and press the Apply!-button. The values should change immediately, if the chance is different.

Current game stage: 1

Introduction[edit | edit source]

In the xml files are all of the items and entitys of the game defined. How much damage they do, what you can do with them, how they are named, their behavior etc. Editing these is pretty simple, every texteditor is capable of that (although Notepad++ is recommended as it is a freeware and very handy too use).
However, doing this in an uncorrect manner can result in erros, ctd or simple wrong use of items in the game. To prevent that and to give a little help to everyone trying to alter their gameplay to their wishes, this section provides some explanations to the attributes in the xml files.
It is recommended to copy the xml and edit the copies, not the originals, in case something goes wrong. Alternatively one can usually download the latest xmls here.

xmls related to items[edit | edit source]

items.xml[edit | edit source]

Here are the properties of every item in the game defined. Damage, material, critical-strike chance and so on.


General[edit | edit source]

  • item id="NUMBER"

The id is to differentiate each item. There is room for many items (over 4000), but normally only items up to a specific ID are shown in the creative-menu. The others are still in game though.

  • name=”ITEMNAME”

The name of the item. If you create a custom item from scratch, this is the name that appears in game unless you also edit the localization.txt. It is not allowed to use space between two parts of a name.

  • property name="Group" value="GROUPNAME"

Groupname can either be one of the standard-groups or you can create a custom group in groups.xml and use that. The standard groups are:
Basic,Ammo/Weapon, Tools/Traps, Building, Resources, Forging/Molds, Decor, Medicine, Chemicals, Food/Cooking, Clothing, Miscellaneous, Special Items

  • property name="Meshfile" value="FILEPATH"

The look of an item in the game. The filepath is where the mesh is found inside the .dlls of the game. If you want your custom item to look like another item, just copy it from there.

  • property name="DropMeshfile" value="FILEPATH"

The look of an item dropped on the ground.

  • property name="HandMeshfile" value="FILEPATH"

The look of an item if held in hand. Needed if it normally would not be held in hand, such as crossbowbolts.

  • property name="Material" value="MATERIALNAME"

Some items get a damage mulitplier against certain materials. Is also used to determine what the item is dismantled into. Which materials are possible is defined in materials.xml.

  • property name="HoldType" value="NUMBER"

The way the item is held in hands, i.e. 36 is like a knife, 32 is like bolts. These are defined in misc.xml.

  • property name="Stacknumber" value="NUMBER"

How much of this item can stack in one field of your belt/backpack.

  • property name="SoundDestroy" value="NAMEOFSOUND"

In case the item is destroyed, which sound is played. There are other events like this:

Sound_start, Sound_repeat, Sound_end, SoundJammed, Sound_empty, Sound_reload, SoundIdle, Sound_warning, Sound_draw, Sound_cancel, Upgrade_action_sound, Repair_action_sound
  • property name="Weight" value="NUMBER"

Effecting how much you get as output if you smelt it in your forge or how much you can scrape it for.

  • property name="Degradation" value="NUMBER" param1="true"

If the item degrades with use.

  • property name="DegradationBreaksAfter" value="false"

If the item breaks after reaching 0 durability.