• 🏆 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] Tournament help please

Status
Not open for further replies.
Level 6
Joined
Apr 14, 2007
Messages
109
Im making a map that has a tournament in it and I can figure out everything but how to make the unit that entered into the tournament first and the unit that entered second be the first two to fight and the third to enter would be in the second round and so on and so forth. Can someone tell/show me how to make a GUI trigger that can do that?
 
Level 4
Joined
Feb 4, 2008
Messages
82
  • Melee Initialization
    • Events
      • Unit - A unit enters Region1 (the region which will trigger the tournament event)
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in (Region1))) Equal to 0 (Region1 = region where your players will be teleported from to the battle area)
        • Then - Actions
          • Unit - Move (Triggering unit) instantly to (Center of (Region2)) (Region2 = Battle area)
        • Else - Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Number of units in (Units in (Region2))) Equal to 2
        • Then - Actions
          • Unit - Move (Triggering unit) instantly to (Center of (Region3)) (Where Region3 is the region where the other players will wait for the other fighting players to finish
        • Else - Actions
You can also add a variable
  • Set x = (Number of units in (Units in (Region)))
so you can count the players in the region with it and then if the variable is equal to 2 (desired no. of players to fight together) then
  • Unit - Move (Triggering unit) instantly to (Center of (Region3)) (Where Region3 is the region where the other players will wait for the other fighting players to finish
    • Else - Actions
 
Level 29
Joined
Jul 29, 2007
Messages
5,174
  • Actions
    • For each (Integer A) from 1 to maximum_Number_Of_Units, do (Actions)
      • Loop - Actions
        • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
          • If - Conditions
            • Unit[(Integer A)] Equal to No unit
          • Then - Actions
            • Set Unit[(Integer A)] = (Triggering unit)
            • Skip remaining actions
          • Else - Actions
 
Status
Not open for further replies.
Top