24.12.2015, 12:14
This is only returning the player's stats who is clicking it, it is supposed to return the stats of the person being clicked on, what did I do wrong? Thanks in advance.
Код:
public OnPlayerClickPlayer(playerid, clickedplayerid, source) { new dstring[256]; new Float:ratio=floatdiv(pInfo[playerid][Kills], pInfo[playerid][Deaths]); format(dstring, sizeof(dstring), "Name: %s | ID: %d | Score: %d | Kills: %i | Deaths: %i | KDR: %.2f | Money: %d | Adminlevel: %d | Tester: %d",GetName(playerid), playerid, pInfo[playerid][Scores], pInfo[playerid][Kills], pInfo[playerid][Deaths], ratio, GetPlayerMoney(playerid), pInfo[playerid][Adminlevel], pInfo[playerid][Testerlevel]); ShowPlayerDialog(playerid, DIALOG_STATS, DIALOG_STYLE_MSGBOX, "Stats", dstring, "Close", ""); return 1; }