summaryrefslogtreecommitdiffstats
path: root/source/blocks/Block.cpp
diff options
context:
space:
mode:
authorlapayo94@gmail.com <lapayo94@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-07-16 15:30:33 +0200
committerlapayo94@gmail.com <lapayo94@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-07-16 15:30:33 +0200
commitba70a151915bb14ddbe0527d8807508000819df6 (patch)
tree3d6d465e35067921809d3c5dc5c45d796934ad85 /source/blocks/Block.cpp
parentA new Block handling system :o (diff)
downloadcuberite-ba70a151915bb14ddbe0527d8807508000819df6.tar
cuberite-ba70a151915bb14ddbe0527d8807508000819df6.tar.gz
cuberite-ba70a151915bb14ddbe0527d8807508000819df6.tar.bz2
cuberite-ba70a151915bb14ddbe0527d8807508000819df6.tar.lz
cuberite-ba70a151915bb14ddbe0527d8807508000819df6.tar.xz
cuberite-ba70a151915bb14ddbe0527d8807508000819df6.tar.zst
cuberite-ba70a151915bb14ddbe0527d8807508000819df6.zip
Diffstat (limited to '')
-rw-r--r--source/blocks/Block.cpp15
1 files changed, 13 insertions, 2 deletions
diff --git a/source/blocks/Block.cpp b/source/blocks/Block.cpp
index 047caa989..1fd7a1af8 100644
--- a/source/blocks/Block.cpp
+++ b/source/blocks/Block.cpp
@@ -34,10 +34,10 @@
#include "BlockCactus.h"
#include "BlockStems.h"
#include "BlockGlowstone.h"
-#include "BlockRedstoneOre.h"
#include "BlockStone.h"
#include "BlockMelon.h"
#include "BlockIce.h"
+#include "BlockOre.h"
bool cBlockHandler::m_HandlerInitialized = false;
cBlockHandler *cBlockHandler::m_BlockHandler[256];
@@ -144,9 +144,15 @@ cBlockHandler *cBlockHandler::CreateBlockHandler(BLOCKTYPE a_BlockID)
return new cBlockStemsHandler(a_BlockID);
case E_BLOCK_GLOWSTONE:
return new cBlockGlowstoneHandler(a_BlockID);
+ case E_BLOCK_DIAMOND_ORE:
+ case E_BLOCK_GOLD_ORE:
case E_BLOCK_REDSTONE_ORE:
case E_BLOCK_REDSTONE_ORE_GLOWING:
- return new cBlockRedstoneOreHandler(a_BlockID);
+ case E_BLOCK_EMERALD_ORE:
+ case E_BLOCK_IRON_ORE:
+ case E_BLOCK_LAPIS_ORE:
+ case E_BLOCK_COAL_ORE:
+ return new cBlockOreHandler(a_BlockID);
case E_BLOCK_STONE:
case E_BLOCK_COBBLESTONE:
return new cBlockStoneHandler(a_BlockID);
@@ -261,6 +267,11 @@ void cBlockHandler::DropBlock(cWorld *a_World, int a_X, int a_Y, int a_Z)
}
}
+bool cBlockHandler::CanBePlacedAt(cWorld *a_World, int a_X, int a_Y, int a_Z, char a_Dir)
+{
+ return CanBeAt(a_World, a_X, a_Y, a_Z);
+}
+
bool cBlockHandler::CanBeAt(cWorld *a_World, int a_X, int a_Y, int a_Z)
{
return true;