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

Status
Not open for further replies.
Level 19
Joined
Aug 31, 2008
Messages
1,780
Can anyone make me a trigger (put it in a demo map) where when a unit cast an ability... sunken ruins trees will be summoned everywhere in the map, healing the allies of unit (who casts the spell) if you can.. please also make the sunken ruins tree use the birth animation when being summoned throughout the map..

thank you +rep to the one who can help

please try your best in lessening the variables and object datas, for easy copying (i'm not really good at copying spells)
 
Level 8
Joined
Mar 12, 2008
Messages
437
  • Events
    • Unit - A unit starts the effects of an ability
  • Conditions
    • (Ability being cast) Equal to [Ability]
  • Actions
    • For each (Integer A) from 1 to [Integer], do (Actions)
      • Loop - Actions
        • Set Point = (Random point in (Playable map area))
        • Destructible - Create a Ruins Tree Wall at Point facing (Random angle) with scale 1.00 and variation 0
        • Custom script: call RemoveLocation (udg_Point)
    • Custom script: set bj_wantDestroyGroup = true
    • Pick every unit in (Units in (Playable map area) matching ((Owner of (Matching unit)) is an ally of (Owner of (Triggering unit)) Equal to True)) and do (Actions)
      • Unit - Set Life of (Picked unit) to ((Life of (Picked unit)) + [Real])
[Real] is the number with which you want the allies to be healed.
[Integer] is the number of trees you want to appear.
[Ability] is the ability being cast.
Point is a point variable.
 
Last edited:
Level 16
Joined
May 1, 2008
Messages
1,605
Seas =)

As I see he only use 1 variable:
Name: Point / Type: Point / Array: NO!

And by the way you want an animation you should add after you create a tree:
  • Animation - Play (Last created destructible)'s birth animation
  • For each (Integer A) from 1 to 200, do (Actions)
    • Loop - Actions
      • Set Point = (Random point in (Playable map area))
      • Destructible - Create a Summer Tree Wall at Point facing (Random angle) with scale 1.00 and variation 0
      • Animation - Play (Last created destructible)'s birth animation // <--- Here
      • Custom script: call RemoveLocation(udg_Point)
 
Level 8
Joined
Mar 12, 2008
Messages
437
I think that he might mean functions (for example "Position of unit") and not variables, is that correct?

Conditions:
Ability comparison

Actions:
For loop Integer A
Set variable
Destructible - Create
Custom script
Random point in region
Unit Group - Pick every unit in unit group and do actions
Units in region matching condition
Unit - Set Life (to value or to percentage, whichever you want)
Unit - Property
Arithmetic (Used for simple math, eg "(Life of (Picked unit)) + 1300")

I think that's all of them.
 
Last edited:
Status
Not open for further replies.
Top