input line too long
#1

hello how i can fix this big line .

error :

Quote:

error 075: input line too long (after substitutions)

Quote:

ShowPlayerDialog(playerid, 1112, DIALOG_STYLE_MSGBOX, "Welcome / Sveiki Atvyke !", "{FFFFFF}Welcome To Our Server ! / {FFFFFF}Sveiki Atvyke i Musu Serveri !\n \nThe predominant language in this server is : Lithuanian.\n{FFFFFF}Because the half of players are from other countries we set language to English.\nU can change language by typing :\n\n{FFFF00}/LTU {FFFFFF}- For Lithuanian \n\n{FFFF00}/ENG {FFFFFF}- For English\n\n{FFFFFF}Pagrindine sio serverio kalba yra : Anglu.\n{FFFFFF}Daugybe sio serverio zaideju yra is kitu pasaulio saliu , mes nustateme kalba i Anglu.\nKalba galite pakeisti rasydami:\n\n{FFFF00}/LTU {FFFFFF}- Lietuviu Kalba\n\n{FFFF00}/ENG {FFFFFF}- Anglu Kalba", "Ok", "");

http://pastebin.com/wLtr0njA
Reply
#2

Split it up maybe? Or use strcat?
Reply
#3

I don't know how to use strcat , so maaaany errors ...
Reply
#4

Use either strcat or just '\'.

pawn Код:
// Examples:

"blablabla \
blablabla \
blablabla \
blablabla
"


// OR

new
    string[ 128 ] // If the lenght is longer, change it.
;
strcat(string, "blablabla");
strcat(string, "blablabla");
strcat(string, "blablabla");
strcat(string, "blablabla");
Reply
#5

pawn Код:
new long_string[632];
strcat(long_string,"{FFFFFF}Welcome To Our Server ! / {FFFFFF}Sveiki Atvyke i Musu Serveri !\n \nThe predominant language in this server is : Lithuanian.\n");
strcat(long_string,"{FFFFFF}Because the half of players are from other countries we set language to English.\nU can change language by typing :\n\n{FFFF00}/LTU {FFFFFF}");
strcat(long_string,"- For Lithuanian \n\n{FFFF00}/ENG {FFFFFF}- For English\n\n{FFFFFF}Pagrindine sio serverio kalba yra : Anglu.\n{FFFFFF}Daugybe sio serverio zaideju yra is kitu pasaulio saliu , mes nustateme kalba i Anglu.\n");
strcat(long_string,"Kalba galite pakeisti rasydami:\n\n{FFFF00}/LTU {FFFFFF}- Lietuviu Kalba\n\n{FFFF00}/ENG {FFFFFF}- Anglu Kalba");
ShowPlayerDialog(playerid, 1112, DIALOG_STYLE_MSGBOX, "Welcome / Sveiki Atvyke !", long_string, "Ok", "");
This should work.
Reply
#6

Quote:
Originally Posted by zombieking
Посмотреть сообщение
pawn Код:
new long_string[632];
strcat(long_string,"{FFFFFF}Welcome To Our Server ! / {FFFFFF}Sveiki Atvyke i Musu Serveri !\n \nThe predominant language in this server is : Lithuanian.\n");
strcat(long_string,"{FFFFFF}Because the half of players are from other countries we set language to English.\nU can change language by typing :\n\n{FFFF00}/LTU {FFFFFF}");
strcat(long_string,"- For Lithuanian \n\n{FFFF00}/ENG {FFFFFF}- For English\n\n{FFFFFF}Pagrindine sio serverio kalba yra : Anglu.\n{FFFFFF}Daugybe sio serverio zaideju yra is kitu pasaulio saliu , mes nustateme kalba i Anglu.\n");
strcat(long_string,"Kalba galite pakeisti rasydami:\n\n{FFFF00}/LTU {FFFFFF}- Lietuviu Kalba\n\n{FFFF00}/ENG {FFFFFF}- Anglu Kalba");
ShowPlayerDialog(playerid, 1112, DIALOG_STYLE_MSGBOX, "Welcome / Sveiki Atvyke !", long_string, "Ok", "");
This should work.
Thanks so much !! +Rep
Reply
#7

Quote:
Originally Posted by Dwane
Посмотреть сообщение
or just '\'.

[pawn]
// Examples:

"blablabla \
blablabla \
blablabla \
blablabla
"
That doesn't actually work out the error.
Reply
#8

Quote:
Originally Posted by LarzI
Посмотреть сообщение
That doesn't actually work out the error.
As I've mentioned to previous posts, it does work but not everytime when the line is extremely long.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)