Spawning vehicles and weapons detection - 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: Spawning vehicles and weapons detection (
/showthread.php?tid=269105)
Spawning vehicles and weapons detection -
cloudysky - 14.07.2011
Hi, I need to know how to stop people from spawning weapons and vehicles who are not admins. I'm not sure on how to go about doing it some can anyone help?
Re: Spawning vehicles and weapons detection -
whitedragon - 14.07.2011
Like Command or how?
Re: Spawning vehicles and weapons detection -
cloudysky - 14.07.2011
No, like something automatic that detects it
Re: Spawning vehicles and weapons detection -
dowster - 14.07.2011
what is your command that spawns the cars and weapons?
Re: Spawning vehicles and weapons detection -
cloudysky - 14.07.2011
Its for hackers...
Re: Spawning vehicles and weapons detection -
Cypress - 15.07.2011
Quote:
Originally Posted by cloudysky
Its for hackers...
|
Do you mean anti cheat or? If yes use JunkBuster.
Re: Spawning vehicles and weapons detection -
dowster - 15.07.2011
Make an array like
Код:
ServerCars[MAX_VEHICLES]
then make a timer that loops at a period of time that you want, could be 30 seconds or an hour, you choose.
then when an admin types a legitimate command to make a car it inserts a one into the array at a certain spot like as follows.
Код:
ServerCars[54] = 1; //54 is for the vehicle id, just a random number
then the function that your timer calls does a check with every vehicle id against the array, and if there is a vehicle on say id 76, but the array has id 76 as 0 it will delete the car. just a quick guess but i think it may work.