Template:Durability weapon

From PZwiki
Notebook.pngTemplate Documentation

The {{Durability weapon}} template produces a pre-formatted table used to automatically calculate a weapon's chance of lowering in durability. The input is the weapon's "ConditionLowerChanceOneIn" attribute from items_weapons.txt (Project Zomboid directory/media/scripts/).

{{Durability weapon/core}} is used for all calculations.

Usage

Copy the below, and replace N with the weapon's ConditionLowerChanceOneIn attribute.
{{Durability weapon|N}}

Parameters

1 Required
The value of the ConditionLowerChanceOneIn attribute for the weapon.
weapon_skill
Should be false if the weapon has no weapon skill associated with it (defined by the Categories attribute). Otherwise, it should be omitted.

Example

Defining the first parameter will automatically calculate the chance of lowering durability based on predefined skills and the ConditionLowerChanceOneIn.

For how this is calculated, see: Durability
Maintenance skill Weapon skill Durability lower chance
0 0 1/10 (10%)
0 4 1/12 (8%)
0 8 1/14 (7%)
4 0 1/14 (7%)
8 0 1/18 (6%)
4 4 1/16 (6%)
4 8 1/18 (6%)
8 8 1/22 (5%)
10 10 1/24 (4%)


All values can be left blank, defaulting ConditionLowerChanceOneIn to 1.

For how this is calculated, see: Durability
Maintenance skill Weapon skill Durability lower chance
0 0 1/1 (100%)
0 4 1/3 (33%)
0 8 1/5 (20%)
4 0 1/5 (20%)
8 0 1/9 (11%)
4 4 1/7 (14%)
4 8 1/9 (11%)
8 8 1/13 (8%)
10 10 1/15 (7%)


weapon_skill can be set to false if the weapon has no associated weapon skill.

For how this is calculated, see: Durability
Maintenance skill Durability lower chance
0 1/1 (100%)
2 1/3 (33%)
4 1/5 (20%)
6 1/7 (14%)
8 1/9 (11%)
10 1/11 (9%)
Editors can experiment in this template's sandbox.