/stats command
#1

Hi, another question. How to make an stats system which will take the information from dini?
Another question. How to make an aJail system too with a reason?
Reply
#2

What kind of things you want in your stats?
Reply
#3

Name, money, age, (havent figured out the age system, yet.) Admin level, etc.
Reply
#4

They are saved in DINI or INI?
Reply
#5

The files save .ini

Code:
Name=Sander_Koksaja
Password=*******
LastInt=0
AdminLevel=5
LastX=268.765045
LastY=1883.209960
LastZ=-30.093750
Cash=67612
That is the inside of %s.ini
Reply
#6

dini_Get them into vars, and then format() it and place the vars accordingly, like:


pawn Code:
GetPlayerName(playerid, name, 24);
format(string, sizeof string, "Stats: [%s] Level: %d | Score: %d | Cash: %d |",name,Level[playerid],GetPlayerScore(playerid), GetPlayerMoney(playerid));
SendClientMessage(playerid, -1, string);
Reply
#7

Im sorry, but i dont know how to place any vars or something. Can you do the all command? It uses zcmd.
Reply
#8

Make a new var like:

pawn Code:
new variable;
Then,
pawn Code:
variable = dini_Get(formattedfilehere,"Level");
EDIT: Oh, erm.

pawn Code:
CMD:stats(playerid, params[])
{
    new file[36], Level, name[24], string[42];
    GetPlayerName(playerid, name, 24);
    format(file, sizeof file, "/Users/%s.ini",name);
    Level = dini_Get(file, "Level");
    format(string, sizeof string, "[%s] Admin Level: %d",name,level);
    SendClientMessage(playerid, blue, string);
    return 1;
}
Reply
#9

Hmm, where should i place the
PHP Code:
variable dini_Get(formattedfilehere,"Level"); 
Reply
#10

Place it in your stats command ?
Reply
#11

Nevermind, can you guys help me to make the /ajail (playerid/name) (time) (reason) command?
Reply
#12

That's not really helping you with it, but creating it for you. If you want the script made for you, reply in the Script Requests thread. Otherwise, show us what you have made so far in the command.

There are also multiple administration scripts in the Filterscripts section of this forum that contain that command. Not to mention, countless threads asking the same question as yours as well. Try doing some searching either via the search engine on this forum (which to be honest, isn't that great) or ******.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)