Dialog problem /cars
#1

Hi, guys, i'm From Romanian so sorry for my bad english !

My problem is:
I make a dialog comand when a player type /cars to show a dialog with some otions ( lock / park / spawn etc)

But you know every time is a problem !
I take some Errors

The Dialog :

Код:
if(dialogid == 8765)// dialog masini
  {
  new query[ 4048 ];
  new carid[ 4049 ];
  new text[ 4050 ];

  if(!response)
            {
                SendClientMessage(playerid, 0xFF0000FF, "Ai anulat.");
                return 1; // We processed it
            }
  switch(listitem)
            {
  case 0:
                {
  new text[512];
  format(text, sizeof(text),"Lock\nAlege chei\n", "Alege", "Anulare");
  ShowPlayerDialog(playerid,8766,DIALOG_STYLE_LIST, "Slot 1:", text, "Alege","Anulare");
  }
  case 1:
                {
  new text[512];
  format(text, sizeof(text),"Lock\nAlege chei\n", "Alege", "Anulare");
  ShowPlayerDialog(playerid,8767,DIALOG_STYLE_LIST, "Slot 2:", text, "Alege","Anulare");
  }
  case 2:
                {
  ShowPlayerDialog(playerid, 8768, DIALOG_STYLE_LIST, "Slot 3:", "Lock\nAlege chei\n", "Alege", "Anulare");
  }
  }
  }
  if((dialogid == 8766) || (dialogid == 8767) || (dialogid == 8768))
  {
  if(!response)
            {
                SendClientMessage(playerid, 0xFF0000FF, "Ai anulat.");
                return 1; // We processed it
            }
  if(dialogid == 8766)
  {
  if(PlayerData[playerid][pPcarkey] == 999)
  {
  SendClientMessage(playerid, 0xFF0000FF, "Nu ai o masina pe acest slot.");
  return 1; // We processed it
  }
  switch(listitem)
  {
                case 0:
                {
  new query[128];
     if(SwitchKey[playerid] == 1)
     {
     new carid = PlayerData[playerid][pPcarkey];
     if(CarData[carid][cLockk] == 0)
     {
      SendClientMessage(playerid, COLOR_GRAD1, "Masina personala a fost incuiata.");
  PlayerPlaySound(playerid, 1145, 0.0, 0.0, 0.0);
  CarData[carid][cLockk] = 1;
  VehLocked[carid+PreVehicle] = 1;
  GetVehicleParamsEx(carid+PreVehicle,engine,lights,alarm,doors,bonnet,boot,objective);
  SetVehicleParamsEx(carid+PreVehicle,engine,lights,alarm,1,bonnet,boot,objective);
  format(query, sizeof(query), "UPDATE cars SET Lockk='%d' WHERE id=%d",CarData[carid][cLockk], carid);
  mysql_query(query);
         return 1;
  }
  else
  {
     SendClientMessage(playerid, COLOR_GRAD1, "Masina personala a fost descuiata.");
  PlayerPlaySound(playerid, 1145, 0.0, 0.0, 0.0);
     CarData[carid][cLockk] = 0;
     VehLocked[carid+PreVehicle] = 0;
  GetVehicleParamsEx(carid+PreVehicle,engine,lights,alarm,doors,bonnet,boot,objective);
  SetVehicleParamsEx(carid+PreVehicle,engine,lights,alarm,0,bonnet,boot,objective);
  format(query, sizeof(query), "UPDATE cars SET Lockk='%d' WHERE id=%d", CarData[carid][cLockk], carid);
  mysql_query(query);
         return 1;
  }
  }
  }
  case 1:
                {
  if(PlayerData[playerid][pPcarkey] != 999 && PlayerData[playerid][pPcarkey] != 0)
  {
     SwitchKey[playerid] = 1;
  SendClientMessage(playerid, COLOR_GRAD1, "Acum controlezi masina personala");
  return 1;
  }
  else
  {
     SendClientMessage(playerid, COLOR_GRAD1, "Server: Nu detii masina personala!");
     SwitchKey[playerid] = 1;
  return 1;
  }
                }
  }
  }
  }
And the Errors :

Код:
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20599) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20605) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20608) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20610) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20612) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20615) : error 021: symbol already defined: "format"
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20618) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20621) : error 021: symbol already defined: "format"
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20624) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20630) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20632) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20635) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20637) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20639) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20642) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20644) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20646) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20649) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20652) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20662) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20664) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20674) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20678) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20680) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20684) : error 010: invalid function or declaration
C:\Documents and Settings\John\Desktop\RealGaming\SERVER\gamemodes\RealGaming.pwn(20686) : error 010: invalid function or declaration

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


26 Errors.

PSL HELP ME! I give +Rep
Reply


Messages In This Thread
Dialog problem /cars - by Sn4ke2 - 19.01.2015, 19:48
Re: Dialog problem /cars - by Sn4ke2 - 20.01.2015, 12:44
Re: Dialog problem /cars - by xVIP3Rx - 20.01.2015, 12:57
Re: Dialog problem /cars - by PowerPC603 - 20.01.2015, 13:22
Re: Dialog problem /cars - by Sn4ke2 - 20.01.2015, 13:25
Re: Dialog problem /cars - by Sn4ke2 - 20.01.2015, 14:29
Re: Dialog problem /cars - by PMH - 20.01.2015, 14:30
Re: Dialog problem /cars - by Sn4ke2 - 20.01.2015, 14:36
Re: Dialog problem /cars - by Sn4ke2 - 20.01.2015, 15:55
Re: Dialog problem /cars - by xVIP3Rx - 20.01.2015, 15:59

Forum Jump:


Users browsing this thread: 1 Guest(s)