• 🏆 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!
  • 🏆 Hive's 6th HD Modeling Contest: Mechanical is now open! Design and model a mechanical creature, mechanized animal, a futuristic robotic being, or anything else your imagination can tinker with! 📅 Submissions close on June 30, 2024. Don't miss this opportunity to let your creativity shine! Enter now and show us your mechanical masterpiece! 🔗 Click here to enter!

[Trigger] Taunt->Pick Every Taunted Unit

Status
Not open for further replies.
Level 4
Joined
Dec 30, 2006
Messages
84
I am making spell based on taunt... but I got a problem (what else could it be:witch_doc_sad::witch_doc_sad:)

Now directly to the point...:

I just cant pick the right units... I suck at making conditions... I wanna pick every unit in triggering unit area of 300 that are under issued order taunt to attack triggering units...


If anyone understands that, help me out.:wink:
 
Level 12
Joined
Aug 18, 2006
Messages
1,193
if you are trying to make a thing that goes like "A unit taunts, and all affected units are, lets say, damaged" then you can just do like

Set Variable : Player = Owner of (Casting Unit)
Set Variable : UnitGroup = Units within 300 of (Casting Unit) matching ((Owner of Matching Unit) is equal to Enemy of Player
Pick every unit in Unit Group.....

i think that should work :p
 
Level 21
Joined
Jan 5, 2005
Messages
3,515
  • Actions
    • Unit Group - Pick every unit in (Units within (Real(X)) of (Position of (Triggering unit)) matching (((Owner of (Picked unit)) Not equal to (Owner of (Triggering unit))) and (((Picked unit) is A structure) Equal to False))) and do (Actions)
      • Loop - Actions
do this if you want to cast it on everything except building. if you only want to cast on certain units you would need to add the condition either within that line with crap load of "and"s, of in a "if then do multiple actions" within the loop, or you could use a variable to set the unit group as described above. i dont know which is most efficient. oh btw X is your distance variable.
 
This is kinda hard to do because Taunt does not apply any buff to the units.

But you could trigger everything xD
Base it off Thunder Clap (or other area spell that does not cause stun). Set its duration to 0, but nullify all its effects (slowing, damaging, etc). Then there could be two triggers:
  • Trigger Thunder Clap Cast
    • Events
      • Unit - A unit starts the effect of an ability
    • Conditions
      • (Ability Being Cast) equal to (Your Thunder Clap)
    • Actions
      • Unit Group - Pick every unit within RANGE of (Position of (Triggering Unit)) matching (Conditions Here) and do (actions)
        • Loop - Actions
          • Unit - Order (Picked Unit) to attack (Triggering Unit)
So the units will attack the caster. THEN we remove the buff (which is infinite because of duration 0) when they receive another order.
  • Trigger Remove Buff
    • Events
      • Unit - A unit is issued an order targeting a point
      • Unit - A unit is issued an order targeting an object
      • Unit - A unit is issued an order with no target
    • Conditions
      • (Triggering Unit) has buff (Your Thunder Clap Buff)
    • Actions
      • Unit - Remove (Your Thunder Clap Buff) from (Triggering Unit)
I haven't tested it, but I THINK it sould work =P
 
Level 4
Joined
Dec 30, 2006
Messages
84
Thx all 3 of you!!:infl_thumbs_up::infl_thumbs_up:

That works nicely I combined your ideas :thumbs_up:

Now I wanna damage that units; here begins the another issue...Now I wanna damage all that units... To deal 1/2/3 times STR into DMG and burn their mana equalto the damage done... To teal STR in Dmg is not an issue but how to damage all tha units...and burn their mana thats the problem... Because using trigger action Damage area, damages everything (including Caster and his Allies)... and to burn their mana i dont even have a clue.....
 
  • YourTrigger
    • Set TempReal = (Strength of (Casting Unit)) x (Integer(Level of YourAbility for (Casting Unit))))
    • Unit Group - Pick every unit in YourGroup and do Actions
      • Unit - Make (Casting Unit) deal TempReal damage to (Picked Unit) blahblah
      • Unit - Set (Picked Unit)'s mana to ((Mana of (Picked Unit)) - TempReal)
Hope this helps.
 
Status
Not open for further replies.
Top