Fixed sheep
This commit is contained in:
parent
73d9a285d5
commit
ba4865f7ee
@ -68,7 +68,6 @@ void cSheep::OnRightClicked(cPlayer & a_Player)
|
|||||||
|
|
||||||
void cSheep::Tick(float a_Dt, cChunk & a_Chunk)
|
void cSheep::Tick(float a_Dt, cChunk & a_Chunk)
|
||||||
{
|
{
|
||||||
super::Tick(a_Dt, a_Chunk);
|
|
||||||
// The sheep should not move when he's eating so only handle the physics.
|
// The sheep should not move when he's eating so only handle the physics.
|
||||||
if (m_TimeToStopEating > 0)
|
if (m_TimeToStopEating > 0)
|
||||||
{
|
{
|
||||||
@ -96,7 +95,6 @@ void cSheep::Tick(float a_Dt, cChunk & a_Chunk)
|
|||||||
m_TimeToStopEating = 40;
|
m_TimeToStopEating = 40;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
cPlayer * a_Closest_Player = m_World->FindClosestPlayer(GetPosition(), (float)m_SightDistance);
|
cPlayer * a_Closest_Player = m_World->FindClosestPlayer(GetPosition(), (float)m_SightDistance);
|
||||||
if (a_Closest_Player != NULL)
|
if (a_Closest_Player != NULL)
|
||||||
{
|
{
|
||||||
@ -121,4 +119,5 @@ void cSheep::Tick(float a_Dt, cChunk & a_Chunk)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user