Removed a usage of Mob::DistNoRootNoZ and used ComparativeDistanceNoZ instead

This commit is contained in:
Arthur Ice 2015-01-18 03:09:08 -08:00
parent e58a022e25
commit f33eb9f8f3

View File

@ -1584,7 +1584,7 @@ Corpse *EntityList::GetCorpseByOwnerWithinRange(Client *client, Mob *center, int
auto it = corpse_list.begin();
while (it != corpse_list.end()) {
if (it->second->IsPlayerCorpse())
if (center->DistNoRootNoZ(*it->second) < range &&
if (ComparativeDistanceNoZ(center->GetPosition(), it->second->GetPosition()) < range &&
strcasecmp(it->second->GetOwnerName(), client->GetName()) == 0)
return it->second;
++it;