ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_LIST, "Help","Account\nCommands\nRules\nCredits", "Select", "Cancel");
if(strcmp(cmd, "/help", true) == 0)
{
if(IsPlayerConnected(playerid))
{
ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_LIST, "Help","Account\nCommands\nRules\nCredits", "Select", "Cancel");
}
return 1;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == 1338)
{
if(response)
{
if(listitem == 0)
{
ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_MSGBOX, "Account","Account related stuff here", "Back", "Cancel");
}
if(listitem == 1)
{
ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_MSGBOX, "Commands","Command shown here", "Back", "Cancel");
}
if(listitem == 2)
{
ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_MSGBOX, "Rules","Server rules shown here", "Back", "Cancel");
}
if(listitem == 3)
{
ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_MSGBOX, "Credits","Credits here", "Back", "Cancel");
}
}
}
return 0;
}
if(response)
{
//Stuff Here
}
else ShowPlayerDialog(playerid, HELP, DIALOG_STYLE_LIST, "Help","Account\nCommands\nRules\nCredits", "Select", "Cancel");
if(dialogid == HELP && !response) //(!response means it would make a response for the 2nd button)
{
// Do something here
}
Originally Posted by Coldthug
So how would it stay?
|