summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Blocks/BlockOre.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/Blocks/BlockOre.h b/src/Blocks/BlockOre.h
index af67ccc4c..3bd193ee3 100644
--- a/src/Blocks/BlockOre.h
+++ b/src/Blocks/BlockOre.h
@@ -1,7 +1,8 @@
#pragma once
-#include "BlockHandler.h"
+#include "Blocks/BlockHandler.h"
+#include "Items/ItemHandler.h"
@@ -93,6 +94,11 @@ private:
return;
}
+ if (!ItemHandler(Player->GetEquippedItem().m_ItemType)->CanHarvestBlock(m_BlockType))
+ {
+ return;
+ }
+
auto & Random = GetRandomProvider();
int Reward = 0;