SA-MP Forums Archive
isnotinbox - 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: isnotinbox (/showthread.php?tid=83512)



isnotinbox - Serediucr - 25.06.2009

is thiere a function like isnotinbox ? plz tell me


Re: isnotinbox - Correlli - 25.06.2009

http://forum.sa-mp.com/index.php?top...2304#msg622304
Here is function IsPlayerInBox. When you're going to use it, just use it like:
pawn Код:
if(!IsPlayerInBox(..



Re: isnotinbox - Serediucr - 25.06.2009

ok thx now i tried it but if i'm in box , or not , every 1 sec is give me test message!
pawn Код:
//up
forward Sumo(playerid);
//in tele
SetTimer("Sumo",1000,1);
//down
public Sumo(playerid)
{
if(!IsPlayerInBox(playerid,-391.9988,-476.2663,2553.0342,2461.8596,120.8335,160.8335)){
SendClientMessage(playerid,ORANGE,"test");
}
plz help


Re: isnotinbox - Serediucr - 25.06.2009

knows somebody?


Re: isnotinbox - Serediucr - 25.06.2009

don't like to do triple post but somebody must know


Re: isnotinbox - Correlli - 25.06.2009

Quote:
Originally Posted by Serediucr
ok thx now i tried it but if i'm in box , or not , every 1 sec is give me test message!
Of course it does, you're using every_second_timer.


Re: isnotinbox - Serediucr - 26.06.2009

Quote:
Originally Posted by Don Correlli
Quote:
Originally Posted by Serediucr
ok thx now i tried it but if i'm in box , or not , every 1 sec is give me test message!
Of course it does, you're using every_second_timer.
i want that message when i'm not in the box , but gives me everywhere!!!


Re: isnotinbox - NeRoSiS - 26.06.2009

Quote:
Originally Posted by Serediucr
Quote:
Originally Posted by Don Correlli
Quote:
Originally Posted by Serediucr
ok thx now i tried it but if i'm in box , or not , every 1 sec is give me test message!
Of course it does, you're using every_second_timer.
i want that message when i'm not in the box , but gives me everywhere!!!
Think it works the same as isplayerinarea, the XYZ have to be in the right order, something like the southern edge of the box needs to be first?


Re: isnotinbox - abhinavdabral - 26.06.2009

Lol... his Z cords are 120 to 160 ..... only if he flies, then the message will stop ... lol


Re: isnotinbox - smallo - 26.06.2009

Quote:
Originally Posted by Serediucr
ok thx now i tried it but if i'm in box , or not , every 1 sec is give me test message!
pawn Код:
//up
forward Sumo(playerid);
//in tele
SetTimer("Sumo",1000,1);
//down
public Sumo(playerid)
{
if(!IsPlayerInBox(playerid,-391.9988,-476.2663,2553.0342,2461.8596,120.8335,160.8335)){
SendClientMessage(playerid,ORANGE,"test");
}
plz help
Here you are missing a bracket

pawn Код:
//up
forward Sumo(playerid);
//in tele
SetTimer("Sumo",1000,1);
//down
public Sumo(playerid)
{
if(!IsPlayerInBox(playerid,-391.9988,-476.2663,2553.0342,2461.8596,120.8335,160.8335))
{
SendClientMessage(playerid,ORANGE,"test");
}
}