diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-06-17 21:58:39 +0200 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-06-17 21:58:39 +0200 |
commit | e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d (patch) | |
tree | d13286487b7d74dc3c56cf3c529909e31f00b8ff /source/cChunk.h | |
parent | Logs completion of chunk saving (FS #215) (diff) | |
download | cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.tar cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.tar.gz cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.tar.bz2 cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.tar.lz cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.tar.xz cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.tar.zst cuberite-e5fdc133bc6e03c4e8e1f1707ff13f4c836d2b8d.zip |
Diffstat (limited to '')
-rw-r--r-- | source/cChunk.h | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/source/cChunk.h b/source/cChunk.h index 9ecbe89b8..5aff98962 100644 --- a/source/cChunk.h +++ b/source/cChunk.h @@ -38,9 +38,13 @@ class cServer; class MTRand; class cPlayer; class cChunkMap; +class cChestEntity; +class cFurnaceEntity; typedef std::list<cClientHandle *> cClientHandleList; -typedef cItemCallback<cEntity> cEntityCallback; +typedef cItemCallback<cEntity> cEntityCallback; +typedef cItemCallback<cChestEntity> cChestCallback; +typedef cItemCallback<cFurnaceEntity> cFurnaceCallback; @@ -146,6 +150,21 @@ public: /// Calls the callback for each entity; returns true if all entities processed, false if the callback aborted by returning true bool ForEachEntity(cEntityCallback & a_Callback); // Lua-accessible + /// Calls the callback for each chest; returns true if all chests processed, false if the callback aborted by returning true + bool ForEachChest(cChestCallback & a_Callback); // Lua-accessible + + /// Calls the callback for each furnace; returns true if all furnaces processed, false if the callback aborted by returning true + bool ForEachFurnace(cFurnaceCallback & a_Callback); // Lua-accessible + + /// Calls the callback for the chest at the specified coords; returns false if there's no chest at those coords, true if found + bool DoWithChestAt(int a_BlockX, int a_BlockY, int a_BlockZ, cChestCallback & a_Callback); // Lua-acessible + + /// Calls the callback for the furnace at the specified coords; returns false if there's no furnace at those coords, true if found + bool DoWithFurnaceAt(int a_BlockX, int a_BlockY, int a_BlockZ, cFurnaceCallback & a_Callback); // Lua-accessible + + /// Retrieves the test on the sign at the specified coords; returns false if there's no sign at those coords, true if found + bool GetSignLines (int a_BlockX, int a_BlockY, int a_BlockZ, AString & a_Line1, AString & a_Line2, AString & a_Line3, AString & a_Line4); // Lua-accessible + void UseBlockEntity(cPlayer * a_Player, int a_X, int a_Y, int a_Z); // [x, y, z] in world block coords void CalculateLighting(); // Recalculate right now |