SA-MP Forums Archive
Help !! "isplayerinrangeofpoint" - 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)
+--- Thread: Help !! "isplayerinrangeofpoint" (/showthread.php?tid=584371)



Help !! "isplayerinrangeofpoint" - Remy0 - 04.08.2015

When im trying to compile a something it gives me that error

Код:
C:\Users\Hassan\Desktop\dd.pwn(353) : error 017: undefined symbol "playerid"
C:\Users\Hassan\Desktop\dd.pwn(355) : error 017: undefined symbol "playerid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
And This is the code

Код:
public EnterExit()
{
	if(IsPlayerInRangeOfPoint(playerid, 3.0, 2287.0161, 2432.0356, 10.0835)
	{
		SetPlayerPos(playerid,238.6965, 139.0925, 1002.7668);
	}
	return 1;
}



Re: Help !! "isplayerinrangeofpoint" - Emmet_ - 04.08.2015

There appears to be a missing bracket at the end of that conditional statement. This would be appropriate instead:

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 3.0, 2287.0161, 2432.0356, 10.0835))



Re: Help !! "isplayerinrangeofpoint" - Remy0 - 04.08.2015

Same Error !!

Anyone can help me


Re: Help !! "isplayerinrangeofpoint" - Nixtren - 04.08.2015

Also, the function "EnterExit" doesn't have any parameter called "playerid", you should correct to this:
Код:
public EnterExit(playerid)
Edit: RIDE2DAY said it first :P


Re: Help !! "isplayerinrangeofpoint" - Remy0 - 04.08.2015

Quote:
Originally Posted by Nixtren
Посмотреть сообщение
Also, the function "EnterExit" doesn't have any parameter called "playerid", you should correct to this:
Код:
public EnterExit(playerid)
Edit: RIDE2DAY said it first :P
New Errors

Код:
C:\Users\Hassan\Desktop\dd.pwn(351) : error 025: function heading differs from prototype
C:\Users\Hassan\Desktop\dd.pwn(354) : error 001: expected token: ")", but found "{"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Код:
public EnterExit(playerid)
{
	if(IsPlayerInRangeOfPoint(playerid, 3.0, 2287.0161, 2432.0356, 10.0835)
	{
		SetPlayerPos(playerid,238.6965, 139.0925, 1002.7668);
	}
	return 1;
}



Re: Help !! "isplayerinrangeofpoint" - Luis- - 04.08.2015

Take a look at Emmets post, that'll fix the new errors.


Re: Help !! "isplayerinrangeofpoint" - Nixtren - 04.08.2015

In line 351 replace EnterExit() with EnterExit(playerid). You should post here the lines 350-355 by the way, because you probably have another error in your script that is not directly related to this one.


Re: Help !! "isplayerinrangeofpoint" - Remy0 - 04.08.2015

1 error fixed

how i fix this
Код:
C:\Users\Hassan\Desktop\dd.pwn(351) : error 025: function heading differs from prototype
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
Code :

Код:
public EnterExit(playerid)
{
	if(IsPlayerInRangeOfPoint(playerid, 3.0, 2287.0161, 2432.0356, 10.0835))
	{
		SetPlayerPos(playerid,238.6965, 139.0925, 1002.7668);
	}
	return 1;
}



Re: Help !! "isplayerinrangeofpoint" - Nixtren - 04.08.2015

Quote:
Originally Posted by Remy0
Посмотреть сообщение
1 error fixed

how i fix this

C:\Users\Hassan\Desktop\dd.pwn(351) : error 025: function heading differs from prototype
Quote:
Originally Posted by Nixtren
Посмотреть сообщение
In line 351 replace EnterExit() with EnterExit(playerid).
Did you do that?


Re: Help !! "isplayerinrangeofpoint" - Luis- - 04.08.2015

You need to add 'playerid' to your
pawn Код:
forward EnterExit();