Sasu Posted September 4, 2013 Posted September 4, 2013 function montar() warpPedIntoVehicle(conductor, carro) outputChatBox(tostring(source)..", "..getPlayerName(source) or "Failed!!", root) try = warpPedIntoVehicle(source, carro, 4) outputChatBox(tostring(try), root) triggerClientEvent("startTravel", root, conductor) end addEvent("subirPlayer", true) addEventHandler("subirPlayer", root, montar) I have this function that is trigger when I press a button. But for any reason the warpPedIntoVehicle in line 4 returns me false. I cant warp the player to the carro who is defined with createVehicle. The warpPedIntoVehicle in line 2 works perfectly. Why the other dont work?
Sasu Posted September 4, 2013 Author Posted September 4, 2013 source is the localPlayer triggerServerEvent("subirPlayer", localPlayer) And in the line 3, I check that the player "source" is correctly.
50p Posted September 4, 2013 Posted September 4, 2013 Ok, then there is no seat 4. Use seat 3 instead because seat numbers start from 0 = driver.
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