Condition: Unit has Spell Immunity or Invulnerable

Status
Not open for further replies.
Hello guys, is it possible to make a condition if Unit has Spell Immunity?
  • ((Triggering unit) is Magic Immune) Equal to True
Boolean condition, it's the same as "is a Structure", but you have to change it to Magic Immune.
is it possible to make a condition if is Invulnerable?
I don't think there is one condition to do so. However you can check for abilities (Invulnerable, ...), buffs (Invulnerable, Divine Shield, ...).
You could also use a dummy unit and try if you can order it to cast a spell on a unit. The spell can target everything but vulnerable units (use Channel as base ability). Using JASS the function returns whether the order was succesful.
This would also consider transported units as invulnerable, because they cannot be targeted.
 
Status
Not open for further replies.
Back
Top