summaryrefslogtreecommitdiffstats
path: root/src/Blocks/BlockLever.h
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2015-06-30 16:50:15 +0200
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2015-07-14 22:46:30 +0200
commit8656e149c8820272a882406912790f0075ed5f28 (patch)
treeb4f89f69dfb026f76862046637fd99162a49d3c9 /src/Blocks/BlockLever.h
parentMerge pull request #2352 from mmdk95/master (diff)
downloadcuberite-8656e149c8820272a882406912790f0075ed5f28.tar
cuberite-8656e149c8820272a882406912790f0075ed5f28.tar.gz
cuberite-8656e149c8820272a882406912790f0075ed5f28.tar.bz2
cuberite-8656e149c8820272a882406912790f0075ed5f28.tar.lz
cuberite-8656e149c8820272a882406912790f0075ed5f28.tar.xz
cuberite-8656e149c8820272a882406912790f0075ed5f28.tar.zst
cuberite-8656e149c8820272a882406912790f0075ed5f28.zip
Diffstat (limited to 'src/Blocks/BlockLever.h')
-rw-r--r--src/Blocks/BlockLever.h14
1 files changed, 6 insertions, 8 deletions
diff --git a/src/Blocks/BlockLever.h b/src/Blocks/BlockLever.h
index 8d676b56f..840a61e60 100644
--- a/src/Blocks/BlockLever.h
+++ b/src/Blocks/BlockLever.h
@@ -27,20 +27,17 @@ public:
a_WorldInterface.GetBroadcastManager().BroadcastSoundEffect("random.click", (double)a_BlockX, (double)a_BlockY, (double)a_BlockZ, 0.5f, (Meta & 0x08) ? 0.6f : 0.5f);
}
-
virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta) override
{
// Reset meta to 0
a_Pickups.push_back(cItem(E_BLOCK_LEVER, 1, 0));
}
-
virtual bool IsUseable(void) override
{
return true;
}
-
virtual bool GetPlacementBlockTypeMeta(
cChunkInterface & a_ChunkInterface, cPlayer * a_Player,
int a_BlockX, int a_BlockY, int a_BlockZ, eBlockFace a_BlockFace,
@@ -53,7 +50,6 @@ public:
return true;
}
-
inline static NIBBLETYPE LeverDirectionToMetaData(eBlockFace a_Dir)
{
// Determine lever direction:
@@ -73,7 +69,6 @@ public:
#endif
}
-
inline static eBlockFace BlockMetaDataToBlockFace(NIBBLETYPE a_Meta)
{
switch (a_Meta & 0x7)
@@ -94,7 +89,6 @@ public:
}
}
-
virtual bool CanBeAt(cChunkInterface & a_ChunkInterface, int a_RelX, int a_RelY, int a_RelZ, const cChunk & a_Chunk) override
{
NIBBLETYPE Meta = a_Chunk.GetMeta(a_RelX, a_RelY, a_RelZ);
@@ -128,7 +122,6 @@ public:
return false;
}
-
virtual NIBBLETYPE MetaRotateCCW(NIBBLETYPE a_Meta) override
{
switch (a_Meta)
@@ -143,7 +136,6 @@ public:
}
}
-
virtual NIBBLETYPE MetaRotateCW(NIBBLETYPE a_Meta) override
{
switch (a_Meta)
@@ -157,6 +149,12 @@ public:
default: return super::MetaRotateCW(a_Meta); // Wall Rotation
}
}
+
+ virtual ColourID GetMapBaseColourID(NIBBLETYPE a_Meta) override
+ {
+ UNUSED(a_Meta);
+ return 0;
+ }
} ;