18.10.2011, 06:13
I meant that you need to create the FPSList string within the command.
Delete new FPSList from the top of your script and use the example below.
PS: Change the cell size to whatever suits your server.
Delete new FPSList from the top of your script and use the example below.
PS: Change the cell size to whatever suits your server.
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/fpslist", cmdtext, true, 10) == 0)
{
new FPSList[128];
for(new i = 0; i < MAX_PLAYERS; ++i)
{
if(IsPlayerConnected(i) && !IsPlayerNPC(i))
{
format(FPSList, sizeof(FPSList), "%s%s: %d\n", FPSList, pName(i), FPS2[i]-1);
ShowPlayerDialog(playerid, DIALOG_FPS_LIST, DIALOG_STYLE_MSGBOX, "Players FPS", FPSList, "Ok", "");
}
}
return 1;
}
return 0;
}