(HELP) Chracter is too far away - 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) Chracter is too far away (
/showthread.php?tid=269066)
(HELP) Chracter is too far away -
spaty2 - 14.07.2011
How to make script that will say character is too far away, if he will? please?
Re: (HELP) Chracter is too far away -
[MG]Dimi - 14.07.2011
PHP код:
IsPlayerInRangeOfPoint(playerid,radius,x,y,z);
Re: (HELP) Chracter is too far away -
Flyfishes - 14.07.2011
IsPlayerInRangeOfPlayer is your friend.
Re: (HELP) Chracter is too far away -
Toreno - 14.07.2011
It's an example of a command.
pawn Код:
CMD:check(playerid, params[]) {
if(!IsPlayerInRangeOfPoint(playerid, radius, x,y,z)) return SendClintMessage(playerid, -1, "You are not near the POSITION!"); // Change X, Y, Z, RADIUS.
// Do whatever you want to open when he is close.
return 1;
}
Re: (HELP) Chracter is too far away -
spaty2 - 14.07.2011
Thanks, but this is not what i need..
Re: (HELP) Chracter is too far away -
Skylar Paul - 14.07.2011
pawn Код:
new Float:Position[3];
GetPlayerPos(PersonWhoYourTooFarAwayFrom, Position[0], Position[1], Position[2]);
if(!IsPlayerinRangeOfPoint(playerid, 30, Position[0], Position[1], Position[2])) return SendClientMessage(playerid, -1, "You're too far away!");
else
{
//your code
}
Is that what you're looking for?
Re: (HELP) Chracter is too far away -
spaty2 - 14.07.2011
Quote:
CarLicenses.pwn(299) : error 029: invalid expression, assumed zero
CarLicenses.pwn(299) : warning 215: expression has no effect
CarLicenses.pwn(299) : warning 215: expression has no effect
CarLicenses.pwn(299) : warning 215: expression has no effect
CarLicenses.pwn(299) : error 001: expected token: ";", but found ")"
CarLicenses.pwn(299) : error 029: invalid expression, assumed zero
CarLicenses.pwn(299) : fatal error 107: too many error messages on one line
|
This errors i get