I
IKilledKEnny
Guest
Hello all,
I wrote this question ina a new theard (and not in the previous theard I made) becuase I didn't want to make the previous one too long, I hope that's ok, if not I'll of course delete this post
anyway I got 2 triggers here;
Trigger 1:
Trigger 2:
Trigger one should award you 20 points if you kill a building that is not yours, but instead it awards you 21 points.
Trigger two should award you 100 points if you kill a town hall that is not yours, but instead it awards you 121 points.
Here is the second question:
How can I say in text the name of a player? What I mean is this; If player just lost I want everybody to know he lost so I'll send them a massage the problem is I don't know the name of the player so it needs to change from game to game and from player to player. Can anyone help me with that as well?
Thanks for your time. I appreciate it.
I wrote this question ina a new theard (and not in the previous theard I made) becuase I didn't want to make the previous one too long, I hope that's ok, if not I'll of course delete this post
anyway I got 2 triggers here;
Trigger 1:
Code:
Building LeaderBoard
Events
Unit - A unit Dies
Conditions
((Triggering unit) is A structure) Equal to True
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player number of (Owner of (Triggering unit))) Not equal to (Player number of (Owner of (Killing unit)))
Then - Actions
Set PlayerKills[(Player number of (Owner of (Killing unit)))] = (PlayerKills[(Player number of (Owner of (Killing unit)))] + (19 + 1))
Leaderboard - Change the value for (Owner of (Killing unit)) in (Last created leaderboard) to PlayerKills[(Player number of (Owner of (Killing unit)))]
Leaderboard - Sort (Last created leaderboard) by Value in Descending order
Else - Actions
Do nothing
Trigger 2:
Code:
Building LeaderBoard
Events
Unit - A unit Dies
Conditions
((Triggering unit) is A structure) Equal to True
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player number of (Owner of (Triggering unit))) Not equal to (Player number of (Owner of (Killing unit)))
Then - Actions
Set PlayerKills[(Player number of (Owner of (Killing unit)))] = (PlayerKills[(Player number of (Owner of (Killing unit)))] + (19 + 1))
Leaderboard - Change the value for (Owner of (Killing unit)) in (Last created leaderboard) to PlayerKills[(Player number of (Owner of (Killing unit)))]
Leaderboard - Sort (Last created leaderboard) by Value in Descending order
Else - Actions
Do nothing
Trigger one should award you 20 points if you kill a building that is not yours, but instead it awards you 21 points.
Trigger two should award you 100 points if you kill a town hall that is not yours, but instead it awards you 121 points.
Here is the second question:
How can I say in text the name of a player? What I mean is this; If player just lost I want everybody to know he lost so I'll send them a massage the problem is I don't know the name of the player so it needs to change from game to game and from player to player. Can anyone help me with that as well?
Thanks for your time. I appreciate it.