Error [REP+]
#1

Hey, I am getting this error

Код:
error 040: duplicate "case" label (value 20016)
My script

Код:
		case DIALOG_AMMU:
		{
  			switch(listitem)
    		{
    			case 0:
    			{
    			    GivePlayerWeapon(playerid, 25, 99999);  // Shotgun
				}
				case 1:
				{
        			GivePlayerWeapon(playerid, 26, 99999);  // Sawn-Off
				}
				case 2:
				{
				    GivePlayerWeapon(playerid, 27, 99999);  // Combat Shotgun
				}
			}
		}
Any idea on how to fix it?
Reply
#2

Specify the line
Mean while check this
pawn Код:
case DIALOG_AMMU:
if you have it twice in

pawn Код:
OnDialogResponse
Reply
#3

Quote:
Originally Posted by gurmani11
Посмотреть сообщение
Specify the line
Mean while check this
pawn Код:
case DIALOG_AMMU:
if you have it twice in

pawn Код:
OnDialogResponse
I checked it many times and its nothing found
Reply
#4

You have two or more values within "switch(dialogid)" that possess the value of 20,016.

For example:
pawn Код:
#define DIALOG_AMMU 20016
#define DIALOG_CLICKIN 20016
Reply
#5

Quote:
Originally Posted by SickAttack
Посмотреть сообщение
You have two or more values within "switch(dialogid)" that possess the value of 20,016.

For example:
pawn Код:
#define DIALOG_AMMU 20016
#define DIALOG_CLICKIN 20016
Oh thats it, thanks I forgot to change it when I copied the defines
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)