01.01.2013, 20:15
Well; I want a dialog to show to all players;
however when I ran this;
Stock;
Command;
The dialog reopens after pressing close and just wont go away! Any Ideas? :3
however when I ran this;
Stock;
pawn Код:
ShowDialogForAll(dialogid, dialogstyle, caption[], info[], button1[], button2[])
{
new
x
;
do
{
if(IsPlayerConnected(x) && !IsPlayerNPC(x))
{
ShowPlayerDialog(x, dialogid, dialogstyle, caption, info, button1, button2);
}
}
while((x != MAX_PLAYERS));
return 1;
}
pawn Код:
CMD:annrestart(playerid, params[])
{
if(PlayerInfo[playerid][pAdminLevel] >= 3)
{
new string[128];
strcat(string, "There is going to be a restart\nPlease /q to save your stats before the restart");
ShowDialogForAll(100, DIALOG_STYLE_MSGBOX, "Server Restarting Soon", string, "Close", "");
return 1;
}
return 1;
}