Jump to content

Spawn Bike


Recommended Posts

  
function hasBikeSpawned(thePlayer) 
if getElementData(thePlayer, "bikeSpawned") then 
return true 
else 
return false 
end 
end 
  
function gimmeTheBike(thePlayer) 
if hasBikeSpawned(thePlayer) then 
destroyElement(getElementData(thePlayer, "bikeSpawned")) 
local veh = createVehicle(411, getElementPosition(thePlayer)) 
warpPedIntoVehicle(thePlayer, veh) 
setElementDAta(thePlayer, "bikeSpawned", veh) 
else 
local veh = createVehicle(411, getElementPosition(thePlayer)) 
warpPedIntoVehicle(thePlayer, veh) 
setElementDAta(thePlayer, "bikeSpawned", veh) 
end 
end 
  

Comanda o pui tu singur pe functie si modifica ID'ul pt ca eu nu stiu IDurile pe derost. ID 411 = Infernus.

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...