String problem when using DIALOG_STYLE_TABLIST_HEADERS
#1

Hi,

I tried to make a command to show all players online using this code:
Код:
CMD:onlineplayers(playerid, params[])
{
	new Tabs[500], List[500];
	for (new i; i < MAX_PLAYERS; i++)
	{
		if (IsPlayerConnected(i))
		{
			format(Tabs, 500, "Player\tID\n%s\n", List);
			format(List, 500, "%s%s\t%i\n", List, GetName(i), i);
		}
	}
	if (strlen(List) > 0) ShowPlayerDialog(playerid, 1, DIALOG_STYLE_TABLIST_HEADERS, "Online Players:", Tabs, "Close", "");
	return 1;
}
I tested this with two players but it's showing only the player with the lower id.
Reply


Messages In This Thread
String problem when using DIALOG_STYLE_TABLIST_HEADERS - by Darkwood17 - 31.05.2015, 00:19
Re: String problem when using DIALOG_STYLE_TABLIST_HEADERS - by Jefff - 31.05.2015, 00:29
Re: String problem when using DIALOG_STYLE_TABLIST_HEADERS - by Darkwood17 - 31.05.2015, 08:41

Forum Jump:


Users browsing this thread: 1 Guest(s)