error 001: expected token: ",", but found "case"
#1

I'm lost

I've got those errors:

C:\BSL\BSL 2.1\gamemodes\BSL2.pwn(18368 -- 18369) : error 001: expected token: ",", but found "case"
C:\BSL\BSL 2.1\gamemodes\BSL2.pwn(18369) : error 014: invalid statement; not in switch
C:\BSL\BSL 2.1\gamemodes\BSL2.pwn(18369) : warning 215: expression has no effect
C:\BSL\BSL 2.1\gamemodes\BSL2.pwn(18369) : error 001: expected token: ";", but found ":"
C:\BSL\BSL 2.1\gamemodes\BSL2.pwn(18369) : fatal error 107: too many error messages on one line


lines 18368 and 18369:

PHP код:
            case 7NikoGPSEntretenimento()
            case 
8NikoGPSEmpresas() 
the define's


PHP код:
#define NikoGPSEntretenimento() { new gpsEntretenimento[] = "1.\tCorrida de Vacas\n2.\tPuteiro\n3.\tCasa Noturna\n4.\tBoliche\n5.\tBalada\n6.\tBarzinho\n7.\tSex Shop\n8.\t8 Ball\n9.\tRally\n10.\tStunt"; ShowPlayerDialog(playerid,DIALOG_GPS_ENTRETENIMENTO, DIALOG_STYLE_LIST,"{00ff00}G.P.S. {ff0000}BSL{00ff00} Entretenimento:",gpsEntretenimento,"Selecionar","Voltar"); }
#define NikoGPSEmpresas() { new gpsEmpresas[] = "1.\tAluguel de Motos\n2.\tAluguel de Carros\n3.\tEmpresa de Telefonia\n4.\tCentral dos Postos\n5.\tEnergia Elйtrica\n6.\tTransportadora\n7.\tAtualizaзхes\n8.\tAnъncios\n9.\tMecвnico\n10.\tLojas 24/7\n11.\tPaintball\n12.\tKart\n13.\tБgua\n14.\tConcessionбria\n15.\tHospital\n16.\tPay and Spray\n17.\tSprunk\n18.\tAuto-Escola\n19.\tLoja Binco\n20.\tPedбgio\n21.\tBar\n22.\tRestaurante\n23.\tLotйrica\n24.\tCorrida de Vacas\n25.\tTunning\n26.\tArmas Norte\n27.\tArmas Sul"; ShowPlayerDialog(playerid,DIALOG_GPS_EMPRESAS, DIALOG_STYLE_LIST,"{00ff00}G.P.S. {ff0000}BSL{00ff00} Empresas:",gpsEmpresas,"Selecionar","Voltar"); } 
any Idea?
Reply
#2

pawn Код:
switch ( <variable> ) {
case this-value:
  Code to execute if <variable> == this-value
  break;
case that-value:
  Code to execute if <variable> == that-value
  break;
...
default:
  Code to execute if <variable> does not equal the value following any of the cases
  break;
}
Function cannot be used and colon should be placed at the end.
Reply
#3

I'm not using a function
it is a directive...

and if you read it, you can see there is colon.
Reply
#4

Quote:
Originally Posted by dudaefj
Посмотреть сообщение
I'm not using a function
it is a directive...

and if you read it, you can see there is colon.
Quote:
Function cannot be used and colon should be placed at the end.

4char
Reply
#5

where "function cannot be used"?
Reply
#6

pawn Код:
case 7: NikoGPSEntretenimento() ;
            case 8: NikoGPSEmpresas();
Reply
#7

lol double post ? Stupid internet
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)