xScatta Posted September 9, 2013 Share Posted September 9, 2013 (edited) Hey guys i maked his script error below CODE REMOVED But when the player dont have owner serial he still can drive the vehicle. no messages in debugscript 3. Edited September 10, 2013 by Guest Link to comment
GamerDeMTA Posted September 9, 2013 Share Posted September 9, 2013 BUMP? NO, DON'T BUMP. Only 1 hour passed and "BUMP"? Link to comment
csiguusz Posted September 9, 2013 Share Posted September 9, 2013 If you don't want him to bump, then why don't you try to help him? Try this anyway: vehicles = {} addCommandHandler("vehicle", function(player,vehicle,car) local x, y, z = getElementPosition(player) player = getPlayerSerial(player) vehiclex = createVehicle(getVehicleModelFromName(car), x, y+2, z) vehicles[vehiclex] = player end) addEventHandler("onVehicleEnter", root, function(playerx, seat) if vehicles [ source ] == getPlayerSerial ( playerx ) and seat == 0 then setVehicleEngineState(source, true) elseif seat == 0 then outputChatBox("You can't drive this vehicle.", playerx) setVehicleEngineState(source, false) end end) 1 Link to comment
xScatta Posted September 9, 2013 Author Share Posted September 9, 2013 Working. Thank very much Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now