SA-MP Forums Archive
Is in interval - 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)
+--- Thread: Is in interval (/showthread.php?tid=619887)



Is in interval - MerryDeer - 23.10.2016

Hi,

I'am getting player position and then compare after second, it's for afk system, but i want to check not only if excatly == pos == oldpos, but position could by in range off


Re: Is in interval - Spmn - 23.10.2016

floatabs(pos-oldpos) < max_difference

or just use IsPlayerInRangeOfPoint