mirror of
https://github.com/mangosfour/server.git
synced 2025-12-15 01:37:00 +00:00
[11105] Melee attacks distance
Inspired by patch provided by Feanordev. Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
aa4c1be8cf
commit
8e68d1bcaf
13 changed files with 77 additions and 43 deletions
|
|
@ -115,7 +115,7 @@ void GuardAI::UpdateAI(const uint32 /*diff*/)
|
|||
|
||||
if (m_creature->isAttackReady())
|
||||
{
|
||||
if (m_creature->IsWithinDistInMap(m_creature->getVictim(), ATTACK_DISTANCE))
|
||||
if (m_creature->CanReachWithMeleeAttack(m_creature->getVictim()))
|
||||
{
|
||||
m_creature->AttackerStateUpdate(m_creature->getVictim());
|
||||
m_creature->resetAttackTimer();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue