diff options
author | Tycho <work.tycho+git@gmail.com> | 2014-01-26 15:20:39 +0100 |
---|---|---|
committer | Tycho <work.tycho+git@gmail.com> | 2014-01-26 15:20:39 +0100 |
commit | 14e48ccb4bbad6f43121dc27f042083cda160f45 (patch) | |
tree | 96df772125eb96f79bf76226e5df91b4e2b99696 /src/ClientHandle.cpp | |
parent | Added support for overide in c++11 supporting varients of gcc/clang (diff) | |
download | cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.tar cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.tar.gz cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.tar.bz2 cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.tar.lz cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.tar.xz cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.tar.zst cuberite-14e48ccb4bbad6f43121dc27f042083cda160f45.zip |
Diffstat (limited to '')
-rw-r--r-- | src/ClientHandle.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/ClientHandle.cpp b/src/ClientHandle.cpp index 083dad833..fa3827d73 100644 --- a/src/ClientHandle.cpp +++ b/src/ClientHandle.cpp @@ -20,6 +20,7 @@ #include "Items/ItemHandler.h" #include "Blocks/BlockHandler.h" #include "Blocks/BlockSlab.h" +#include "Blocks/ChunkInterface.h" #include "Vector3f.h" #include "Vector3d.h" @@ -916,7 +917,9 @@ void cClientHandle::HandleRightClick(int a_BlockX, int a_BlockY, int a_BlockZ, c // A plugin doesn't agree with using the block, abort return; } - BlockHandler->OnUse(World, World, m_Player, a_BlockX, a_BlockY, a_BlockZ, a_BlockFace, a_CursorX, a_CursorY, a_CursorZ); + cChunkInterface *ChunkInterface = new cChunkInterface(World->GetChunkMap()); + BlockHandler->OnUse(ChunkInterface, World, m_Player, a_BlockX, a_BlockY, a_BlockZ, a_BlockFace, a_CursorX, a_CursorY, a_CursorZ); + delete ChunkInterface; PlgMgr->CallHookPlayerUsedBlock(*m_Player, a_BlockX, a_BlockY, a_BlockZ, a_BlockFace, a_CursorX, a_CursorY, a_CursorZ, BlockType, BlockMeta); return; } |