diff options
author | madmaxoft <github@xoft.cz> | 2013-08-25 16:11:19 +0200 |
---|---|---|
committer | madmaxoft <github@xoft.cz> | 2013-08-25 16:11:19 +0200 |
commit | 104a31e23d146fe69fed78932e442f4894af2a86 (patch) | |
tree | b9b2f6ffd83d1fba85361e66955673bf322d94e8 /source/Blocks/BlockDoor.cpp | |
parent | Fixed logging in cTracer. (diff) | |
parent | Fixed iron door opening by hand (diff) | |
download | cuberite-104a31e23d146fe69fed78932e442f4894af2a86.tar cuberite-104a31e23d146fe69fed78932e442f4894af2a86.tar.gz cuberite-104a31e23d146fe69fed78932e442f4894af2a86.tar.bz2 cuberite-104a31e23d146fe69fed78932e442f4894af2a86.tar.lz cuberite-104a31e23d146fe69fed78932e442f4894af2a86.tar.xz cuberite-104a31e23d146fe69fed78932e442f4894af2a86.tar.zst cuberite-104a31e23d146fe69fed78932e442f4894af2a86.zip |
Diffstat (limited to 'source/Blocks/BlockDoor.cpp')
-rw-r--r-- | source/Blocks/BlockDoor.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/Blocks/BlockDoor.cpp b/source/Blocks/BlockDoor.cpp index 267486c47..02cbd28e2 100644 --- a/source/Blocks/BlockDoor.cpp +++ b/source/Blocks/BlockDoor.cpp @@ -47,7 +47,10 @@ void cBlockDoorHandler::OnDestroyed(cWorld * a_World, int a_BlockX, int a_BlockY void cBlockDoorHandler::OnUse(cWorld * a_World, cPlayer * a_Player, int a_BlockX, int a_BlockY, int a_BlockZ, char a_BlockFace, int a_CursorX, int a_CursorY, int a_CursorZ) { - cDoors::ChangeDoor(a_World, a_BlockX, a_BlockY, a_BlockZ); + if (a_World->GetBlock(a_BlockX, a_BlockY, a_BlockZ) == E_BLOCK_WOODEN_DOOR) + { + cDoors::ChangeDoor(a_World, a_BlockX, a_BlockY, a_BlockZ); + } } |