leaderboard help

W

War-Crafter

Guest
ok im making a leader board and im working on the tallying system. this is the trigger im using.

Trigger Tally Score

Events
Unit - A unit Dies
Conditions
((Killing unit) belongs to an ally of Player 1 (Red)) Equal to True
Actions
Set Player_Kills[(Player number of (Owner of (Killing unit)))] =
(Player_Kills[(Player number of (Owner of (Killing unit)))] + 1)


Leaderboard - Change the value for (Owner of (Killing unit)) in
(Last created leaderboard) to Player_Kills[(Player number of (Owner of (Killing unit)))]

Leaderboard - Sort (Last created leaderboard) by Value in Descending order

under the first action it says +1 but when i make it i cant figure out how to add the +1 part. when i use my map it doesnt add 1 for every kill like i want it to. help plz
 
O

Opossum

Guest
I am not sure I'm getting your problem but it sounds like you don't use the arithmetic function to add to your value. At the point where you want the +1, just select "arithmetic" and you should be fine from there.
 

WilliamPa

Active Member
Reaction score
51
Also remove the condition or triggering players and owner of killing units are pretty useless...
 

Advena

Just casually observing atm ;)
Reaction score
42
like opossum said, you use the "aritmethic" thingy that is the first that shows up when you make a new such action, and then you put in your values.
So say for example that you hava an integer variable that you want to increase (moving off topic now, just to explain easier) by using the "set variable" action.
Say you want increase it by 2 when some event occurs.

Then you would ue the "set variable" action, putting the name of the variable to the left of the summary symbol. To the right there is still a red text that needs to be filled with a value before you can click "ok" on making the action.
When you open that value you'll have "aritmethic" preselected and you'll see that you can add two separate values separated by a + (can be changed to -, x or / too). Click the first one and select the variable again, even here. Click ok.
The second value (on the other side of the +) you set simply as "1".

Now you'll have an action that looks something like this (I don't we open atm):
Set (My_Integer_Variable) = ((My_Integer_Variable) + (1))
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top