27.07.2012, 21:16
Hi all, I'm making player statistics in textraws, and it's going very well, but there is a bug.
When I typed my command to show stats (/account profile) it show stats normally, but when other player type /account profile I'm watching his stats. I changed targetid with playerid because it show me error: undefined targetid.
Please help.
When I typed my command to show stats (/account profile) it show stats normally, but when other player type /account profile I'm watching his stats. I changed targetid with playerid because it show me error: undefined targetid.
Please help.
Код:
TextDrawShowForPlayer(playerid, StatsTacke);
format(string,sizeof string,"---------------------");
TextDrawSetString(StatsTacke,string);
TextDrawShowForPlayer(playerid, StatsLevel);
format(string,sizeof string,"LEVEL: %d",PlayerInfo[playerid][pLevel]);
TextDrawSetString(StatsLevel,string);
TextDrawShowForPlayer(playerid, StatsRespekti);
new nxtlevel = PlayerInfo[playerid][pLevel]+1;
new expamount = nxtlevel*levelexp;
format(string,sizeof string,"RESPEKTI: %d/%d",PlayerInfo[playerid][pExp], expamount);
TextDrawSetString(StatsRespekti,string);
TextDrawShowForPlayer(playerid, StatsDoRespekta);
format(string,sizeof string,"DO RESPEKTA: %d/60", PlayerInfo[playerid][pMinutePayDay]);
TextDrawSetString(StatsDoRespekta,string);
TextDrawShowForPlayer(playerid, StatsNovac);
format(string,sizeof string,"NOVAC: %d$", PlayerInfo[playerid][pCash]);
TextDrawSetString(StatsNovac,string);
TextDrawShowForPlayer(playerid, StatsBanka);
format(string,sizeof string,"BANKA: %d$", PlayerInfo[playerid][pAccount]);
TextDrawSetString(StatsBanka,string);
TextDrawShowForPlayer(playerid, StatsOrg);
format(string,sizeof string,"ORG: %d", PlayerInfo[playerid][pMember]);
TextDrawSetString(StatsOrg,string);


