mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-25 22:56:24 +00:00
feat(Core/Anticheat): Preparation to implement new passive anticheat … (#5516)
This commit is contained in:
@@ -2382,6 +2382,11 @@ void AuraEffect::HandleFeignDeath(AuraApplication const* aurApp, uint8 mode, boo
|
||||
if (target->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
|
||||
if (apply)
|
||||
{
|
||||
/*
|
||||
@@ -2874,6 +2879,11 @@ void AuraEffect::HandleAuraWaterWalk(AuraApplication const* aurApp, uint8 mode,
|
||||
|
||||
Unit* target = aurApp->GetTarget();
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
|
||||
if (!apply)
|
||||
{
|
||||
// do not remove unit flag if there are more than this auraEffect of that kind on unit on unit
|
||||
@@ -2891,6 +2901,11 @@ void AuraEffect::HandleAuraFeatherFall(AuraApplication const* aurApp, uint8 mode
|
||||
|
||||
Unit* target = aurApp->GetTarget();
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
|
||||
if (!apply)
|
||||
{
|
||||
// do not remove unit flag if there are more than this auraEffect of that kind on unit on unit
|
||||
@@ -2912,6 +2927,11 @@ void AuraEffect::HandleAuraHover(AuraApplication const* aurApp, uint8 mode, bool
|
||||
|
||||
Unit* target = aurApp->GetTarget();
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
|
||||
if (!apply)
|
||||
{
|
||||
// do not remove unit flag if there are more than this auraEffect of that kind on unit on unit
|
||||
@@ -3226,6 +3246,11 @@ void AuraEffect::HandleAuraModIncreaseSpeed(AuraApplication const* aurApp, uint8
|
||||
Unit* target = aurApp->GetTarget();
|
||||
|
||||
target->UpdateSpeed(MOVE_RUN, true);
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
}
|
||||
|
||||
void AuraEffect::HandleAuraModIncreaseMountedSpeed(AuraApplication const* aurApp, uint8 mode, bool apply) const
|
||||
@@ -3266,6 +3291,11 @@ void AuraEffect::HandleAuraModIncreaseFlightSpeed(AuraApplication const* aurApp,
|
||||
target->SetUInt32Value(UNIT_FIELD_MOUNTDISPLAYID, 16314);
|
||||
}
|
||||
}
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
}
|
||||
|
||||
void AuraEffect::HandleAuraModIncreaseSwimSpeed(AuraApplication const* aurApp, uint8 mode, bool /*apply*/) const
|
||||
@@ -3276,6 +3306,11 @@ void AuraEffect::HandleAuraModIncreaseSwimSpeed(AuraApplication const* aurApp, u
|
||||
Unit* target = aurApp->GetTarget();
|
||||
|
||||
target->UpdateSpeed(MOVE_SWIM, true);
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
}
|
||||
|
||||
void AuraEffect::HandleAuraModDecreaseSpeed(AuraApplication const* aurApp, uint8 mode, bool /*apply*/) const
|
||||
@@ -3291,6 +3326,11 @@ void AuraEffect::HandleAuraModDecreaseSpeed(AuraApplication const* aurApp, uint8
|
||||
target->UpdateSpeed(MOVE_RUN_BACK, true);
|
||||
target->UpdateSpeed(MOVE_SWIM_BACK, true);
|
||||
target->UpdateSpeed(MOVE_FLIGHT_BACK, true);
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
}
|
||||
|
||||
void AuraEffect::HandleAuraModUseNormalSpeed(AuraApplication const* aurApp, uint8 mode, bool /*apply*/) const
|
||||
@@ -3303,6 +3343,11 @@ void AuraEffect::HandleAuraModUseNormalSpeed(AuraApplication const* aurApp, uint
|
||||
target->UpdateSpeed(MOVE_RUN, true);
|
||||
target->UpdateSpeed(MOVE_SWIM, true);
|
||||
target->UpdateSpeed(MOVE_FLIGHT, true);
|
||||
|
||||
if (Player* targetPlayer = target->ToPlayer())
|
||||
{
|
||||
sScriptMgr->AnticheatSetUnderACKmount(targetPlayer);
|
||||
}
|
||||
}
|
||||
|
||||
/*********************************************************/
|
||||
|
||||
Reference in New Issue
Block a user