guigow_ Posted May 13, 2015 Share Posted May 13, 2015 Quero criar uma NRG, eu vi esse comando la na Wiki MTA function createVehicleForPlayer(thePlayer, command, vehicleModel) local x,y,z = getElementPosition(thePlayer) -- get the position of the player x = x + 5 -- add 5 units to the x position local createdVehicle = createVehicle(tonumber(vehicleModel),x,y,z) -- check if the return value was ''false'' if (createdVehicle == false) then -- if so, output a message to the chatbox, but only to this player. outputChatBox("Failed to create vehicle.",thePlayer) end end addCommandHandler("createvehicle", createVehicleForPlayer) mas da esse erro ai Failed to create vehicle oquje falta pro meu comando estar correto ? Link to comment
DNL291 Posted May 13, 2015 Share Posted May 13, 2015 A sintaxe é: createvehicle . Pode ser que o ID do veiculo esteja errado. Verifique também se o script está como server-side no meta.xml. 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