mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-12 01:11:29 +00:00
Removed a usage of Mob::DistNoRoot and used ComparativeDistance instead
This commit is contained in:
parent
d71fc61511
commit
86639f924d
@ -4003,7 +4003,7 @@ void Bot::PetAIProcess() {
|
|||||||
switch(pStandingPetOrder) {
|
switch(pStandingPetOrder) {
|
||||||
case SPO_Follow:
|
case SPO_Follow:
|
||||||
{
|
{
|
||||||
float dist = botPet->DistNoRoot(*botPet->GetTarget());
|
float dist = ComparativeDistance(botPet->GetPosition(), botPet->GetTarget()->GetPosition());
|
||||||
botPet->SetRunAnimSpeed(0);
|
botPet->SetRunAnimSpeed(0);
|
||||||
if(dist > 184) {
|
if(dist > 184) {
|
||||||
botPet->CalculateNewPosition2(botPet->GetTarget()->GetX(), botPet->GetTarget()->GetY(), botPet->GetTarget()->GetZ(), botPet->GetTarget()->GetRunspeed());
|
botPet->CalculateNewPosition2(botPet->GetTarget()->GetX(), botPet->GetTarget()->GetY(), botPet->GetTarget()->GetZ(), botPet->GetTarget()->GetRunspeed());
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user