Jump to content

HELP Me with my Script PLEASEE!!!


Recommended Posts

CLIENT SIDE

  
local vehicleMarker = createMarker(1032.47998, -1032.34766, 31.1,"cylinder",1,255,255,255) 
  
function vehicleGUI() 
vehicleGUI = guiCreateWindow(277, 204, 268, 223, "Vehicle Spawn", false) 
guiWindowSetSizable(vehicleGUI, false) 
  
vehicleOne = guiCreateButton(9, 31, 250, 50, "Faggio", false, vehicleGUI) 
vehicleBMX = guiCreateButton(9, 95, 250, 50, "BMX", false, vehicleGUI) 
vehicleMountain = guiCreateButton(9, 162, 250, 50, "Mountain Bike", false, vehicleGUI) 
  
if source == vehicleMarker then 
guiSetVisible(vehicleGUI, true) 
showCursor( true ) 
   end 
end 
addEventHandler("onClientMarkerHit",getRootElement(),vehicleGUI) 
  
function vehicleOne( player ) 
if source == vehicleOne then 
local playerspawn = getLocalPlayer() 
local x, y, z = getElementPosition ( playerspawn ) 
createVehicle ( 462, x, y, z + 5 ) 
guiSetVisible(vehicleGUI,false) 
showCursor( false ) 
end  
end 
addEventHandler("onResourceStart",getRootElement(),vehicleOne) 
  

I can't spawn the vehilce when i press the button :/ No errors come up either.

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...