• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Help with a taunt ability

Status
Not open for further replies.
Level 2
Joined
Mar 1, 2005
Messages
6
I trying to make a taunt ability but somehow it did not work. Below is two trigger I do.

Hatred Taunt
Events
Unit - A unit Starts the effect of an ability
Conditions
(Ability being cast) Equal to Hatred
(Unit-type of (Casting unit)) Equal to Magtheridon
Actions
Set caster = (Casting unit)
Trigger - Turn on Hatred pull <gen>
Wait 4.00 seconds
Trigger - Turn off Hatred pull <gen>

Hatred pull
Events
Time - Every 0.25 seconds of game time
Conditions
(Unit-type of (Casting unit)) Equal to Magtheridon
Actions
Unit Group - Pick every unit in (Units within 300.00 of (Position of caster) matching ((((Matching unit) is A structure) Equal to False) and ((((Matching unit) belongs to an ally of (Owner of Caster)) Equal to False) and (((Matching unit) has buff Hatred ) Equal to True)))) and do (Actions)
Loop - Actions
Set caster = (Casting unit)
Unit - Order (Picked unit) to Attack Caster

Could anyone help me as the unit with the Hatred buff don't seems to attack my hero, and somehow if i use the hero <GEN>viarable it works.
 
Level 10
Joined
Apr 9, 2004
Messages
502
Your periodic event is what's messed up. Take out who the casting unit is and just make the units attack yuor hero directly. Instead of setting casting unit to your hero, set your hero as a global variable and just keep that varaible (like at instalation or whenever he's defined, set him = HeroVariable. That way you just have to amke referance to him that way.)

I have something similar to this. Keep the rest (such as checking for buff etc.) and it should work. Your conditions might also be wrong on the actual tirgger...dunno.
 
Status
Not open for further replies.
Top