• 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] Need help with Leaderboard Trigger

Status
Not open for further replies.
Level 14
Joined
Nov 2, 2008
Messages
579
so im having problems with this trigger:


  • Events
  • Unit - A unit Dies
  • Conditions
  • (Owner of (Dying unit)) Equal to Player 2 (Blue)
  • Actions
  • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
    • If - Conditions
      • WINS Equal to 10
    • Then - Actions
      • Game - Victory Player 1 (Red) (Show dialogs, Show scores)
      • Game - Defeat Player 2 (Blue) with the message: You got Rocked...Pa...
    • Else - Actions
      • Wait 7.00 seconds
      • Leaderboard - Change the value for Player 1 (Red) in LeaderBoard to (WINS + 1)
      • Unit Group - Pick every unit in (Units in Region 000 <gen>) and do (Unit - Hide (Picked unit))
      • Trigger - Run Dialog 1 <gen> (checking conditions)
Now what happens is the leaderboard gets set to 1 , then it does not go up, so the game goes on and on and on and on and on and on and on, lol, so anyway can any1 tel meh whats wrong please. :cute:
 
Level 23
Joined
Nov 29, 2006
Messages
2,482
You forgot to increase the variable WINS.

At the Else action, modify it a bit:
  • Wait 7.00 seconds
  • Set WINS = WINS + 1
  • Leaderboard - Change the value for Player 1 (Red) in LeaderBoard to (WINS)
  • Unit Group - Pick every unit in (Units in Region 000 <gen>) and do (Unit - Hide (Picked unit))
  • Trigger - Run Dialog 1 <gen> (checking conditions)
 
Status
Not open for further replies.
Top