STATS command.
#1

How to creat stats command?
My Register system - https://sampforum.blast.hk/showthread.php?tid=273088
Код:
    if (strcmp("/stats", cmdtext, true, 5) == 0)
    {
        SendClientMessage(playerid, 0xFFFFFFFF, " |- - - - - - - - - - - - - - - - - - - |");
        SendClientMessage(playerid, 0xFFFFFFFF, " - [Player name] these are your stats");
        SendClientMessage(playerid, 0xFFFFFFFF, " - Cash: ");
        SendClientMessage(playerid, 0xFFFFFFFF, " - Kills:");
        SendClientMessage(playerid, 0xFFFFFFFF, " - Deaths:");
        SendClientMessage(playerid, 0xFFFFFFFF, " - Admin Level:");
        SendClientMessage(playerid, 0xFFFFFFFF, " |- - - - - - - - - - - - - - - - - - - |");
        return 1;
    }
Код:
new gPlayerLogged[MAX_PLAYERS];
new pRank[MAX_PLAYERS];

enum pInfo
{
    pPass,
    pCash,
    pAdmin,
    pKills,
    pDeaths
}
new PlayerInfo[MAX_PLAYERS][pInfo];

forward LoadUser_data(playerid,name[],value[]);
public LoadUser_data(playerid,name[],value[])
{
    INI_Int("Password",PlayerInfo[playerid][pPass]);
    INI_Int("Cash",PlayerInfo[playerid][pCash]);
    INI_Int("Admin",PlayerInfo[playerid][pAdmin]);
    INI_Int("Kills",PlayerInfo[playerid][pKills]);
    INI_Int("Deaths",PlayerInfo[playerid][pDeaths]);
    return 1;
}
Reply


Messages In This Thread
STATS command. - by Bug. - 27.10.2012, 14:32
Re: STATS command. - by gtakillerIV - 27.10.2012, 14:36
Re: STATS command. - by Bug. - 27.10.2012, 14:41
Re: STATS command. - by Bug. - 27.10.2012, 14:49
Re: STATS command. - by gtakillerIV - 27.10.2012, 14:54
Re: STATS command. - by Bug. - 27.10.2012, 14:56
Re: STATS command. - by gtakillerIV - 27.10.2012, 14:57
Re: STATS command. - by Bug. - 27.10.2012, 15:03
Re: STATS command. - by CmZxC - 27.10.2012, 15:05
Re: STATS command. - by Bug. - 27.10.2012, 15:07

Forum Jump:


Users browsing this thread: 3 Guest(s)