• 🏆 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] Duel Help

Status
Not open for further replies.
Level 4
Joined
May 31, 2009
Messages
109
can someone pls teach me how to create a duel?

i tried creating one with these:
Timer
Events
Time - Elapsed game time is 0.00 seconds
Conditions
Actions
Countdown Timer - Create a timer window for (Last started timer) with title Duel Starts
Countdown Timer - Start (Last started timer) as a Repeating timer that will expire in 240.00 seconds

and...
Duel On
Events
Time - Every 240.00 seconds of game time
Conditions
Actions
Set Duel_Group = (Units in (Playable map area) matching (((Matching unit) is A Hero) Equal to True))
Unit Group - Pick every unit in (Units in (Playable map area)) and do (Actions)
Loop - Actions
Set TempPoint = (Random point in Duel Area <gen>)
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked unit) is alive) Equal to True
Then - Actions
Unit - Move (Picked unit) instantly to TempPoint
Custom script: call RemoveLocation(udg_TempPoint)
Game - Display to (All players) the text: Duel Time!!!
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked unit) is alive) Equal to False
Then - Actions
Hero - Instantly revive (Picked unit) at TempPoint, Hide revival graphics
Custom script: call RemoveLocation(udg_TempPoint)
Else - Actions
Trigger - Turn on Duel Off <gen>

and last...
Duel Off
Events
Unit - A unit Dies
Conditions
(Duel Area <gen> contains (Triggering unit)) Equal to True
Actions
Unit Group - Remove (Triggering unit) from Duel_Group
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Number of units in Duel_Group) Equal to 1
Then - Actions
Unit Group - Pick every unit in Duel_Group and do (Actions)
Loop - Actions
Game - Display to (All players) the text: ((Proper name of (Picked unit)) + has won the duel!)
Custom script: call DestroyGroup(udg_Duel_Group)
Trigger - Turn off (This trigger)
Else - Actions

but it doesnt work :cry: pls reply
 
Level 4
Joined
May 31, 2009
Messages
109
 
Status
Not open for further replies.
Top