- Joined
- Nov 9, 2006
- Messages
- 25
Will someone explain to me why my trigger for 1v1 dueling isn't working?
Creates a dialog box with the names of all the other players & their heroes, and deletes the triggering player and his his hero from the list.
This trigger works, although i do have a question. How can i lock it so that Player 1 = red, player 2 = blue (like dota, which i know everyone will hate me for using in an analogy).
Any help is extremely appreciated, and will be rewarded accordingly
.
Creates a dialog box with the names of all the other players & their heroes, and deletes the triggering player and his his hero from the list.
This trigger works, although i do have a question. How can i lock it so that Player 1 = red, player 2 = blue (like dota, which i know everyone will hate me for using in an analogy).
-
Initiate
-

Events
-


Player - Player 1 (Red) types a chat message containing -Duel as An exact match
-


Player - Player 2 (Blue) types a chat message containing -Duel as An exact match
-


Player - Player 3 (Teal) types a chat message containing -Duel as An exact match
-


Player - Player 4 (Purple) types a chat message containing -Duel as An exact match
-


Player - Player 5 (Yellow) types a chat message containing -Duel as An exact match
-


Player - Player 6 (Orange) types a chat message containing -Duel as An exact match
-


Player - Player 8 (Pink) types a chat message containing -Duel as An exact match
-


Player - Player 7 (Green) types a chat message containing -Duel as An exact match
-


Player - Player 9 (Gray) types a chat message containing -Duel as An exact match
-


Player - Player 10 (Light Blue) types a chat message containing -Duel as An exact match
-


Player - Player 11 (Dark Green) types a chat message containing -Duel as An exact match
-


Player - Player 12 (Brown) types a chat message containing -Duel as An exact match
-
-

Conditions
-

Actions
-


Dialog - Show DuelDialog[(Player number of (Triggering player))] for (Triggering player)
-


Dialog - Change the title of DuelDialog[(Player number of (Triggering player))] to Who do you wish to ...
-


For each (Integer A) from 1 to 12, do (Actions)
-



Loop - Actions
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






(Integer A) Not equal to (Player number of (Triggering player))
-
-





Then - Actions
-






Dialog - Create a dialog button for DuelDialog[(Player number of (Triggering player))] labelled ((Proper name of Hero[(Integer A)]) + (( + (PlayerNames[(Player number of (Player((Integer A))))] + ))))
-






Set DialogButton[(Integer A)] = (Last created dialog Button)
-
-





Else - Actions
-
-
-
-


Dialog - Show DuelDialog[(Player number of (Triggering player))] for (Triggering player)
-
-
-
Red clicks button
-

Events
-


Dialog - A dialog button is clicked for DuelDialog[1]
-
-

Conditions
-

Actions
-


For each (Integer A) from 1 to 12, do (Actions)
-



Loop - Actions
-




If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-





If - Conditions
-






(Clicked dialog button) Equal to DialogButton[(Integer A)]
-
-





Then - Actions
-






Set ChallengedHero[1] = Hero[((Integer A) + 1)]
-






If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-







If - Conditions
-








(ChallengedHero[1] belongs to an ally of Player 1 (Red)) Equal to True
-
-







Then - Actions
-








Game - Display to Player Group - Player 1 (Red) the text: (PlayerNames[(Player number of (Owner of ChallengedHero[1]))] + is your ally. You cannot challenge him)
-
-







Else - Actions
-








Game - Display to (Player group((Owner of ChallengedHero[1]))) the text: (PlayerNames[1] + has challenged you to a duel! If you accept. Type -accept in the next 30 seconds if you accept.')
-
-
-
-





Else - Actions
-
-
-
-
-
-
Button clicked Copy
-

Events
-


Player - Player 1 (Red) types a chat message containing -accept as An exact match
-


Player - Player 2 (Blue) types a chat message containing -accept as An exact match
-


Player - Player 3 (Teal) types a chat message containing -accept as An exact match
-


Player - Player 4 (Purple) types a chat message containing -accept as An exact match
-


Player - Player 5 (Yellow) types a chat message containing -accept as An exact match
-


Player - Player 6 (Orange) types a chat message containing -accept as An exact match
-


Player - Player 7 (Green) types a chat message containing -accept as An exact match
-


Player - Player 8 (Pink) types a chat message containing -accept as An exact match
-


Player - Player 9 (Gray) types a chat message containing -accept as An exact match
-


Player - Player 10 (Light Blue) types a chat message containing -accept as An exact match
-


Player - Player 11 (Dark Green) types a chat message containing -accept as An exact match
-


Player - Player 12 (Brown) types a chat message containing -accept as An exact match
-
-

Conditions
-

Actions
-


Set PrivateDuel[(Player number of (Triggering player))] = True
-


If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-



If - Conditions
-




PrivateDuel[1] Equal to True
-
-



Then - Actions
-




Set HeroLife[1] = (Life of Hero[1])
-




Set HeroMana[1] = (Mana of Hero[1])
-




Set HeroLife[(Player number of (Triggering player))] = (Life of ChallengedHero[1])
-




Set PositionOfTheHeroes[(Player number of (Triggering player))] = (Position of ChallengedHero[1])
-





Set PositionOfTheHeroes[1] = (Position of Hero[1])
-





Unit - Move Hero[1] instantly to (Center of 1v1 Duel Arena <gen>)
-





Unit - Move ChallengedHero[1] instantly to (Center of 1v1 Duel Arena <gen>)
-





Unit - Set life of Hero[1] to 100.00%
-





Unit - Set life of ChallengedHero[1] to 100.00%
-





Unit - Set mana of Hero[1] to 100.00%
-





Unit - Set mana of ChallengedHero[1] to 100.00%
-
-
-



Else - Actions
-
-
-
Any help is extremely appreciated, and will be rewarded accordingly

