• Check out the results of the Techtree Contest #19!
  • 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.
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 22nd Icon Contest: Creep Abilities is now concluded, time to vote for your favourite set of icons! Click here to vote!

[Trigger] Removing a buff from a spell-hit unit

Status
Not open for further replies.
It seems i can't find this anywere so i'm posting.
I'd like to remove a buff from an unit hit by(example) a slow spell. How's the GUI sequence? Thanks in advance.

There is, in fact, a trigger called "Unit - Remove Specific Buff." Use that for whatever unit you want to remove the buff from.

In fact, there's at least 3 different "Unit - Remove buffs" functions in GUI. They're not hidden anywhere... just scroll down the list of Unit Actions.

  • Unit - Remove (category) buffs from (Unit)
  • Unit - Remove (category) buffs considered (Magical and/or Physical) from (Unit) (Include/Exclude expiration timers, Include/Exclude auras)
  • Unit - Remove (specific buff type) buff from (Unit)
:thumbs_up:
 
I know that, i already used that type of action. The problem is that i may be wrong at event or conditions. Can you explain me which event/condition to use?

Well, if you want to have a unit *hit by an ability* have a buff removed, it would be...

  • RemoveBuff
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to (Your Spell)
    • Actions
      • Unit - Remove (Your Specifc Buff) from (Event Response - Target Unit of Ability Being Cast)
 
The game won't remember "target unit of ability being cast" if you use wait.

Here's how to do it:

  • immunity
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Slow
      • (Unit-type of (Target unit of ability being cast)) Equal to Footman
    • Actions
      • Custom script: local unit u = GetSpellTargetUnit()
      • Wait 1.00 seconds
      • Custom script: call UnitRemoveBuffBJ( 'Bslo', u )
 

Attachments

Status
Not open for further replies.
Back
Top