Spy Error Onplayerdialog
#1

pawn Код:
////////SPY Disguise Dialog SPYKIT
{
    if(dialogid == SPYKIT)
    {
       if(respose)//enter or pressing Disguise
         {
         if(listitem == 0)
            {
         SentClientMessage(playerid, COLOR_GREY, "[SERVER] {FFFFFF} Successfully Disguised as Team USA");
         SetPlayerSkin(playerid, 287);
         SetPlayerColor(playerid, COLOR_LIGHTBLUE)
             }
             return 1;
           }
     }
return true;
}
This was my 2 command on OnDialogResponse and i started it like this stated above


K so i made a cmd which would show dialog that if you are a spy then u can disguise as other teams and i listed those teams.
Till this i had no errors.

When i wanted to make listitem 0 ONplayerdialog reponse i got errors idk

D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(484) : error 055: start of function body without function header
D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(485) : error 010: invalid function or declaration
D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(487) : error 010: invalid function or declaration
D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(489) : error 010: invalid function or declaration
D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(492) : error 021: symbol already defined: "SetPlayerSkin"
D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(495) : error 010: invalid function or declaration
D:\SAMP STUFF\SAMP HOST\gamemodes\Test.pwn(49 : error 010: invalid function or declaration
Reply
#2

Bump
zzzz
Reply
#3

If you would indent your code properly, you would find some missing brackets.
Reply
#4

Give us your whole OnDialogResponse.

It will be much easier to help you.
Reply
#5

pawn Код:
// There was a bracket here, it's gone now
    if(dialogid == SPYKIT)
    {
       if(respose)//enter or pressing Disguise
         {
         if(listitem == 0)
            {
         SentClientMessage(playerid, COLOR_GREY, "[SERVER] {FFFFFF} Successfully Disguised as Team USA");
         SetPlayerSkin(playerid, 287);
         SetPlayerColor(playerid, COLOR_LIGHTBLUE)
             }
             return 1;
           }
     }
//There was a return and a unneeded bracket here, they're gone too now
And as BigETI said, please, for the love of pawn, indent your code!
Reply
#6

NVM i had closed the whole onplayerdialog response bracket "}" and i added return true after my 2 command on Dialogresponse NVM i solved it myself
thanks for your attention though
~Regards
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)