Bonemeal is consumed in survival mode when used on growable blocks
git-svn-id: http://mc-server.googlecode.com/svn/trunk@582 0a769ca7-a7f5-676a-18bf-c427514a06d6
This commit is contained in:
@@ -1267,6 +1267,10 @@ void cClientHandle::HandleBlockPlace(cPacket_BlockPlace * a_Packet)
|
||||
// Handle bonemeal and dyes on sheep
|
||||
if (HandleDyes(a_Packet))
|
||||
{
|
||||
if (m_Player->GetGameMode() == eGameMode_Survival)
|
||||
{
|
||||
m_Player->GetInventory().RemoveItem(Item);
|
||||
}
|
||||
return;
|
||||
}
|
||||
break;
|
||||
@@ -1582,7 +1586,7 @@ bool cClientHandle::HandleDyes(cPacket_BlockPlace * a_Packet)
|
||||
if (Equipped.m_ItemHealth == E_META_DYE_WHITE)
|
||||
{
|
||||
cWorld * World = m_Player->GetWorld();
|
||||
World->GrowPlant(a_Packet->m_PosX, a_Packet->m_PosY, a_Packet->m_PosZ);
|
||||
return World->GrowPlant(a_Packet->m_PosX, a_Packet->m_PosY, a_Packet->m_PosZ);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user