Anti vehicle create. -
Dreftas - 25.06.2009
How to make something like Anti vehicle create ? That only vehicles with AddStaticVehicle/CreateVehicle work, hackers spawned vehicles will be destroyed.
Re: Anti vehicle create. -
gytisx - 25.06.2009
Labas(Hello) Reikia kazka sumastyti, kad tikrintu masinas serveri(ju skaiciu)... Bet cia siaip sunkus dalykas manau... Sorry
I'm talking about this
anti vehicle create Who can create it? I need this anti vehicle create too
Re: Anti vehicle create. -
abhinavdabral - 25.06.2009
Dude.. its easy ... if your server dont needs any vehicel shit... then you can put Destroy vehicle under OnVehicleSpawn
Re: Anti vehicle create. -
Dreftas - 25.06.2009
Ok i made it
pawn Код:
forward CheckVehicles();
public CheckVehicles()
{
for(new DestVeh = LastCar+1; DestVeh < 701; DestVeh++)
{
DestroyVehicle(DestVeh);
}
return 1;
}
LastCar is last cars id. Maybe someone need this too
On OnVehicleSpawn doesnt work this...
Re: Anti vehicle create. -
abhinavdabral - 25.06.2009
Yes... OnSpawnVehicle will clean all the vehicles...but the code you made will not allow any new vehicle
Nice 1
Re: Anti vehicle create. -
Dreftas - 25.06.2009
Because my mode dont create any new vehicles, for now this will be ok :P
Re: Anti vehicle create. -
gytisx - 25.06.2009
Good job dreft
I will use this
Re: Anti vehicle create. -
Chaprnks - 25.06.2009
Vehicles can't be created client-side. Only ones set script-side.
Re: Anti vehicle create. -
Rac3r - 25.06.2009
Quote:
hackers spawned vehicles will be destroyed.
Quote:
Originally Posted by ǝɹoɯ‾ʎ
Vehicles can't be created client-side. Only ones set script-side.
|
|
Hacks/Mods can allow any vehicles to be spawned client side only.
I 'think' the server won't be able to destroy the client side vehicles anyway, because you need to pass the vehicleid to DestroyVehicle.
Suggestion: (cba coding)
IsPlayerInAnyVehicle, if the player is in a vehicle and if the vehicle is not valid (0-700), kick/ban/punish the player.
Re: Anti vehicle create. -
abhinavdabral - 26.06.2009
I got an idea..
1) Make a Timer which will check that which player is in which vehicle.
2) If the player is in the vehicle (the maximum number of vehicles) your server have, then its OK.
3) If Player is in vehicle, but the vehicle ID is not under your server's vehicle limit, then kick the player..lol
4) Sorry, If you think this a cheap idea.
Thank You
-Abhinav