14.08.2015, 14:30
(
Последний раз редактировалось Hemeei; 15.08.2015 в 02:21.
)
Help me my textdraw is bug , I Draw a stats on Screen But! its mixing up all player score :3
i want own score only will show on there screen huhuhu
heres the forward code
i want own score only will show on there screen huhuhu
heres the forward code
PHP код:
forward textdraw(playerid);
public textdraw(playerid)
{
for(new i; i <MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
new pscore[127];
format(pscore, sizeof(pscore), "Score : ~y~%d" ,GetPlayerScore(i));
PlayerTextDrawSetString(playerid, Textdraw1[i], pscore);
//new pname[128];
new names[MAX_PLAYER_NAME];
GetPlayerName(playerid, names, sizeof(names));
format(names, sizeof(names),"Name : ~y~%s" ,names);
PlayerTextDrawSetString(playerid, Textdraw2[i], names);
new prank[129];
format(prank, sizeof(prank), "Rank : ~y~%s" ,GetRankName(i));
PlayerTextDrawSetString(playerid, Textdraw3[i], prank);
new pclass[130];
format(pclass, sizeof(pclass), "Class : ~y~%s" ,GetClass(i));
PlayerTextDrawSetString(playerid, Textdraw4[i], pclass);
new pkill[131];
format(pkill, sizeof(pkill), "Kills : ~y~%d" ,PlayerInfo[i][Kills]);
PlayerTextDrawSetString(playerid, Textdraw5[i], pkill);
new pdeath[132];
format(pdeath, sizeof(pdeath), "Deaths : ~y~%d" ,PlayerInfo[i][Deaths]);
PlayerTextDrawSetString(playerid, Textdraw6[i], pdeath);
new pdkill;
new pdkills[100];
if(PlayerInfo[i][Deaths] == 0) pdkill = 1; else pdkill = PlayerInfo[i][Deaths];
format(pdkills, sizeof(pdkills), "K/D Ratio : ~y~%0.2f" ,Float:PlayerInfo[i][Kills]/Float:pdkill);
PlayerTextDrawSetString(playerid, Textdraw7[i], pdkills);
new pip[136];
new tmp33[50];
GetPlayerIp(playerid,tmp33,50);
format(pip,sizeof(pip),"IP : ~y~%s", tmp33);
PlayerTextDrawSetString(playerid, Textdraw8[i], pip);
new phealthw[137];
new Float:armour;
GetPlayerArmour(playerid, armour);
format(phealthw, sizeof(phealthw),"%0.0f", armour);
PlayerTextDrawSetString(playerid, healthcount[i], phealthw);
new phealthr[137];
new Float:health;
GetPlayerHealth(playerid,health);
format(phealthr, sizeof(phealthr),"%0.0f", health);
PlayerTextDrawSetString(playerid, healthcount1[i], phealthr);
new ping[138];
format(ping,sizeof(ping),"Ping : ~r~%i",GetPlayerPing(i));
PlayerTextDrawSetString(playerid, TextPing[i], ping);
}
}