SA-MP Forums Archive
Help me with PlayerToPoint - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Help me with PlayerToPoint (/showthread.php?tid=77877)



Help me with PlayerToPoint - Derksen123 - 15.05.2009

whats wrong with this it dont gives error but it dont work?
Code:
if(PlayerToPoint(25.0,playerid,-415.2488,-3146.3875,4.5154) || PlayerToPoint(25.0,playerid,-417.1043,-3153.9048,47.0001))
   {//vuur
     return 1;

look this is the place where i need to enter:
 AddPlayerClass(270,-415.2488,-3146.3875,4.5154,174.1317,0,0,0,0,0,0); // vuurtoren
if im entered i need to go to this place:
AddPlayerClass(297,-417.1043,-3153.9048,47.0001,165.6255,0,0,0,0,0,0); // vuurtorenboven

and if im at that place where i need to enter nothing happins



Re: Help me with PlayerToPoint - OmeRinG - 15.05.2009

What do you mean it doesn't work?
All I see is If returning 1 that doesn't do anything.


Re: Help me with PlayerToPoint - Derksen123 - 15.05.2009


if(PlayerToPoint(25.0,playerid,-415.2488,-3146.3875,4.5154) || PlayerToPoint(25.0,playerid,-417.1043,-3153.9048,47.0001))
{//vuur
return 1;

look this is the place where i need to enter:
AddPlayerClass(270,-415.2488,-3146.3875,4.5154,174.1317,0,0,0,0,0,0); // vuurtoren
if im entered i need to go to this place:
AddPlayerClass(297,-417.1043,-3153.9048,47.0001,165.6255,0,0,0,0,0,0); // vuurtorenboven

and if im at that place where i need to enter nothing happins


Re: Help me with PlayerToPoint - OmeRinG - 15.05.2009

show me the full code after if(playertopoint


Re: Help me with PlayerToPoint - MenaceX^ - 15.05.2009

Which errors does it give?


Re: Help me with PlayerToPoint - Derksen123 - 15.05.2009

it dont give a error but nothing happens if im at the place


Re: Help me with PlayerToPoint - Correlli - 15.05.2009

Quote:
Originally Posted by MenaceX^
Which errors does it give?
It doesn't give any errors he said.

@Derksen123: show us your PlayerToPoint.


Re: Help me with PlayerToPoint - Derksen123 - 15.05.2009

Code:
public IsAtClothShop(playerid)
{
  if(IsPlayerConnected(playerid))
 {
	if(PlayerToPoint(25.0,playerid,-415.2488,-3146.3875,4.5154) || PlayerToPoint(25.0,playerid,-417.1043,-3153.9048,47.0001)) THIS IS THE ONE THAT DON't WORK
		{//vuur
		  return 1;
		}
    else if(PlayerToPoint(25.0,playerid,20.5627,-103.7291,1005.2578) || PlayerToPoint(25.0,playerid,203.9068,-41.0728,1001.8047))
		{//Binco & Suburban
		  return 1;
		}
		else if(PlayerToPoint(30.0,playerid,214.4470,-7.6471,1001.2109) || PlayerToPoint(50.0,playerid,161.3765,-83.8416,1001.8047))
		{//Zip & Victim
		  return 1;
		}
	}
	return 0;
}
look this is the place where i need to enter:
AddPlayerClass(270,-415.2488,-3146.3875,4.5154,174.1317,0,0,0,0,0,0); // vuurtoren
if im entered i need to go to this place:
AddPlayerClass(297,-417.1043,-3153.9048,47.0001,165.6255,0,0,0,0,0,0); // vuurtorenboven

and if im at that place where i need to enter nothing happins


Re: Help me with PlayerToPoint - Correlli - 15.05.2009

Derksen123, i meant the functions code.


Re: Help me with PlayerToPoint - Derksen123 - 15.05.2009

Quote:
Originally Posted by Don Correlli
Derksen123, i meant the functions code.
you mean the saved code ??