Removed a usage of Mob::DistNoRoot and used ComparativeDistance instead

This commit is contained in:
Arthur Ice 2015-01-17 23:48:44 -08:00
parent fccd767330
commit 864e9ba8ef

View File

@ -997,7 +997,7 @@ void Client::AI_Process()
if(owner == nullptr)
return;
float dist = DistNoRoot(*owner);
float dist = ComparativeDistance(m_Position, owner->GetPosition());
if (dist >= 100)
{
float speed = dist >= 225 ? GetRunspeed() : GetWalkspeed();
@ -1492,7 +1492,7 @@ void Mob::AI_Process() {
//if(owner->IsClient())
// printf("Pet start pos: (%f, %f, %f)\n", GetX(), GetY(), GetZ());
float dist = DistNoRoot(*owner);
float dist = ComparativeDistance(m_Position, owner->GetPosition());
if (dist >= 400)
{
float speed = GetWalkspeed();