SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help > Help Archive

 
 
Thread Tools Display Modes
Old 28/11/2009, 01:51 PM   #1
addmion
Little Clucker
 
Join Date: Nov 2009
Posts: 2
Reputation: 0
Default error 004: function "PlayerToPoint" is not implemented

Code:
F:\GF3.pwn(4656) : error 004: function "PlayerToPoint" is not implemented
F:\GF3.pwn(4660) : error 004: function "PlayerToPoint" is not implemented
F:\GF3.pwn(4725) : error 004: function "PlayerToPoint" is not implemented
F:\GF3.pwn(4729) : error 004: function "PlayerToPoint" is not implemented
F:\GF3.pwn(4741) : error 004: function "PlayerToPoint" is not implemented
Code:
4660:else if(PlayerToPoint(40,playerid,2126.457519,-1152.129272,23.869300)||PlayerToPoint(40,playerid,1054.454345,-909.379272,42.562801)||PlayerToPoint(40,playerid,1623.161132,-1896.359497,13.122594))
Code:
4725:if(PlayerToPoint(25.0,playerid,207.5627,-103.7291,1005.2578) || PlayerToPoint(25.0,playerid,203.9068,-41.0728,1001.8047))
Code:
4729:else if(PlayerToPoint(30.0,playerid,214.4470,-7.6471,1001.2109) || PlayerToPoint(50.0,playerid,161.3765,-83.8416,1001.8047))
Code:
4741:if(PlayerToPoint(6.2, playerid, 326.8956,186.0858,1014.1875) || PlayerToPoint(6.0,playerid,374.1812,191.2544,1014.1875) || PlayerToPoint(5.2,playerid,327.7716,153.3677,1014.1875))
addmion is offline  
Old 28/11/2009, 01:54 PM   #2
Remi-X
Huge Clucker
 
Join Date: Dec 2008
Posts: 296
Reputation: 0
Default Re: error 004: function "PlayerToPoint" is not implemented

Better to use IsPlayerInRangeOf, since SA:MP 0.3a is out.
Remi-X is offline  
Old 28/11/2009, 01:57 PM   #3
Correlli
Godfather
 
Correlli's Avatar
 
Join Date: May 2009
Location: Slovenia
Posts: 6,340
Reputation: 365
Default Re: error 004: function "PlayerToPoint" is not implemented

Make sure you have PlayerToPoint function in your script or just do as Remi-X told you.
Correlli is offline  
Old 28/11/2009, 02:11 PM   #4
Luka P.
High-roller
 
Join Date: Feb 2009
Posts: 1,428
Reputation: 13
Default Re: error 004: function "PlayerToPoint" is not implemented

Copy this at bottom of your script
pawn Code:
PlayerToPoint(Float:radius, playerid, Float:X, Float:Y, Float:Z)
{
  new Float:oldpos[3], Float:temppos[3];
  GetPlayerPos(playerid, oldpos[0], oldpos[1], oldpos[2]);
  temppos[0] = (oldpos[0] -X);
  temppos[1] = (oldpos[1] -Y);
  temppos[2] = (oldpos[2] -Z);
  if(((temppos[0] < radius) && (temppos[0] > -radius)) && ((temppos[1] < radius) && (temppos[1] > -radius)) && ((temppos[2] < radius) && (temppos[2] > -radius)))
  {
    return true;
  }
  return false;
}
Luka P. is offline  
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Run time error 19: "File or function is not found" TouR Help Archive 2 18/06/2010 10:04 AM
error 004: function "PlayerToPoint" is not implemented - HELP CaliforniaRP Help Archive 3 04/04/2010 08:13 PM
error 004: function "LoadHouseCars" is not implemented Keeboo13 Help Archive 8 17/02/2010 12:32 AM
error 004: function "PlayerToPoint" is not implemented? braduz Help Archive 2 10/01/2010 08:15 PM
error 004: function "FixHour" is not implemented buonggiorno Help Archive 7 25/11/2009 09:17 PM


All times are GMT. The time now is 11:34 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.