Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local spawnX, spawnY, spawnZ = 1959.55, -1714.46, 17
- local createdVehicle, myBlip
- function joinHandler()
- spawnPlayer(source, spawnX, spawnY, spawnZ)
- fadeCamera(source, true)
- setCameraTarget(source, source)
- outputChatBox("Welcomezzz babe!", source)
- end
- addEventHandler("onPlayerJoin", root, joinHandler)
- function createVehicleForPlayer(thePlayer, command, vehicleModel, blip)
- local x, y, z = getElementPosition(thePlayer)
- x = x + 5
- y = y + 10
- if (createdVehicle) then
- destroyElement(createdVehicle)
- end
- createdVehicle = createVehicle(tonumber(vehicleModel), x, y, z)
- if (not createdVehicle) then
- outputChatBox("failed to create veh!", thePlayer)
- end
- if (myBlip) then
- destroyElement(myBlip)
- end
- myBlip = createBlipAttachedTo(createdVehicle, blip)
- end
- addCommandHandler("createveh", createVehicleForPlayer)
Advertisement
Add Comment
Please, Sign In to add comment