summaryrefslogtreecommitdiffstats
path: root/src/Mobs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Mobs/Villager.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Mobs/Villager.cpp b/src/Mobs/Villager.cpp
index b42c3ecaa..4d358e0a6 100644
--- a/src/Mobs/Villager.cpp
+++ b/src/Mobs/Villager.cpp
@@ -47,8 +47,8 @@ void cVillager::Tick(float a_Dt, cChunk & a_Chunk)
BLOCKTYPE CropBlock = m_World->GetBlock(m_CropsPos.x, m_CropsPos.y, m_CropsPos.z);
if (IsBlockFarmable(CropBlock) && m_World->GetBlockMeta(m_CropsPos.x, m_CropsPos.y, m_CropsPos.z) == 0x7)
{
- cBlockHandler Handler(CropBlock);
- Handler.DropBlock(m_World, this, m_CropsPos.x, m_CropsPos.y, m_CropsPos.z);
+ cBlockHandler * Handler = cBlockHandler::GetBlockHandler(CropBlock);
+ Handler->DropBlock(m_World, this, m_CropsPos.x, m_CropsPos.y, m_CropsPos.z);
m_World->SetBlock(m_CropsPos.x, m_CropsPos.y, m_CropsPos.z, E_BLOCK_AIR, 0);
}
}