Hello,
I'm trying to write a script to add/check/change someone's ranking on mirc.
So if someone typed "!rank somebody" the script would reply with "Somebody's rank is: Hard [Date added: 12/12/12]"
However, if you try to check the ranking of someone who's not on the list it would reply with: "Somebody does not have a rank, yet."
Typing "!rank" only would give the reply "Please choose a player."
I got this right now but I'm like 99% sure this is rubbish and doesn't work. I also don't know how to add the "[Date added: x/x/x]" part.
on *:TEXT:!rank *:#: {
var %nick $2-
var %rank
if (!%rank) {
/msg $chan %nick does not have a rank, yet.
return
}
/msg $chan %nick $+ 's rank is: %rank [Date added: ]
The available ranks should be: "Very Easy", "Easy", "Normal", "Hard" and "Very hard".
I'm not sure how to save the playername and rank information, though. I'm thinking of using a .txt file for saving the information.
Now for the part I have no clue how to start at all.
I want the people in my channel to be able to promote/demote a player's rank.
so if someone is currently ranked "Hard" people can type "!promote [Name]" to change his rank to "Very Hard". However, this should require the vote of 5 different people. So if the same person tries to promote the same player again he should get the notice: "You've already voted for [Name]!"
Once the player rank has changed you should be able to vote for the same person again. The same goes for "!demote [Name]".
So what I'm trying to do is overwriting a player's rank with the next higher/lower rank but only if 5 different people have entered the command. After successfully changing the rank, the date the rank was added should also be updated.
Example:
Someone's rank is: Hard [Date added: 1/1/12]
---After 5 users have voted to demote the player---
Someone's rank is: Normal [Date added: 2/2/12]
I would be VERY grateful for any help.