summaryrefslogtreecommitdiffstats
path: root/source/ChestEntity.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/ChestEntity.cpp')
-rw-r--r--source/ChestEntity.cpp19
1 files changed, 2 insertions, 17 deletions
diff --git a/source/ChestEntity.cpp b/source/ChestEntity.cpp
index e0f818de0..45c543538 100644
--- a/source/ChestEntity.cpp
+++ b/source/ChestEntity.cpp
@@ -24,8 +24,7 @@ class cRoot;
cChestEntity::cChestEntity(int a_BlockX, int a_BlockY, int a_BlockZ) :
- super(E_BLOCK_CHEST, a_BlockX, a_BlockY, a_BlockZ),
- m_Contents(c_ChestWidth, c_ChestHeight)
+ super(E_BLOCK_CHEST, a_BlockX, a_BlockY, a_BlockZ, ContentsWidth, ContentsHeight, NULL)
{
cBlockEntityWindowOwner::SetBlockEntity(this);
}
@@ -35,8 +34,7 @@ cChestEntity::cChestEntity(int a_BlockX, int a_BlockY, int a_BlockZ) :
cChestEntity::cChestEntity(int a_BlockX, int a_BlockY, int a_BlockZ, cWorld * a_World) :
- super(E_BLOCK_CHEST, a_BlockX, a_BlockY, a_BlockZ, a_World),
- m_Contents(c_ChestWidth, c_ChestHeight)
+ super(E_BLOCK_CHEST, a_BlockX, a_BlockY, a_BlockZ, ContentsWidth, ContentsHeight, a_World)
{
cBlockEntityWindowOwner::SetBlockEntity(this);
}
@@ -58,19 +56,6 @@ cChestEntity::~cChestEntity()
-void cChestEntity::Destroy(void)
-{
- // Drop items
- cItems Pickups;
- m_Contents.CopyToItems(Pickups);
- m_Contents.Clear();
- m_World->SpawnItemPickups(Pickups, m_PosX, m_PosY, m_PosZ);
-}
-
-
-
-
-
bool cChestEntity::LoadFromJson(const Json::Value & a_Value)
{
m_PosX = a_Value.get("x", 0).asInt();