[9159] Skip invisible/stealthed and not detected targets from threat list at next target selection.

This will fix work spell 58984 and similar in combat.
This commit is contained in:
VladimirMangos 2010-01-12 10:45:34 +03:00
parent 2c092b1c34
commit 83261d9b9b
2 changed files with 8 additions and 5 deletions

View file

@ -1619,6 +1619,9 @@ bool Creature::IsOutOfThreatArea(Unit* pVictim) const
if (!pVictim->isInAccessablePlaceFor(this))
return true;
if (!pVictim->isVisibleForOrDetect(this,this,false))
return true;
if(sMapStore.LookupEntry(GetMapId())->IsDungeon())
return false;

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "9158"
#define REVISION_NR "9159"
#endif // __REVISION_NR_H__