diff options
author | andrew <xdotftw@gmail.com> | 2014-03-25 10:40:54 +0100 |
---|---|---|
committer | andrew <xdotftw@gmail.com> | 2014-03-25 10:40:54 +0100 |
commit | c8445cd93479d4729a180b21df1783449ce01b7e (patch) | |
tree | 3307357f0320f1ee42a69d7348e27584f2ab2b07 /src/Blocks | |
parent | Fixed wither summoning (diff) | |
download | cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.tar cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.tar.gz cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.tar.bz2 cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.tar.lz cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.tar.xz cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.tar.zst cuberite-c8445cd93479d4729a180b21df1783449ce01b7e.zip |
Diffstat (limited to 'src/Blocks')
-rw-r--r-- | src/Blocks/BlockMobHead.h | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/src/Blocks/BlockMobHead.h b/src/Blocks/BlockMobHead.h index 693240898..e172cee69 100644 --- a/src/Blocks/BlockMobHead.h +++ b/src/Blocks/BlockMobHead.h @@ -160,21 +160,24 @@ public: World->DoWithMobHeadAt(a_BlockX, a_BlockY, a_BlockZ, Callback); a_ChunkInterface.SetBlockMeta(a_BlockX, a_BlockY, a_BlockZ, a_BlockMeta); - static const Vector3i Coords[] = + if (a_BlockMeta == SKULL_TYPE_WITHER) { - Vector3i( 0, 0, 0), - Vector3i( 1, 0, 0), - Vector3i(-1, 0, 0), - Vector3i( 0, 0, 1), - Vector3i( 0, 0, -1), - }; - for (size_t i = 0; i < ARRAYCOUNT(Coords); ++i) - { - if (TrySpawnWither(a_ChunkInterface, World, a_BlockX + Coords[i].x, a_BlockY, a_BlockZ + Coords[i].z)) + static const Vector3i Coords[] = { - break; - } - } // for i - Coords[] + Vector3i( 0, 0, 0), + Vector3i( 1, 0, 0), + Vector3i(-1, 0, 0), + Vector3i( 0, 0, 1), + Vector3i( 0, 0, -1), + }; + for (size_t i = 0; i < ARRAYCOUNT(Coords); ++i) + { + if (TrySpawnWither(a_ChunkInterface, World, a_BlockX + Coords[i].x, a_BlockY, a_BlockZ + Coords[i].z)) + { + break; + } + } // for i - Coords[] + } } } ; |