• 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 faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 21st Texturing Contest: Upgrade is now concluded, time to vote for your favourite set of icons! Click here to vote!

Detect when casting frost, flamme or dark arrow

Status
Not open for further replies.
Level 30
Joined
Feb 18, 2014
Messages
3,635
Auto-cast spells like searing arrows, frost arrows or black arrows don't count as normal spells but rather as an issued order/damage event. You will need two triggers to detect them, one that detects when a unit is issued to cast the spell and the other that detects when the target is attacked.
Here's an example on how to detect searing arrows/black arrows :
  • Searing Arrows Initial
    • Events
      • Unit - A unit Is issued an order with no target
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Issued order) Equal to (Order(flamingarrows))
        • Then - Actions
          • Trigger - Turn on Searing Arrows Detection <gen>
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Issued order) Equal to (Order(unflamingarrows))
        • Then - Actions
          • Trigger - Turn off Searing Arrows Detection <gen>
        • Else - Actions
  • Searing Arrows Detection
    • Events
      • Unit - A unit Is attacked
    • Conditions
    • Actions
      • Game - Display to (All players) the text: Searing Arrow Detected !
Frost arrows is tricky because it doesn't have an order ID which means you cannot detect it using the method above. However, you can use the event A unit is attacked and check if this latter has a buff caused by Frost arrows using the boolean condition : (Triggering unit) has buff X )

Edit : I just made some testing and I found out that Frost arrows does actually has an order ID :p

Frost Arrows On : coldarrows
Frost Arrows Off : uncoldarrows
 
Last edited:
Status
Not open for further replies.
Top