mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-16 18:52:22 +00:00
[Bug Fix] Limit Player Taunt Distance (#4019)
* [Bug Fix] Player Taunt Distance Previously this was not regulated on the server side and allowed players to exploit situations where the client did not enforce Z distance checks. Rule Name: MaximumTauntDistance Rule Default: 150 Calculation is Rule Squared * remove `this`
This commit is contained in:
@@ -14905,6 +14905,11 @@ void Client::Handle_OP_Taunt(const EQApplicationPacket *app)
|
||||
return;
|
||||
}
|
||||
|
||||
if (DistanceSquared(GetPosition(), GetTarget()->GetPosition()) > (RuleI(Skills, MaximumTauntDistance) * (RuleI(Skills, MaximumTauntDistance)))) {
|
||||
MessageString(Chat::TooFarAway, TAUNT_TOO_FAR);
|
||||
return;
|
||||
}
|
||||
|
||||
Taunt(GetTarget()->CastToNPC(), false);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user