SA-MP Forums Archive
Function doesn't work - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Function doesn't work (/showthread.php?tid=224909)



Function doesn't work - pantelimonfl - 12.02.2011

I have the mdcplate function but it doesn't work. I type the plate and it says only that the car is not legalized.
pawn Код:
if(dialogid == DIALOG_MDCPLATE)
        {
            new string[256], string2[256];
            for(new i; i<MAX_VEHICLES; i++)
            {
                if(strcmp(CarInfo[i][cPlate], inputtext, true)== 0)
                {
                    if(CarInfo[i][cLicense] == 1)
                    {
                        format(string2, sizeof(string2), "Legalized");
                    }
                    else
                    {
                        format(string2, sizeof(string2), "Not legalized");
                    }
                    format(string, sizeof(string), "Car Plate: %s\nModel:%s\nLegal Status: %s\nOwner : %s",CarInfo[i][cPlate],CarInfo[i][cDescription], string2, CarInfo[i][cOwner]);
                    ShowPlayerDialog(playerid,99,DIALOG_STYLE_MSGBOX,"Car Info",string,"Ok","");
                    return 1;
                }
            }
            ShowPlayerDialog(playerid,99,DIALOG_STYLE_MSGBOX,"Unsuccessfull search:","No vehicle found!","Ok","");
        }



Re: Function doesn't work - pantelimonfl - 13.02.2011

Up...


Re: Function doesn't work - pantelimonfl - 14.02.2011

up...