[HELP] What's wrong with this code? 'bout a message box
#1

I personally think nothing's wrong but i think pawn overdrives and makes fake errors becouse in an fs it works
pawn Код:
if(strcmp(cmd, "/rules", true) == 0)
    {
    ShowPlayerDialog(playerid,3,DIALOG_STYLE_MSGBOX,"Do you accept our rules?","1 We want you to behave like in real life.\n2 Talk normally or you can get kicked/banned.\n3 Cheating or bug abusing results in a ban, also try /abusehelp\n4 Respect eachother and respect the admins, also try /abusehelp\n5 Spawnkilling and driveover kills aren't allowed.\n6 Use English or Dutch in any the mainchat.\n7 Advertising is allowed but if you're advertising a bad site it's a ban.\nFollow this rules and nothing will happen to you.","Accept","Decline");
        return 1;
    }
Reply
#2

Quote:
Originally Posted by WThieves
I personally think nothing's wrong but i think pawn overdrives and makes fake errors becouse in an fs it works
pawn Код:
if(strcmp(cmd, "/rules", true) == 0)
    {
    ShowPlayerDialog(playerid,3,DIALOG_STYLE_MSGBOX,"Do you accept our rules?","1 We want you to behave like in real life.\n2 Talk normally or you can get kicked/banned.\n3 Cheating or bug abusing results in a ban, also try /abusehelp\n4 Respect eachother and respect the admins, also try /abusehelp\n5 Spawnkilling and driveover kills aren't allowed.\n6 Use English or Dutch in any the mainchat.\n7 Advertising is allowed but if you're advertising a bad site it's a ban.\nFollow this rules and nothing will happen to you.","Accept","Decline");
        return 1;
    }
What errors do you get, post the errors plus the line
Reply
#3

pawn Код:
this is 22467    if(strcmp(cmd, "/rules", true) == 0)
    this is 22468   {
    this is 22469    ShowPlayerDialog(playerid,3,DIALOG_STYLE_MSGBOX,"Do you accept our rules?","1 We want you to behave like in real life.\n2 Talk normally or you can get kicked/banned.\n3 Cheating or bug abusing results in a ban, also try /abusehelp\n4 Respect eachother and respect the admins, also try /abusehelp\n5 Spawnkilling and driveover kills aren't allowed.\n6 Use English or Dutch in any the mainchat.\n7 Advertising is allowed but if you're advertising a bad site it's a ban.\nFollow this rules and nothing will happen to you.","Accept","Decline");
        return 1;
    }
gamemodes\****.pwn(2246 : error 075: input line too long (after substitutions)
gamemodes\****.pwn(22469) : error 037: invalid string (possibly non-terminated string)
gamemodes\****.pwn(22469) : warning 215: expression has no effect
gamemodes\****.pwn(22469) : error 001: expected token: ";", but found "-identifier-"
gamemodes\****.pwn(22469) : error 017: undefined symbol "We"
gamemodes\****.pwn(22469) : fatal error 107: too many error messages on one line
Reply
#4

please help me
Reply
#5

Use '\' when your strings getting large..

Код:
if(!strcmp(cmdtext, "/rules", true))
{
    ShowPlayerDialog(playerid, 3, DIALOG_STYLE_MSGBOX, "Do you accept our rules?",
	"\
	1 We want you to behave like in real life.\n\
	2 Talk normally or you can get kicked/banned.\n\
	3 Cheating or bug abusing results in a ban, also try /abusehelp\n\
	4 Respect eachother and respect the admins, also try /abusehelp\n\
	5 Spawnkilling and driveover kills aren't allowed.\n\
	6 Use English or Dutch in any the mainchat.\n\
	7 Advertising is allowed but if you're advertising a bad site it's a ban.\n\
	Follow this rules and nothing will happen to you.", "Accept", "Decline");
	return 1;
}
Works fine for me.
(Learn to indentitate your codes)
Reply
#6

Quote:
Originally Posted by » RyDeR «
Use '\' when your strings getting large..

Код:
if(!strcmp(cmdtext, "/rules", true))
{
    ShowPlayerDialog(playerid, 3, DIALOG_STYLE_MSGBOX, "Do you accept our rules?",
	"\
	1 We want you to behave like in real life.\n\
	2 Talk normally or you can get kicked/banned.\n\
	3 Cheating or bug abusing results in a ban, also try /abusehelp\n\
	4 Respect eachother and respect the admins, also try /abusehelp\n\
	5 Spawnkilling and driveover kills aren't allowed.\n\
	6 Use English or Dutch in any the mainchat.\n\
	7 Advertising is allowed but if you're advertising a bad site it's a ban.\n\
	Follow this rules and nothing will happen to you.", "Accept", "Decline");
	return 1;
}
Works fine for me.
(Learn to indentitate your codes)
I've been using pawno for years but never knew this thanks man you're a lifesaver!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)