From 561296f2699bcfff93d22b8a67182308998cfb31 Mon Sep 17 00:00:00 2001 From: Samuel Barney Date: Mon, 13 Jul 2015 18:15:37 -0600 Subject: Leather Armor can now be dyed. * Created new color class to handle dye-related coloring --- src/Item.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/Item.h') diff --git a/src/Item.h b/src/Item.h index 056b5eb8a..8f47c4177 100644 --- a/src/Item.h +++ b/src/Item.h @@ -12,6 +12,7 @@ #include "Defines.h" #include "Enchantments.h" #include "WorldStorage/FireworksSerializer.h" +#include "Color.h" @@ -19,6 +20,7 @@ // fwd: class cItemHandler; +class cColor; namespace Json { @@ -41,7 +43,8 @@ public: m_CustomName(""), m_Lore(""), m_RepairCost(0), - m_FireworkItem() + m_FireworkItem(), + m_ItemColor() { } @@ -62,7 +65,8 @@ public: m_CustomName (a_CustomName), m_Lore (a_Lore), m_RepairCost (0), - m_FireworkItem() + m_FireworkItem(), + m_ItemColor() { if (!IsValidItem(m_ItemType)) { @@ -105,6 +109,7 @@ public: m_Lore = ""; m_RepairCost = 0; m_FireworkItem.EmptyData(); + m_ItemColor.Clear(); } @@ -114,6 +119,7 @@ public: m_ItemCount = 0; m_ItemDamage = 0; m_RepairCost = 0; + m_ItemColor.Clear(); } @@ -206,6 +212,7 @@ public: int m_RepairCost; cFireworkItem m_FireworkItem; + cColor m_ItemColor; }; // tolua_end -- cgit v1.2.3