From 27b02efffa202e7a97d85fceb017a47678f52a9e Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Sat, 8 Sep 2012 21:33:53 +0000 Subject: StringToItem() sets item's count to 1 after a successful parse git-svn-id: http://mc-server.googlecode.com/svn/trunk@854 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/BlockID.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'source') diff --git a/source/BlockID.cpp b/source/BlockID.cpp index 99f8cb1d1..654a55e63 100644 --- a/source/BlockID.cpp +++ b/source/BlockID.cpp @@ -86,6 +86,7 @@ public: { a_Item.m_ItemDamage = 0; } + a_Item.m_ItemCount = 1; return true; } @@ -107,6 +108,7 @@ public: } if (Split.size() < 2) { + a_Item.m_ItemCount = 1; return true; } a_Item.m_ItemDamage = atoi(Split[1].c_str()); @@ -115,7 +117,7 @@ public: // Parsing the number failed return false; } - + a_Item.m_ItemCount = 1; return true; } -- cgit v1.2.3