21.07.2010, 10:18
How make Float right?
when i do /testcmd then i get nnnnnnnnnnnnnn I think how to make its to player dynamic.....
pawn Код:
enum Pydinf
{
Float:Pros
}
new AdminDuty[MAX_PLAYERS];
forward Prot;
new PlayerInfo[MAX_PLAYERS][Pydinf];
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/testcmd", cmdtext, true, 10) == 0)
{
new text[128];
format(text,sizeof text,"Stuff have: %s",PlayerInfo[playerid][Pros]);
SendClientMessage(playerid,0x8C1717,text);
return 1;
}
return 0;
}
public Prot()
{
for(new i=0;i<MAX_PLAYERS;i++)
{
if(AdminDuty[i] == 0)
PlayerInfo[i][Pros] -= 1;
else
{
PlayerInfo[i][Pros] += 1;
}
}
}