mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-31 00:46:46 +00:00
Throw added client los pet checks behind LoS cheat rule for bots
This commit is contained in:
+10
-6
@@ -11093,7 +11093,7 @@ void Client::Handle_OP_PetCommands(const EQApplicationPacket *app)
|
|||||||
if (!target)
|
if (!target)
|
||||||
break;
|
break;
|
||||||
|
|
||||||
if (!DoLosChecks(target)) {
|
if (CheckLosCheat(target) && !DoLosChecks(target)) {
|
||||||
mypet->SayString(this, NOT_LEGAL_TARGET);
|
mypet->SayString(this, NOT_LEGAL_TARGET);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -11107,8 +11107,10 @@ void Client::Handle_OP_PetCommands(const EQApplicationPacket *app)
|
|||||||
break; //prevent pet from attacking stuff while feared
|
break; //prevent pet from attacking stuff while feared
|
||||||
|
|
||||||
if (!mypet->IsAttackAllowed(target)) {
|
if (!mypet->IsAttackAllowed(target)) {
|
||||||
mypet->SayString(this, NOT_LEGAL_TARGET);
|
if (CheckLosCheat(target) && !DoLosChecks(target)) {
|
||||||
break;
|
mypet->SayString(this, NOT_LEGAL_TARGET);
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// default range is 200, takes Z into account
|
// default range is 200, takes Z into account
|
||||||
@@ -11161,7 +11163,7 @@ void Client::Handle_OP_PetCommands(const EQApplicationPacket *app)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!DoLosChecks(GetTarget())) {
|
if (CheckLosCheat(GetTarget()) && !DoLosChecks(GetTarget())) {
|
||||||
mypet->SayString(this, NOT_LEGAL_TARGET);
|
mypet->SayString(this, NOT_LEGAL_TARGET);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -11172,8 +11174,10 @@ void Client::Handle_OP_PetCommands(const EQApplicationPacket *app)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!mypet->IsAttackAllowed(GetTarget())) {
|
if (!mypet->IsAttackAllowed(GetTarget())) {
|
||||||
mypet->SayString(this, NOT_LEGAL_TARGET);
|
if (CheckLosCheat(GetTarget()) && !DoLosChecks(GetTarget())) {
|
||||||
break;
|
mypet->SayString(this, NOT_LEGAL_TARGET);
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((mypet->GetPetType() == petAnimation && aabonuses.PetCommands[PetCommand]) || mypet->GetPetType() != petAnimation) {
|
if ((mypet->GetPetType() == petAnimation && aabonuses.PetCommands[PetCommand]) || mypet->GetPetType() != petAnimation) {
|
||||||
|
|||||||
Reference in New Issue
Block a user