Removed usage of Mob::DistNoRoot and used ComparativeDistance instead

This commit is contained in:
Arthur Ice 2015-01-17 15:42:58 -08:00
parent 91b2e23e56
commit 70a9a4e7cd

View File

@ -1558,7 +1558,7 @@ Client *EntityList::GetRandomClient(const xyz_location& location, float Distance
for (auto it = client_list.begin();it != client_list.end(); ++it)
if ((it->second != ExcludeClient) && (it->second->DistNoRoot(location.m_X, location.m_Y, location.m_Z) <= Distance))
if ((it->second != ExcludeClient) && (ComparativeDistance(it->second->GetPosition(), location) <= Distance))
ClientsInRange.push_back(it->second);
if (ClientsInRange.empty())