The durability and quality systems control item wear mechanics and rarity classification. Durability determines how long items last before breaking, while quality is a full asset system that controls tooltip appearance, slot textures, text colors, and drop visual effects.
Field Type Default Description MaxDurabilityfloat— Maximum durability points DurabilityLossOnHitfloat— Durability lost per use
Weapons lose durability when hitting targets. The DurabilityLossOnHit value is subtracted from current durability on each successful hit.
"DurabilityLossOnHit" : 0.21
Calculation : Hits until broken = MaxDurability / DurabilityLossOnHit
Mithril Sword: 220 / 0.21 = ~1048 hits
Tools use a more complex durability system with per-block-type loss rates.
"DurabilityLossBlockTypes" : [
"BlockSets" : [ "Stone" , "Rock" , "Ores" , "Soil" ],
"DurabilityLossOnHit" : 0.25
Tool-specific properties:
Field Type Description DurabilityLossBlockTypesarrayPer-block-set durability loss BlockSetsarrayBlock categories that trigger this loss rate DurabilityLossOnHitfloatLoss when mining these blocks
Armor pieces have durability that decreases when taking damage.
Material MaxDurability DurabilityLossOnHit Approximate Hits Scrap 50 0.21 ~238 Crude 80 0.21 ~381 Copper 100 0.21 ~476 Iron 120 0.21 ~571 Cobalt 150 0.21 ~714 Adamantite 180 0.21 ~857 Mithril 220 0.21 ~1048
Material MaxDurability Crude 100 Copper 150 Iron 200 Steel 280 Mithril 400
Quality isn’t a hardcoded enum — it’s a full asset system. Each quality tier is a JSON asset (ItemQuality) loaded into its own AssetStore, which means modders can define entirely new quality tiers beyond the defaults. Each quality asset defines its own tooltip textures, slot textures, text color, localization, and visual behavior.
Field Type Description QualityValueintOrdering value (0 = lowest quality) ItemTooltipTexturestringTooltip background texture path ItemTooltipArrowTexturestringTooltip arrow texture path SlotTexturestringInventory slot texture BlockSlotTexturestringSlot texture for block-type items SpecialSlotTexturestringSlot texture for consumables/usables TextColorColorItem name color in inventory LocalizationKeystringLocalized quality name VisibleQualityLabelbooleanShow quality label in tooltip RenderSpecialSlotbooleanUse special slot for consumables HideFromSearchbooleanHide from creative library search ItemEntityConfigobjectDrop visual config (glow, particles)
Items reference a quality by its asset ID string (e.g. "Quality": "Common"), which gets resolved to the full ItemQuality asset at load time.
Quality Description Text Color CommonBasic items White UncommonImproved items Green RareAdvanced items Blue EpicHigh-tier items Purple LegendaryTop-tier items Gold TemplateBase templates (not for items) —
"Parent" : "Template_Weapon_Sword" ,
"Parent" : "Template_Weapon_Sword" ,
"DurabilityLossOnHit" : 0.52
Material Quality Item Level Crude Common 8 Copper Common 10 Scrap Uncommon 15 Iron Uncommon 20 Bronze Uncommon 30 Steel Uncommon 30 Cobalt Rare 35 Adamantite Rare 40 Mithril Epic 50 Onyxium Epic 30 Flame (Special) Legendary 30
Material Quality Cloth (Linen, Cotton, Wool, Silk) Common Bronze Uncommon Iron Uncommon Steel Uncommon Cobalt Rare Adamantite Rare Cindercloth Rare Mithril Epic Onyxium Epic
The ItemLevel field indicates the relative power/tier of an item. Higher levels typically correlate with better stats and higher quality.
Item Level Range Typical Quality 1-10 Common 11-25 Uncommon 26-39 Rare 40-50+ Epic/Legendary
Dropped items display visual effects based on their quality tier.
"AnimationDuration" : 1.0 ,
"EffectDirection" : "BottomUp" ,
"AnimationRange" : { "Y" : 1.0 },
"UseBloomOnHighlight" : true ,
"HighlightThickness" : 0.5 ,
"HighlightColor" : "#e0ff7d" ,
"AnimationDuration" : 1.0 ,
"EffectDirection" : "BottomUp" ,
"AnimationRange" : { "Y" : 1.0 },
"UseBloomOnHighlight" : true ,
"HighlightThickness" : 1.0 ,
"HighlightColor" : "#7db2ff" ,
"AnimationDuration" : 1.0 ,
"EffectDirection" : "BottomUp" ,
"AnimationRange" : { "Y" : 1.0 },
"UseBloomOnHighlight" : true ,
"HighlightThickness" : 5.0 ,
"HighlightColor" : "#ffdb91" ,
Quality Highlight Color Thickness Effect Common — — No glow Uncommon Green (#e0ff7d) 0.5 Subtle glow Rare Blue (#7db2ff) 1.0 Medium glow Epic Purple (#cb91ff) 2.0 Strong glow Legendary Gold (#ffdb91) 5.0 Bright glow
"Parent" : "Template_Weapon_Sword" ,
"DurabilityLossOnHit" : 0.21 ,
"Model" : "MyPlugin/Weapons/Sword_Custom.blockymodel" ,
"Texture" : "MyPlugin/Weapons/Sword_Custom_Texture.png"
"Parent" : "Tool_Pickaxe_Crude" ,
"DurabilityLossBlockTypes" : [
"BlockSets" : [ "Stone" , "Rock" , "Ores" ],
"DurabilityLossOnHit" : 0.15
"DurabilityLossOnHit" : 0.10
"DurabilityLossOnHit" : 0.35 ,
"BaseDamage" : { "Fire" : 45 },
"RandomPercentageModifier" : 0.15
Durability scales with tier - Higher-tier items last longer
Loss rate is consistent - Most weapons use 0.21 loss per hit
Special items may vary - Legendary items can have different loss rates
Tools use block-specific rates - Different blocks cause different wear
Item Type Typical DurabilityLossOnHit Swords 0.21 Maces 0.21 Daggers 0.21 Battleaxes 0.21 Bows 0.58 Pickaxes (Stone/Rock) 0.25 Pickaxes (Soil) 0.25 Axes (Wood) 0.25
Hits Until Broken = MaxDurability / DurabilityLossOnHit
Iron Sword: 120 / 0.21 = 571 hits
Mithril Sword: 220 / 0.21 = 1048 hits
Match quality to power - Higher ItemLevel items should have higher Quality
Scale durability appropriately - More powerful items should last longer
Use consistent loss rates - Follow game patterns for weapon types
Consider tool specialization - Different loss rates for different block types
Test in-game - Verify durability feels right during gameplay
Balance crafting costs - Higher durability items should cost more to craft