28.11.2014, 14:05
It should do, it does nothing.
Код:
ShowStats(playerid,targetid)
{
if(IsPlayerConnected(targetid)) {
new sext[16];
if(PlayerInfo[targetid][pSex] == 1) { sext = "Male"; } else { sext = "Female"; }
new age = PlayerInfo[targetid][pAge];
new ptime = PlayerInfo[targetid][pConnectTime];
new pot = PlayerInfo[targetid][pPot];
new crack = PlayerInfo[targetid][pCrack];
new meth = PlayerInfo[targetid][pMeth];
new money = PlayerInfo[targetid][pCash];
new coordsstring[268], str[3000];
format(coordsstring, sizeof(coordsstring),"Name: %s | Sex: %s| Age: %d | Cash: $%d | Playing hours: %d | Meth: %d | Crack: %d | Pot: %d\n", GetPlayerNameEx(targetid), sext, age, money, ptime, meth, crack, pot);
strcat(str, coordsstring);
if (PlayerInfo[playerid][pAdmin] >= 6)
{
if(PlayerInfo[targetid][pAdmin] >= 1)
{
format(coordsstring, sizeof(coordsstring), "Accepted reports: %d | Admin Messages Sent: %d\n", PlayerInfo[targetid][pReportsAccepted], PlayerInfo[targetid][pAMSSent]);
strcat(str, coordsstring);
}
if(PlayerInfo[targetid][pHelper] >= 1)
{
format(coordsstring, sizeof(coordsstring), " Accepted help requests: %d\n", PlayerInfo[targetid][pAcceptedHelp]);
strcat(str, coordsstring);
}
}
ShowPlayerDialog(playerid, DIALOG_SHOW_INFO, DIALOG_STYLE_MSGBOX, "{33AA33}General Player Information", str, "Ok", "Close");
}
}

