pls help with stupid dialog
#1

hey guys,
can anyone pls help me with my dialog i made a nice dialog with the scripting machine and now i get this errors:


F:\program files\my own drifting gamemode\gamemodes\NYD_Drifting.pwn(105 : error 075: input line too long (after substitutions)
F:\program files\my own drifting gamemode\gamemodes\NYD_Drifting.pwn(1059) : error 037: invalid string (possibly non-terminated string)
F:\program files\my own drifting gamemode\gamemodes\NYD_Drifting.pwn(1059) : error 017: undefined symbol "this"
F:\program files\my own drifting gamemode\gamemodes\NYD_Drifting.pwn(1059) : error 017: undefined symbol "will"
F:\program files\my own drifting gamemode\gamemodes\NYD_Drifting.pwn(1059) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


5 Errors.

i made this in the scripting machine:

ShowPlayerDialog(playerid, 2, DIALOG_STYLE_LIST, "Teleports", "/drift1 this will teleport you immediately to Drift1\n/drift2 this will teleport you immediately to Drift2\n/drift3 this will teleport you immediately to Drift3\n/Driftking this teleport will bring you immediately to the DriftKing\n/stunt1 this teleport will bring you immediately to stunt1\n/stunt2 this teleport will bring you immediately to stunt2\n/stunt3 this teleport will bring you immediately to stunt3\n/AAstunt this teleport will bring you immediately to the Abandoned Airport Stunts\n/Monster this teleport will bring you immediately to the Monster Race\n/Kart this teleport will bring you immediately to the Kart Race\n/CarKiller this teleport will bring you immediately to the place where you can beast your opponent by smashing your car to his car and the one who has the car most damaged will lose XD\n/twintower this teleport will bring you immediately to the beginning of the bridge to the TwinTowerIsland\n/Derby this teleport will bring you immediately to the demolishion derby\n/Dirtcourt this teleport will bring you immediately to the dirtcourt where you can try to beat your opponent in a dirtrace\n/8track this teleport will bring you immediately to the place where you can race in a hotring racer to beat your opponent\n/dirttrack this teleport will bring you immediately to the place where you can dirt with your selected car and beat your opponent\n/drag this teleport will bring you immediately to the place where you can race with your selected car and beat your opponent\n/vortexstunt this teleport will bring you immediately to the place where you can race with your vortex\n/loco now you will go to the loco low co tuning garage in willowfield\n/arch now you will go to the wheels arch angels in west san fierro\n/lvtune now you will go to the normal tuning garage in las venturas\n/lstune now you will go to the normal tuning garage in los santos\n/sftune now you will go to the normal tuning garage in san fierro\n/lvair now you will go to las venturas airport\n/lsair now you will go to los santos airport\n/sfair now you will go to san fierro airport\n", "Ok", "Cancel");

public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
if(dialogid == 2){
if(response){
switch(listitem)){
case 0:
{
//Selected Item: "/drift1 this will teleport you immediately to Drift1"
}
case 1:
{
//Selected Item: "/drift2 this will teleport you immediately to Drift2"
}
case 2:
{
//Selected Item: "/drift3 this will teleport you immediately to Drift3"
}
case 3:
{
//Selected Item: "/Driftking this teleport will bring you immediately to the DriftKing"
}
case 4:
{
//Selected Item: "/stunt1 this teleport will bring you immediately to stunt1"
}
case 5:
{
//Selected Item: "/stunt2 this teleport will bring you immediately to stunt2"
}
case 6:
{
//Selected Item: "/stunt3 this teleport will bring you immediately to stunt3"
}
case 7:
{
//Selected Item: "/AAstunt this teleport will bring you immediately to the Abandoned Airport Stunts"
}
case 8:
{
//Selected Item: "/Monster this teleport will bring you immediately to the Monster Race"
}
case 9:
{
//Selected Item: "/Kart this teleport will bring you immediately to the Kart Race"
}
case 10:
{
//Selected Item: "/CarKiller this teleport will bring you immediately to the place where you can beast your opponent by smashing your car to his car and the one who has the car most damaged will lose XD"
}
case 11:
{
//Selected Item: "/twintower this teleport will bring you immediately to the beginning of the bridge to the TwinTowerIsland"
}
case 12:
{
//Selected Item: "/Derby this teleport will bring you immediately to the demolishion derby"
}
case 13:
{
//Selected Item: "/Dirtcourt this teleport will bring you immediately to the dirtcourt where you can try to beat your opponent in a dirtrace"
}
case 14:
{
//Selected Item: "/8track this teleport will bring you immediately to the place where you can race in a hotring racer to beat your opponent"
}
case 15:
{
//Selected Item: "/dirttrack this teleport will bring you immediately to the place where you can dirt with your selected car and beat your opponent"
}
case 16:
{
//Selected Item: "/drag this teleport will bring you immediately to the place where you can race with your selected car and beat your opponent"
}
case 17:
{
//Selected Item: "/vortexstunt this teleport will bring you immediately to the place where you can race with your vortex"
}
case 18:
{
//Selected Item: "/loco now you will go to the loco low co tuning garage in willowfield"
}
case 19:
{
//Selected Item: "/arch now you will go to the wheels arch angels in west san fierro"
}
case 20:
{
//Selected Item: "/lvtune now you will go to the normal tuning garage in las venturas"
}
case 21:
{
//Selected Item: "/lstune now you will go to the normal tuning garage in los santos"
}
case 22:
{
//Selected Item: "/sftune now you will go to the normal tuning garage in san fierro"
}
case 23:
{
//Selected Item: "/lvair now you will go to las venturas airport"
}
case 24:
{
//Selected Item: "/lsair now you will go to los santos airport"
}
case 25:
{
//Selected Item: "/sfair now you will go to san fierro airport"
}
case 26:
{
//Selected Item: ""
}
}
else{
//The player has pressed "Ok".
switch(listitem{
case 0:
{
//Selected Item: "/drift1 this will teleport you immediately to Drift1"
}
case 1:
{
//Selected Item: "/drift2 this will teleport you immediately to Drift2"
}
case 2:
{
//Selected Item: "/drift3 this will teleport you immediately to Drift3"
}
case 3:
{
//Selected Item: "/Driftking this teleport will bring you immediately to the DriftKing"
}
case 4:
{
//Selected Item: "/stunt1 this teleport will bring you immediately to stunt1"
}
case 5:
{
//Selected Item: "/stunt2 this teleport will bring you immediately to stunt2"
}
case 6:
{
//Selected Item: "/stunt3 this teleport will bring you immediately to stunt3"
}
case 7:
{
//Selected Item: "/AAstunt this teleport will bring you immediately to the Abandoned Airport Stunts"
}
case 8:
{
//Selected Item: "/Monster this teleport will bring you immediately to the Monster Race"
}
case 9:
{
//Selected Item: "/Kart this teleport will bring you immediately to the Kart Race"
}
case 10:
{
//Selected Item: "/CarKiller this teleport will bring you immediately to the place where you can beast your opponent by smashing your car to his car and the one who has the car most damaged will lose XD"
}
case 11:
{
//Selected Item: "/twintower this teleport will bring you immediately to the beginning of the bridge to the TwinTowerIsland"
}
case 12:
{
//Selected Item: "/Derby this teleport will bring you immediately to the demolishion derby"
}
case 13:
{
//Selected Item: "/Dirtcourt this teleport will bring you immediately to the dirtcourt where you can try to beat your opponent in a dirtrace"
}
case 14:
{
//Selected Item: "/8track this teleport will bring you immediately to the place where you can race in a hotring racer to beat your opponent"
}
case 15:
{
//Selected Item: "/dirttrack this teleport will bring you immediately to the place where you can dirt with your selected car and beat your opponent"
}
case 16:
{
//Selected Item: "/drag this teleport will bring you immediately to the place where you can race with your selected car and beat your opponent"
}
case 17:
{
//Selected Item: "/vortexstunt this teleport will bring you immediately to the place where you can race with your vortex"
}
case 18:
{
//Selected Item: "/loco now you will go to the loco low co tuning garage in willowfield"
}
case 19:
{
//Selected Item: "/arch now you will go to the wheels arch angels in west san fierro"
}
case 20:
{
//Selected Item: "/lvtune now you will go to the normal tuning garage in las venturas"
}
case 21:
{
//Selected Item: "/lstune now you will go to the normal tuning garage in los santos"
}
case 22:
{
//Selected Item: "/sftune now you will go to the normal tuning garage in san fierro"
}
case 23:
{
//Selected Item: "/lvair now you will go to las venturas airport"
}
case 24:
{
//Selected Item: "/lsair now you will go to los santos airport"
}
case 25:
{
//Selected Item: "/sfair now you will go to san fierro airport"
}
case 26:
{
//Selected Item: ""
}
}
}
return 0;
}

can anyone help me pls? i want to fix this because its for my own gamemode im making and i want that when you type /teles you get a dialog with the teles.

pls help
niels
Reply
#2

Show the pieces of the script where the errors are located.
Reply
#3

u mean this? wut i've edited
Reply
#4

and use [pawn] CODE [/ pawn]
Reply
#5

Because there are a lot of teles and can't put it on 1 line, I use this.
pawn Код:
new TelGeneral[][] =
{
    { "/4drag" },
    { "/aa" },
    { "/aaj" },
    { "/ammu1-11" },
    { "/bar1-2" },
    { "/baysidestunts" },
    { "/boatdock" },
    { "/bounce" },
    { "/bp" },
    { "/bs1-2" },
    { "/buildingjump" },
    { "/cage" },
    { "/garage" },
    { "/club1-3" },
    { "/cthustle" },
    { "/dedm" },
    { "/djam" },
    { "/drift1-19" },
    { "/driftschool" },
    { "/ee" },
    { "/eej" },
    { "/eij" },
    { "/islanddm" },
    { "/lsa" },
    { "/mc" },
    { "/newstunts" },
    { "/newworld" },
    { "/otto" },
    { "/parkour" },
    { "/quarry" },
    { "/rcshop" },
    { "/sfa" },
    { "/sfhall" },
    { "/skydrag" },
    { "/tf" },
    { "/tf2" },
    { "/usj" },
    { "/wa" },
    { "/wang" }

};
pawn Код:
if( !strcmp( cmdtext , "/teles" , true ) ) {
        new
            dialog[590],
            part[37]
            ;
        format( dialog , sizeof(dialog) , "{FFFFFF}%s" , TelGeneral[0] );
        for( new i = 1; i < sizeof( TelGeneral ); i++ ) {
            format( part , sizeof(part) , "\n%s" , TelGeneral[i] );
            strcat( dialog , part , sizeof(dialog) );
        }
        printf( "[string check] dialog length %d ( size %d )" , strlen( dialog ) , sizeof(dialog) );
// use this to check that the size of dialog is sufficient

        ShowPlayerDialog( playerid , 6 , DIALOG_STYLE_LIST , "Teleports" , dialog , "Teleport" , "Cancel" );
        return 1;
    }
pawn Код:
if(dialogid == 6) {
        if(response) {
            if(listitem == 0) {
                RemovePlayerFromVehicle(playerid);
                ResetPlayerWeapons(playerid);
                SetPlayerPos(playerid,x,y,z);
                GameTextForPlayer(playerid,"",4000,6);
            }
Also, use [pawn]
Reply
#6

yeah but how that works? everytime when i put my msg in the [/pawn] it doesnt works like i do this ??

EDIT wait i understand i think wait let me try it out XD
Reply
#7

nopes doesnt works all of errors
Reply
#8

At the end use [/pawn] and at start [pawn], [pawn]..[/ pawn] > remove the space between "/ p"
Show me the errors
Reply
#9

wut errors u mean? i edited the errors on top
Reply
#10

Ddue, try it like I said
Because there are a lot of teles and can't put it on 1 line, I use this.
pawn Код:
new TelGeneral[][] =
{
    { "/4drag" },
    { "/aa" },
    { "/aaj" },
    { "/ammu1-11" },
    { "/bar1-2" },
    { "/baysidestunts" },
    { "/boatdock" },
    { "/bounce" },
    { "/bp" },
    { "/bs1-2" },
    { "/buildingjump" },
    { "/cage" },
    { "/garage" },
    { "/club1-3" },
    { "/cthustle" },
    { "/dedm" },
    { "/djam" },
    { "/drift1-19" },
    { "/driftschool" },
    { "/ee" },
    { "/eej" },
    { "/eij" },
    { "/islanddm" },
    { "/lsa" },
    { "/mc" },
    { "/newstunts" },
    { "/newworld" },
    { "/otto" },
    { "/parkour" },
    { "/quarry" },
    { "/rcshop" },
    { "/sfa" },
    { "/sfhall" },
    { "/skydrag" },
    { "/tf" },
    { "/tf2" },
    { "/usj" },
    { "/wa" },
    { "/wang" }

};
pawn Код:
if( !strcmp( cmdtext , "/teles" , true ) ) {
        new
            dialog[590],
            part[37]
            ;
        format( dialog , sizeof(dialog) , "{FFFFFF}%s" , TelGeneral[0] );
        for( new i = 1; i < sizeof( TelGeneral ); i++ ) {
            format( part , sizeof(part) , "\n%s" , TelGeneral[i] );
            strcat( dialog , part , sizeof(dialog) );
        }
        printf( "[string check] dialog length %d ( size %d )" , strlen( dialog ) , sizeof(dialog) );
// use this to check that the size of dialog is sufficient

        ShowPlayerDialog( playerid , 6 , DIALOG_STYLE_LIST , "Teleports" , dialog , "Teleport" , "Cancel" );
        return 1;
    }
pawn Код:
if(dialogid == 6) {
        if(response) {
            if(listitem == 0) {
                RemovePlayerFromVehicle(playerid);
                ResetPlayerWeapons(playerid);
                SetPlayerPos(playerid,x,y,z);
                GameTextForPlayer(playerid,"",4000,6);
            }
It works perfect to me. Change the teles to yours
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)