Fixed bug where the floater could pop in the water while you could already get a fish.
This commit is contained in:
parent
7edad97205
commit
af98fc6170
@ -36,7 +36,7 @@ void cFloater::Tick(float a_Dt, cChunk & a_Chunk)
|
|||||||
HandlePhysics(a_Dt, a_Chunk);
|
HandlePhysics(a_Dt, a_Chunk);
|
||||||
if (IsBlockWater(m_World->GetBlock((int) GetPosX(), (int) GetPosY(), (int) GetPosZ())))
|
if (IsBlockWater(m_World->GetBlock((int) GetPosX(), (int) GetPosY(), (int) GetPosZ())))
|
||||||
{
|
{
|
||||||
if (m_World->GetTickRandomNumber(100) == 0)
|
if ((!m_CanPickupItem) && (m_World->GetTickRandomNumber(100) == 0))
|
||||||
{
|
{
|
||||||
SetPosY(GetPosY() - 1);
|
SetPosY(GetPosY() - 1);
|
||||||
m_CanPickupItem = true;
|
m_CanPickupItem = true;
|
||||||
@ -45,7 +45,7 @@ void cFloater::Tick(float a_Dt, cChunk & a_Chunk)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
SetSpeedY(1);
|
SetSpeedY(0.7);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
SetSpeedX(GetSpeedX() * 0.95);
|
SetSpeedX(GetSpeedX() * 0.95);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user