- Joined
- Jan 9, 2016
- Messages
- 1,487
Hey all.
I'm using kawas11's Breath of Fire spell and it seems to be working fine. However, despite being told to only damage Alive units, the spell seems to try and damage dead units as the projectiles won't go pass their corpses.
Here's the boolean that specifies it to only damage alive units:
Thanks in advance.
I'm using kawas11's Breath of Fire spell and it seems to be working fine. However, despite being told to only damage Alive units, the spell seems to try and damage dead units as the projectiles won't go pass their corpses.
Here's the boolean that specifies it to only damage alive units:
Code:
private function DamageFilter takes unit target, player owner returns boolean
return (UnitAlive(target)) and (not IsUnitType(target, UNIT_TYPE_MAGIC_IMMUNE)) and (not IsUnitType(target, UNIT_TYPE_STRUCTURE)) and (not IsUnitType(target, UNIT_TYPE_FLYING)) and (IsUnitEnemy(target, owner))
endfunction
Thanks in advance.