• 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.

[Trigger] Trigger Fart

Status
Not open for further replies.
Level 9
Joined
Apr 6, 2008
Messages
436
I want to create an ability: Blinding Fart.
You click the button and
-a stink cloud creates around the caster _______________________________________(and this is easy)
-the casting unit plays an animation __________________________________________(and this is easy, too)
-all the enemy units within 200 of the caster get a buff called BLIND ______________(again easy)
-all blind units always miss when attacking. Like a super Curse. __________________(and I can't trigger this)
-after 12 seconds the blind units lose the buff, and everything is back to normal____(easy)
 
w8, I'll create an example.

This would do it:

  • Curse Enemie
    • Events
      • Unit - A unit Starts the effect of an ability
    • Conditions
      • (Ability being cast) Equal to Animate Dead
    • Actions
      • Set temp_point[1] = (Position of (Triggering unit))
      • Custom script: set bj_wantDestroyGroup = true
      • Unit Group - Pick every unit in (Units within 200.00 of temp_point[1] matching (((Matching unit) belongs to an enemy of (Owner of (Triggering unit))) Equal to True)) and do (Actions)
        • Loop - Actions
          • Set temp_point[2] = (Position of (Picked unit))
          • Unit - Create 1 Dummy for (Owner of (Triggering unit)) at temp_point[2] facing Default building facing degrees
          • Unit - Add a 2.00 second Generic expiration timer to (Last created unit)
          • Unit - Order (Last created unit) to Undead Banshee - Curse (Picked unit)
          • Custom script: call RemoveLocation(udg_temp_point[2])
      • Custom script: call RemoveLocation(udg_temp_point[1])
 
Level 18
Joined
Aug 23, 2008
Messages
2,319
Isn't this trigger easier?

  • Actions
    • If (((Matching unit) has buff Blind) Equal to True) then do (Unit - Cause (Matching unit) to damage (Targeted unit), dealing 0.00 damage of attack type Normal and damage type Normal) else do (Do nothing)
If the damage in this trigger can be increased by objects, items, buffs or something else, then take this trigger:

  • Actions
    • If (((Matching unit) has buff Blind) Equal to True) then do (Unit - Cause (Matching unit) to damage (Targeted unit), dealing (0.00 - 10000.00) damage of attack type Normal and damage type Normal) else do (Do nothing)
Just add the Action to the trigger you made to cause Blind to those targets, and change all "Matching Unit" parts to the parts that refer to the effected unit in your trigger.
 
Status
Not open for further replies.
Top