23.03.2015, 15:13
make a command /races [n] (n= 1, 2, 3...)
n depends of the total races. In your case you need 7 dialogs, the last with only two races (8*6)+2 = 50 races, so n=7.
This solution is not very good because you need to edit the script everytime you add a new race.
Код:
dcmd_races(playerid, params[]) { if (params[0] == '1' && params[1] == '\0' ) { // show your first dialog (races 1 to 8) return 1; } else if ( params[0] == '2' && params[1] == '\0' ) { // show your second dialog (races 9 to 16) return 1; } ... ... else if ( params[0] == 'n' && params[1] == '\0' ) { // show your n dialog (races 8*(n-1) to last) return 1; } else return SendUsage( playerid, "/races [1 to n]" ); }
This solution is not very good because you need to edit the script everytime you add a new race.