diff options
author | mtilden@gmail.com <mtilden@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2011-12-29 14:16:23 +0100 |
---|---|---|
committer | mtilden@gmail.com <mtilden@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2011-12-29 14:16:23 +0100 |
commit | c4f4ae5c7122c58af239a01328c168627ed68e27 (patch) | |
tree | a14c16b0e2b270caa465892a0d2a60adf2e3d78e /source/cChestEntity.h | |
parent | - Pickups should now burn in fire (diff) | |
download | cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.tar cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.tar.gz cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.tar.bz2 cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.tar.lz cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.tar.xz cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.tar.zst cuberite-c4f4ae5c7122c58af239a01328c168627ed68e27.zip |
Diffstat (limited to '')
-rw-r--r-- | source/cChestEntity.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/source/cChestEntity.h b/source/cChestEntity.h index 785f57553..599d71c18 100644 --- a/source/cChestEntity.h +++ b/source/cChestEntity.h @@ -3,6 +3,7 @@ #include "cBlockEntity.h"
#include "cWindowOwner.h"
#include "FileDefine.h"
+#include "packets\cPacket_BlockAction.h"
namespace Json
{
@@ -35,8 +36,17 @@ public: virtual void UsedBy( cPlayer & a_Player );
+ cChestEntity *GetJoinedChest() { return m_JoinedChest; }
+ void SetJoinedChest(cChestEntity *a_Chest) { m_JoinedChest = a_Chest; }
+ void RemoveJoinedChest(cChestEntity *a_Chest) { if (m_JoinedChest && m_JoinedChest == a_Chest) { m_JoinedChest = NULL; m_TopChest = false; } }
+
+ int GetChestHeight() { return ((m_JoinedChest) ? c_ChestHeight * 2 : c_ChestHeight); }
+ cItem *GetContents(bool a_OnlyThis = false);
+
static const int c_ChestWidth = 9;
static const int c_ChestHeight = 3;
private:
cItem* m_Content;
+ bool m_TopChest;
+ cChestEntity *m_JoinedChest;
};
\ No newline at end of file |