From edbc2790e31f27195835ef184a9d452bc83b2c56 Mon Sep 17 00:00:00 2001 From: "madmaxoft@gmail.com" Date: Sun, 26 May 2013 20:52:39 +0000 Subject: Fixed cItemGrid API, no more changeable GetSlot(). Also fixed possible water and lava duplication glitches in the dispenser. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1520 0a769ca7-a7f5-676a-18bf-c427514a06d6 --- source/ItemGrid.cpp | 25 ------------------------- 1 file changed, 25 deletions(-) (limited to 'source/ItemGrid.cpp') diff --git a/source/ItemGrid.cpp b/source/ItemGrid.cpp index 5a432e80f..33cae3e17 100644 --- a/source/ItemGrid.cpp +++ b/source/ItemGrid.cpp @@ -81,15 +81,6 @@ const cItem & cItemGrid::GetSlot(int a_X, int a_Y) const -cItem & cItemGrid::GetSlot(int a_X, int a_Y) -{ - return GetSlot(GetSlotNum(a_X, a_Y)); -} - - - - - const cItem & cItemGrid::GetSlot(int a_SlotNum) const { if ((a_SlotNum < 0) || (a_SlotNum >= m_NumSlots)) @@ -106,22 +97,6 @@ const cItem & cItemGrid::GetSlot(int a_SlotNum) const -cItem & cItemGrid::GetSlot(int a_SlotNum) -{ - if ((a_SlotNum < 0) || (a_SlotNum >= m_NumSlots)) - { - LOGWARNING("%s: Invalid slot number, %d out of %d slots", - __FUNCTION__, a_SlotNum, m_NumSlots - ); - return m_Slots[0]; - } - return m_Slots[a_SlotNum]; -} - - - - - void cItemGrid::SetSlot(int a_X, int a_Y, const cItem & a_Item) { SetSlot(GetSlotNum(a_X, a_Y), a_Item); -- cgit v1.2.3