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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: IsPlayerInRangeOfPoint (
/showthread.php?tid=179330)
IsPlayerInRangeOfPoint -
Libra_PL - 26.09.2010
Heya, where should put this thing?
Code:
if(IsPlayerInRangeOfPoint(playerid, 5.0, 383.75933800,2481.53393600,15.23467800))
{
SetPlayerVelocity(playerid,-1.5,0,0.5);
}
if(IsPlayerInRangeOfPoint(playerid, 5.0, 1836.23986800,-2593.30175800,12.29717100))
{
SetPlayerVelocity(playerid,-1.5,0,0.5);
}
I'm asking, because I have put in one place and it didn't work... (checked in-game: no effect)
Re: IsPlayerInRangeOfPoint -
IstuntmanI - 26.09.2010
You must put that:
Code:
if(IsPlayerInRangeOfPoint(playerid, 5.0, 383.75933800,2481.53393600,15.23467800))
{
SetPlayerVelocity(playerid,-1.5,0,0.5);
}
if(IsPlayerInRangeOfPoint(playerid, 5.0, 1836.23986800,-2593.30175800,12.29717100))
{
SetPlayerVelocity(playerid,-1.5,0,0.5);
}
on
OnPlayerUpdate
Re: IsPlayerInRangeOfPoint -
playbox12 - 26.09.2010
No, you don't HAVE to, it would work if you do, but maybe he wants it for a command. If yes put it under the command. Maybe he wants it under OnPlayerSpawn, (which is unlikely) but you never know.
Re: IsPlayerInRangeOfPoint -
Libra_PL - 26.09.2010
No, no. Costel made a good work. It's not for a command, I wanted only make "on-foot ramps".