Dialogue Help
#1

I have this:

pawn Код:
ShowPlayerDialog(playerid, 2, DIALOG_STYLE_MSGBOX, "List of teleports", "Stunt Teleports:  /home /ss /df /dj /2c /bowl /fd1 /fd2 /hj /hp /lstower /lvairport /pj /skatepark /stadium /tp /tp1 /wallride /waytodeath /deadjump /monstercrash\n\nDeathmatches: /CNR /omaha /pirate /CSS /Gangwars /Jetpackdm /csdm /Sniperdm /lcdm /area51 /indoordm /MGM /OH /glassmadness /RCWAR /Shipmadness\n\nRacing and Drifting: /drag2 /drag /karting /karting2 /8track /canalrace /circuit /driftcity /hwydrag /beachcity /skrace /usr /dirt /drift", "OK", "Cancel");
and I'm getting the error:
Код:
error 075: input line too long (after substitutions)
I tired making it 2 lines but it breaks the code so what am I suppose to do?
Reply
#2

Instead of \n or
pawn Код:
ShowPlayerDialog(..., "
[text]"
);
use \n\
Reply
#3

Did not change anything
Reply
#4

You can only "beat" that you put text in more strings and then put them together.
Reply
#5

Quote:
Originally Posted by Sergei
Посмотреть сообщение
You can only "beat" that you put text in more strings and then put them together.
What does that even mean? Also ive seen on other server have much more text than this.
Reply
#6

Something like:
pawn Код:
new string[64],string2[100],string3[165];
format(string,sizeof(string),"List of teleports", "Stunt Teleports:  /home /ss /df /dj /2c /bowl /fd1 /fd2 /hj /hp /lstower /lvairport /pj /skatepark /stadium /tp /tp1 /wallride /waytodeath /deadjump /monstercrash\n");
format(string2,sizeof(string2),"\nDeathmatches: /CNR /omaha /pirate /CSS /Gangwars /Jetpackdm /csdm /Sniperdm /lcdm /area51 /indoordm /MGM /OH /glassmadness /RCWAR /Shipmadness\n\nRacing and Drifting: /drag2 /drag /karting /karting2 /8track /canalrace /circuit /driftcity /hwydrag /beachcity /skrace /usr /dirt /drift");
format(string3,sizeof(string3),"%s %s",string,string2);
ShowPlayerDialog(playerid,2,style,string3....);
Not sure,but am I assuming right?
Reply
#7

Format the textdraw with a string;
pawn Код:
new str[1012]; //Just all in one
new msg[] = "enter as much text as you want, this will appear in the textdraw";
format(str, sizeof(str), "%s", msg));
ShowPlayerDialog(playerid, dialogid, DIALOG_STYLE_LIST, str, "accept", "cancel");
Reply
#8

Quote:
Originally Posted by [XST]O_x
Посмотреть сообщение
Something like:
pawn Код:
new string[64],string2[100],string3[165];
format(string,sizeof(string),"List of teleports", "Stunt Teleports:  /home /ss /df /dj /2c /bowl /fd1 /fd2 /hj /hp /lstower /lvairport /pj /skatepark /stadium /tp /tp1 /wallride /waytodeath /deadjump /monstercrash\n");
format(string2,sizeof(string2),"\nDeathmatches: /CNR /omaha /pirate /CSS /Gangwars /Jetpackdm /csdm /Sniperdm /lcdm /area51 /indoordm /MGM /OH /glassmadness /RCWAR /Shipmadness\n\nRacing and Drifting: /drag2 /drag /karting /karting2 /8track /canalrace /circuit /driftcity /hwydrag /beachcity /skrace /usr /dirt /drift");
format(string3,sizeof(string3),"%s %s",string,string2);
ShowPlayerDialog(playerid,2,style,string3....);
Not sure,but am I assuming right?
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if(!strcmp(cmdtext, "/test", true))
    {
        new string[64],string2[100], masterstring[165], string3[128];
        format(string,sizeof(string),"List of teleports", "Stunt Teleports:  /home /ss /df /dj /2c /bowl /fd1 /fd2 /hj /hp /lstower /lvairport /pj /skatepark /stadium /tp /tp1 /wallride /waytodeath /deadjump /monstercrash\n");
        format(string2,sizeof(string2),"\nDeathmatches: /CNR /omaha /pirate /CSS /Gangwars /Jetpackdm /csdm /Sniperdm /lcdm /area51 /indoordm /MGM /OH /glassmadness /RCWAR /Shipmadness\n");
        format(string3,sizeof(string3),"\nRacing and Drifting: /drag2 /drag /karting /karting2 /8track /canalrace /circuit /driftcity /hwydrag /beachcity /skrace /usr /dirt /drift\n");
        format(masterstring,sizeof(string3),"%s %s %s",string,string2,string3);
        ShowPlayerDialog(playerid,2,DIALOG_STYLE_MSGBOX,"%s",masterstring);
        return 1;
    }
    return 0;
}
Код:
C:\Users\Braeden\Desktop\test.pwn(39) : warning 202: number of arguments does not match definition
C:\Users\Braeden\Desktop\test.pwn(39) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Warnings.
Reply
#9

Quote:
Originally Posted by The Toni
Посмотреть сообщение
Format the textdraw with a string;
pawn Код:
new str[1012]; //Just all in one
new msg[] = "enter as much text as you want, this will appear in the textdraw";
format(str, sizeof(str), "%s", msg));
ShowPlayerDialog(playerid, dialogid, DIALOG_STYLE_LIST, str, "accept", "cancel");
Sigh
The message you have entered is too short. Please lengthen your message to at least 8 characters.
Reply
#10

Quote:
Originally Posted by The Toni
Посмотреть сообщение
Sigh
The message you have entered is too short. Please lengthen your message to at least 8 characters.
Just for the record:

Код:
C:\Users\Braeden\Documents\SAMP Server - 0.3b\filterscripts\teleports.pwn(8) : error 075: input line too long (after substitutions)
C:\Users\Braeden\Documents\SAMP Server - 0.3b\filterscripts\teleports.pwn(9) : error 037: invalid string (possibly non-terminated string)
Same error.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)