Help - 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 (
/showthread.php?tid=162965)
Help -
WillyP - 25.07.2010
I cant seem to get my IsPlayerInRangeOfPoint function working
can someone possibly give me a example code with it built in? i tried wiki and inserted it, no difference :L
thx
Re: Help -
bartje01 - 25.07.2010
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 2.0, X, Y, Z))
{
//what happens if you are in range
}
else
{
// what happens if you don't are in range
}
There ya go lolrolf
Re: Help -
V1ceC1ty - 25.07.2010
pawn Код:
#define PRESSED(%0) \
(((newkeys & (%0)) == (%0)) && ((oldkeys & (%0)) != (%0)))
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if (PRESSED(KEY_CROUCH))
{
if(IsPlayerInRangeOfPoint(playerid, 2.0, X, Y, Z))
{
//do something, like gates?
}
return 1;
}
return 1;
}
Re: Help -
WillyP - 25.07.2010
Quote:
Originally Posted by bartje01
pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 2.0, X, Y, Z)) { //what happens if you are in range } else { // what happens if you don't are in range }
There ya go lolrolf
|
yu are THE MAN