Multple Line (" ")
#1

is it possible to have a text like "text here" on multiple lines because i have ALLOT of text in it.

for example:

Код:
TextDrawCreate(X,Y,"blablablablablabla Line 1
Blablablablabla LINE 2 Blablablablabla LINE 2
Blablablablabla LINE 3 Blablablablabla LINE 3
Blablablablabla LINE 4 Blablablablabla LINE 4
Blablablablabla LINE 5 Blablablablabla LINE 5
Blablablablabla LINE 6 Blablablablabla LINE 6")
when i do something like that i get an error.. any way to do this??
Reply
#2

The only way that I think MIGHT work, because I've never tested it and don't know, is using \r\n. Otherwise, you might have to make more textdraws.
Reply
#3

You can use ~n~ in text draws
Reply
#4

no i mean
new lines in script

this is how it looks in script:

Код:
TextDrawCreate(X,Y,"jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkdjhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfglkjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsfghdfghsfhsfhsfghsfgh");
what i want is:

Код:
TextDrawCreate(X,Y,"jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkd
jhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfgl
kjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsf
ghdfghsfhsfhsfghsfgh");
Reply
#5

Quote:
Originally Posted by <__Ethan__>
no i mean
new lines in script

this is how it looks in script:

Код:
TextDrawCreate(X,Y,"jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkdjhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfglkjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsfghdfghsfhsfhsfghsfgh");
what i want is:

Код:
TextDrawCreate(X,Y,"jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkd
jhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfgl
kjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsf
ghdfghsfhsfhsfghsfgh");
And he told you ~n~ creates a new line.
Reply
#6

Quote:
Originally Posted by Norn
And he told you ~n~ creates a new line.
He would get errors trying to compile because the line is too long.

He should do this.

pawn Код:
new str[270];
new str1[48] = "jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkd";
new str2[73] = "jhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfgl";
new str3[73] = "kjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsf";
new str4[70] = "ghdfghsfhsfhsfghsfgh";
format(str, sizeof(str), "%s~n~%s~n~%s~n~%s", str1, str2, str3, str4);
TextDrawCreate(X,Y, str);
Reply
#7

i believe he is just talking about how ugly it looks in the script, try putting a \ at the end of the line like
pawn Код:
TextDrawCreate(X,Y,"jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkd \
jhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfgl \
kjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsf \
ghdfghsfhsfhsfghsfgh"
);
Reply
#8

Quote:
Originally Posted by Daren_Jacobson
i believe he is just talking about how ugly it looks in the script, try putting a \ at the end of the line like
pawn Код:
TextDrawCreate(X,Y,"jhgjahd;gh;adhg;jahd;gjkha;kdjhgklajhdklgjhalkd \
jhgklahdkjghlakjdhglkjahdlkgjhaldkjghlakjdfhglkajdhlgkjhadlkfjghlakjdhfgl \
kjahdflkgjhalkdjfghlkajdhglkjahdlkfjghlkajdfgadfgadfgsfdhgsfghdfghsfhsf \
ghdfghsfhsfhsfghsfgh"
);
THATS EXACTLY WHAT I WANTED THX!!!
Reply
#9

Thanks for this I just recently ran into the line to long thing and also wondered if there was a way around this.
Reply
#10

Quote:
Originally Posted by cyber_punk
Thanks for this I just recently ran into the line to long thing and also wondered if there was a way around this.
It will not fix the "input line too long" error!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)