Skip to content

Commit

Permalink
[11143] Spells with unit-type and destination flag should not be LOS-…
Browse files Browse the repository at this point in the history
…dependant

Signed-off-by: Ambal <pogrebniak@gala.net>
  • Loading branch information
Feanordev authored and Ambal committed Feb 12, 2011
1 parent a88ea66 commit 2e57df9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/game/Spell.cpp
Expand Up @@ -6576,7 +6576,9 @@ bool Spell::CheckTarget( Unit* target, SpellEffectIndex eff )
// Get GO cast coordinates if original caster -> GO
if (target != m_caster)
if (WorldObject *caster = GetCastingObject())
if (!target->IsWithinLOSInMap(caster))
if (m_targets.m_targetMask != (TARGET_FLAG_UNIT | TARGET_FLAG_DEST_LOCATION) &&
m_spellInfo->EffectImplicitTargetB[eff] != TARGET_ALL_ENEMY_IN_AREA_INSTANT &&
!target->IsWithinLOSInMap(caster))
return false;
break;
}
Expand Down
2 changes: 1 addition & 1 deletion src/shared/revision_nr.h
@@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "11142"
#define REVISION_NR "11143"
#endif // __REVISION_NR_H__

0 comments on commit 2e57df9

Please sign in to comment.