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/BlockCarpet.h | |
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/BlockCarpet.h')
-rw-r--r-- | source/Blocks/BlockCarpet.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/source/Blocks/BlockCarpet.h b/source/Blocks/BlockCarpet.h index f70ff45b6..5eafd8c21 100644 --- a/source/Blocks/BlockCarpet.h +++ b/source/Blocks/BlockCarpet.h @@ -8,6 +8,8 @@ #pragma once +#include "BlockHandler.h" + @@ -16,7 +18,11 @@ class cBlockCarpetHandler : public cBlockHandler { public: - cBlockCarpetHandler(BLOCKTYPE a_BlockType); + cBlockCarpetHandler(BLOCKTYPE a_BlockType) : + cBlockHandler(a_BlockType) + { + } + virtual const char * GetStepSound(void) override { @@ -39,13 +45,13 @@ public: virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta) override { - a_Pickups.push_back(cItem(E_BLOCK_CARPET, a_BlockMeta)); + a_Pickups.push_back(cItem(E_BLOCK_CARPET, 1, a_BlockMeta)); } virtual bool CanBeAt(int a_RelX, int a_RelY, int a_RelZ, const cChunk & a_Chunk) override { - return ((a_RelY > 0) && (a_Chunk.GetBlock(a_RelX, a_RelY - 1, a_RelZ) != E_BLOCK_AIR)); + return (a_RelY > 0) && (a_Chunk.GetBlock(a_RelX, a_RelY - 1, a_RelZ) != E_BLOCK_AIR); } } ; |