Error 040
#1

I've been getting this error:
Код:
C:\Documents and Settings\Luis Ramos\Desktop\Cops & Robbers\gamemodes\san_fierro.pwn(121) : error 040: duplicate "case" label (value 0)
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase
Here's my code:
Код:
public OnCheckpointEnter(playerid, checkpointid)
{
	switch(checkpointid)
	{
	  case SFPD_ENTRANCE:
	  {
			SetPlayerPos(playerid,246.3825,113.6706,1003.2188);
			SetPlayerInterior(playerid, 10);
			SendClientMessage(playerid, COLOR_MESSAGE, "Welcome to SFPD");
	  }
	  case SFPD_EXIT:
	  {
			SetPlayerPos(playerid,246.3825,113.6706,1003.2188);
			SetPlayerInterior(playerid, 0);
	  }
	}
	return 1;
}
Any help is appreciated...

Thanks,
Luisinho
Reply
#2

And how are SFPD_ENTRANCE and SFPD_EXIT defined? Do they have the same value (example: 0 or 1)?
Reply
#3

Problem solved, I forgot to change those values.

Thanks a lot!
I really appreciate your help...
Reply
#4

You're welcome.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)