YCMD:stats(playerid,params[], help)
{
#pragma unused help
#pragma unused params
new string[256], string2[256],str[256];
new TargetID, h, m, s;
new 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\t%d\n",Account[TargetID][accountReact]);
strcat(string2,string);
format(string, sizeof(string),"{22B998}Math Wins:\t\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\n",Account[TargetID][RegisteredDate]);
strcat(string2,string);
format(str,sizeof(str),"{FF4444}-=-Stats from %s",GetName(TargetID));
return ShowPlayerDialog(playerid, 2002, DIALOG_STYLE_MSGBOX, str, string2, "OK","");
}
format(string, sizeof(string),"{22B998}Registered Date:\t%s\n",Account[TargetID][RegisteredDate]);
strcat(string2,string);
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","");
}
[14:35:14] Number of vehicle models: 0 [14:35:35] [DEBUG] |
enum AccountInfo
{
....
RegisteredDate[128],
....
};
INI_WriteString(file,"RegisteredDate
INI_String("RegisteredDate",Account[playerid][RegisteredDate],128);