Statsregister date problйm
#8

Try this
pawn Код:
YCMD:stats(playerid,params[], help)
{
    #pragma unused help
    #pragma unused params
   
    new string[256], string2[512];
    new h, m, s;
    new TargetID, pDeaths;
   
    if(!strlen(params)) TargetID = playerid;
    else TargetID = strval(params);
   
    if(Account[TargetID][Deaths] == 0) pDeaths = 1;
    else pDeaths = Account[TargetID][Deaths];
   
    TotalGameTime(TargetID, h, m, s);

    format(string, sizeof(string),"{22B998}Kills:\t\t\t%d\n",Account[TargetID][Kills]);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Deaths:\t\t\t%d\n",Account[TargetID][Deaths]);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Ratio:\t\t\t%0.2f\n",Float:Account[TargetID][Kills]/Float:pDeaths);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Score:\t\t\t%d\n",GetPlayerScore(TargetID));
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Money:\t\t\t%d$\n",GetPlayerMoney(TargetID));
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}React Wins:\t\t%d\n",Account[TargetID][accountReact]);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Math Wins:\t\t%d\n",Account[TargetID][accountMath]);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Game Time:\t\t\t%d h,%d m,%d s\n",h,m,s);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Donator:\t\t%d\n",Account[TargetID][VipLevel]);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Admin Level:\t\t%d\n",Account[TargetID][Level]);
    strcat(string2,string);
    format(string, sizeof(string),"{22B998}Registered Date:\t%s", Account[TargetID][RegisteredDate]);
    strcat(string2,string);
   
    printf("[DEBUG] %s", Account[TargetID][RegisteredDate]);
   
    format(string,sizeof(string),"{FF4444}-=-Stats from %s",GetName(TargetID));
    return ShowPlayerDialog(playerid, 2002, DIALOG_STYLE_MSGBOX, string, string2, "OK","");
}
If doesn't work, check what prints on your server log/console
Reply


Messages In This Thread
Statsregister date problйm - by anassmaroc - 26.08.2015, 23:07
Re: Statsregister date problйm - by anassmaroc - 27.08.2015, 09:05
Re: Statsregister date problйm - by Matess - 27.08.2015, 09:20
Re: Statsregister date problйm - by anassmaroc - 27.08.2015, 10:11
Re: Statsregister date problйm - by Matess - 27.08.2015, 12:45
Re: Statsregister date problйm - by anassmaroc - 27.08.2015, 13:03
Re: Statsregister date problйm - by HydraHumza - 27.08.2015, 13:14
Re: Statsregister date problйm - by xVIP3Rx - 27.08.2015, 13:14
Re: Statsregister date problйm - by anassmaroc - 27.08.2015, 13:36
Re: Statsregister date problйm - by anassmaroc - 27.08.2015, 18:05

Forum Jump:


Users browsing this thread: 2 Guest(s)