#1

What is the reasoning behind changing the way vehicles are locked, and setvehicleplate?

Cause I have over 300 vehicles that require locking and no one has supplied the way to lock numerous vehicles. I've been given ideas, but none have worked. Also my script really needs setvehicleplate.
Reply
#2

To lock vehicles, just use SetVehiclePrams on OnVehicleStreamIn. Simple
Reply
#3

You can simply re-apply the lock (using SetVehicleParams), everytime it streams in. You just need to create an additional variable, to clarify that it needs to be locked once streamed in for another player.

pawn Код:
new Locked[MAX_PLAYERS];
Then re-apply the SetVehicleParams if Locked is 1.
Reply
#4

add if(Locked[vehicleid]) into OnVehicleStreamLn
and in timer https://sampwiki.blast.hk/wiki/IsVehicleStreamedIn with setting params for player in cycle
Reply
#5

May be simple to you, although every time I've tried doing this, and every person gives me different ideas it failes. I understand almost everything else, except this haha.


Say I have 1 - 25 that need to be locked for anyone else but <desiredname> how would this be accomplished? Cause right now to unlock vehicles for the desired name, say I type /loginlspd below that command in the line of code would be "UnlockLSPDCars" and it unlocked the id's I provide in a line such as

Unlock<Name>cars
Setveh.....1,0
....
setveh.....15,0

ect
Reply
#6

See, it is easy to lock one... but not alot lol
Reply
#7

look, you use normal lock unlock, just add that it should be reapplied when vehicle streams in and thats it
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)