Page 1 of 1

Kills Leader-Board

Posted: Sat Apr 23, 2011 11:27 am
by Loopsnhoops
Hi,

I am making a zombie map in Reign of Chaos and I would like to know how to make a kills leader board. Unfortunately all the sites I go to lead to one event where the word "actions" is used and my version of editor has problems which won't allow it to update. I would like to know a simple way in which I can create a leader board that looks at the names of the players in the slots and saves their kills overall for each game. Ex. loopsnhoops gets 31 kills in his first game and then he rejoins and gets another 31 kills and the leader board will track it or store it in some database and display the overall kills as 62. What I have so far is when the game time has elapsed 2 seconds a leader board with the title kills is created. Then it adds everybody in all the slots who are playing to the leader board. But I can't get the value for kills working.

Thanks, loopsnhoops

P.S: If you don't mind me asking can you give me a brief description of the algorithm you used for your search button.

Re: Kills Leader-Board

Posted: Sat Apr 23, 2011 11:48 am
by samtre
i didn't know that zombie maps can be created in RoC though.....
if its a trigger, of course an 'action' is used, i guess.........

For the leaderboard,
variables:
LEADERBOARD (leaderboard)
player_kills (integer)
Create a leaderboard Create a leaderboard
t_eve Events Elapsed time is 1 seconds t_if Conditions t_act Actions Loop 1 to 12 - Add player[Convert player number to player] to LEADERBOARD - Sort alphabetically
Updating leaderboard Updating leaderboard
t_eve Events A unit is killed t_if Conditions Get unit is Undead equal to true (Boolean) t_act Actions set player_kills[get_killing_unit] = (player_kills[get_killing_unit] = 1) set leaderboard value for player(get_killing_unit_ to player_kills[get_killing_unit] leaderboard - update leaderboard - sort
for the overall kill thing, i suggest a saving trigger, which checks the name of the "loader" and in the save code will also have the total number of kills

Re: Kills Leader-Board

Posted: Sun Apr 24, 2011 1:16 pm
by Loopsnhoops
I don't have access to some of the triggers you mentioned like the player conversion and the set variable thing.

Re: Kills Leader-Board

Posted: Sun Apr 24, 2011 1:18 pm
by 3ICE
Loopsnhoops wrote:give me a brief description of the algorithm you used for your search button.
I have three different search algorithms. Which one are you interested in?
Loopsnhoops wrote:the word "actions" is used
Every trigger uses actions. Therefore they all have the word "actions" in them.
Loopsnhoops wrote:my version of editor has problems which won't allow it to update
We don't support outdated editors. You should reinstall the game. (If you don't have the CD, here is how you can redownload warcraft 3: http://www.3ice.hu/blog/download-warcraft/)
Loopsnhoops wrote:saves their kills overall for each game
Saving is not possible.
Loopsnhoops wrote:rejoins and gets another 31 kills
It is not possible to transfer data between maps, other than through user input. (chat)
Loopsnhoops wrote:store it in some database
Not possible. The only way you can keep a score board, is if you forced everyone to -save and then -load their killcounts (through a save code) every game. But nobody is going to bother with that, unless your map offers some sort of reward for reaching a number of kills. And then it would just get hacked.
Loopsnhoops wrote:But I can't get the value for kills working.
Killcount Killcount
     t_eve Events          t_uni A unit owned by Brown dies.      t_act Actions          t_set Set Kills[Player number of (Triggering player)] to Kills[Player number of (Triggering player)] + 1
Loopsnhoops wrote:zombie maps are pretty easy to make on ROC if you use regions effectively.
A zombie map has little to do with regions or effectiveness.

Re: Kills Leader-Board

Posted: Sun Apr 24, 2011 1:29 pm
by Loopsnhoops
Thanks for the link to the reinstallation and you have not seen my map and so you would not know why the regions are so important in it and thanks for the information on the saving thing and if you know how to use the editor for sc2 can you outline the differences between them besides the obvious stuff because in sc2 I have seen a database like structure in their custom games. Also in my editor which as you pointed out was outdated their is a difference between the keyword "action" and "actions".

Thanks, Loopsnhoops

Re: Kills Leader-Board

Posted: Sun Apr 24, 2011 2:00 pm
by 3ICE
Loopsnhoops wrote:if you know how to use the editor for sc2 can you outline the differences between them
http://www.google.com/search?q=editor+difference+warcraft+3+starcraft+2
Loopsnhoops wrote:in sc2 I have seen a database like structure in their custom games
Yes, SC2 can save variables to a file and load it next game. But this is still far from satisfying, as I want my variables saved to my web server (via an http request).
Loopsnhoops wrote:difference between the keyword "action" and "actions".
Never seen an issue like yours. A screenshot would help.