• 🏆 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!

TRIGGER - Random Hero Selection

Status
Not open for further replies.
Level 5
Joined
Aug 26, 2004
Messages
114
I'm gonna make a kind a Hero Arena and i have done picked out lots of Heroes and placed them on the map... And you can select any off them but i want to make a Random Selection so when you click on the Random Unit i have put out the Wc3 shall automaticly choose one Hero and place it on the map and give it a extra Item... How do i make that?
 
Level 9
Joined
Sep 8, 2004
Messages
633
I'll tell you step by step:

1- Make a variable, integer.
2- A trigger, when random is chosen = Set (yourvariable) is a random number between (x) and (y).
3- Then a trigger which is fired after the randomisation. containing an if/then/else for each hero, if (yourvariable) is equal to (1) then Unit - create (q)

If you don't understand this, i can make it for you. Just ask.
 
Status
Not open for further replies.
Top