Scripting help
#1

I want to do "Next Page" in dialog, it's /cmds and it is too long

please give me example how to make "Next Page"
Reply
#2

You make a button that says 'Next Page' and then when the player clicks it (response or !response), it will show a new dialog having the commands.
Reply
#3

Yes, I know but please give me a code example?
Reply
#4

pawn Код:
#define DIAG_CMDS1 (667)
#define DIAG_CMDS2 (668)
#define DIAG_CMDS3 (669)

CMD:cmds(playerid, params[]) {
    ShowPlayerDialog(playerid, DIAG_CMDS1, DIALOG_STYLE_LIST, "Commands", "/shit\n/pee\n/die\n/kill", "Next page", "Cancel");
    return 1;
}

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) {
    if (response) {
        switch (dialogid) {
            case DIAG_CMDS1:
                ShowPlayerDialog(playerid, DIAG_CMDS2, DIALOG_STYLE_LIST, "Commands-2", "page 2\nempty", "Next page", "Cancel");
            case DIAG_CMDS2:
                ShowPlayerDialog(playerid, DIAG_CMDS3, DIALOG_STYLE_LIST, "Commands-3", "page 3\nwhatcha lookin for", "Okay", "");
        }
    }
    return 1;
}
Reply
#5

Ok here is my code of /cmds

how to make that in the next page :

/veh - to spawn a car

Код:
CMD:cmds (playerid)
{
	new bigstring[3000];
    strcat(bigstring, "{FCFFC3}Commands:\n");
    strcat(bigstring, "{6EAAFF}/teleports (/teles) -{FF0000} Command to show all teleports\n");
	ShowPlayerDialog(playerid, DIALOG_CMDS, DIALOG_STYLE_MSGBOX, ""RED"[EsF]Server Commands", bigstring, "OK", "Next Page");
	return 1;
}
Reply
#6

Help Please
Reply
#7

helpp
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)