• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

Check for Spell shield in trigger?

Status
Not open for further replies.
Level 2
Joined
Mar 10, 2010
Messages
16
I have a problem with spell shield.. I have several spells that have a triggered part that deals damage. The problem is that when the target has a spell shield item ( blocks a spell every x seconds) The spell effect gets blocked but not the triggered part of the spell. I've tried to check if the unit has the spell shield buff but that does not seem to work since the unit itself does not have the buff but rather the item.

Anyone have a suggestion?
 
Yes. You can add the unit in a Unit Group, which constantly substracts an amount from a specified Integer variable, e.g. 60 (let's say that 60 is the cooldown of you Spell Shield spell) every 1.00 seconds (Time - Every 1.00 seconds of game-time) and, when it comes to 0, remove that unit from the Unit Group. So, you will create a fake timer. If you do it that way, you can instead use that check:
  • ((Triggering unit) is in Unit_Group) Equal to True
 
Level 2
Joined
Mar 10, 2010
Messages
16
Seems like I might have to rethink my idea here since I was thinking of having several different items with spell shield and different cooldowns. Looks like a lot of work to implement that functionality :cry:
 
Status
Not open for further replies.
Top