my cars not lock with ths code [HELP]HELP - 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: my cars not lock with ths code [HELP]HELP (
/showthread.php?tid=267641)
my cars not lock with ths code [HELP]HELP -
Honest_Player - 09.07.2011
hello here is my code when i add this its not lock vehicles in my tdm server i want to lock all cars or tell me where i add this players sill drives vehicles and i dontwant they drive just fight
pawn Код:
//==========================Vehicles lock for ever==============================
new engine,lights,alarm,doors,bonnet,boot,objective;
for(new i = 0; i < MAX_VEHICLES; i ++)
{
GetVehicleParamsEx(i,engine,lights,alarm,doors,bonnet,boot,objective);
SetVehicleParamsEx(i,0,lights,alarm,doors,bonnet,boot,objective);
}
plz check the code i use it OnGameModeINT plz help
Re: my cars not lock with ths code [HELP]HELP -
Jack_Leslie - 09.07.2011
Your turning the engine off, not locking the car.
Re: my cars not lock with ths code [HELP]HELP -
Honest_Player - 09.07.2011
how i loc cars
plz give me code!!!!!
Re: my cars not lock with ths code [HELP]HELP -
Jack_Leslie - 09.07.2011
Код:
new engine,lights,alarm,doors,bonnet,boot,objective;
for(new i = 0; i < MAX_VEHICLES; i ++)
{
GetVehicleParamsEx(i,engine,lights,alarm,doors,bonnet,boot,objective);
SetVehicleParamsEx(i,engine,lights,alarm,1,bonnet,boot,objective);
}
Re: my cars not lock with ths code [HELP]HELP -
Honest_Player - 09.07.2011
i add u and wait i try if its work
Re: my cars not lock with ths code [HELP]HELP -
Honest_Player - 09.07.2011
ah first tell me where i add the code and 2nd i add it on gamemodeit and i still enter in ehicle
Re: my cars not lock with ths code [HELP]HELP -
Shadoww5 - 09.07.2011
https://sampwiki.blast.hk/wiki/Function:...aramsForPlayer
Re: my cars not lock with ths code [HELP]HELP -
[MG]Dimi - 09.07.2011
Use
PHP код:
public OnPlayerEnterVehicle(playerid,vehicleid,ispassenger)
{
SetVehicleParamsForPlayer(vehicleid,playerid,0,1);
return 1;
}
Re: my cars not lock with ths code [HELP]HELP -
=WoR=Varth - 09.07.2011
If you want to lock them when the server start you can loop them in your OnGameModeInit()