Jump to content

Captain Cody

Members
  • Posts

    2,753
  • Joined

  • Last visited

  • Days Won

    18

Everything posted by Captain Cody

  1. I know this topic is a bit old but Im still trying to figure out how to do this, Ive tryed a few differnt things but none of them worked is there any way to make it like a tow truck's chain?
  2. Ive tryed just about everthing I could think of
  3. How can I make it so only vehicles from one resource respawn? Ive got one resource with all the servers Main vehicles spawned with it and one that is a car shop and I dont want the Resources from the car shop to respawn Lua For Main Cars: Server: function spawnVehs() for k, v in ipairs (getElementsByType("veh")) do createVehicle(getElementData(v,"model"),getElementData(v,"posX"),getElementData(v,"posY"),getElementData(v,"posZ"),0,0,getElementData(v,"rotation")) end for k, v in ipairs (getElementsByType("vehicle")) do toggleVehicleRespawn(v,true) setVehicleIdleRespawnDelay(v,120000) end end addEventHandler("onResourceStart",getResourceRootElement(),spawnVehs) function respawnVeh() setTimer(respawnVehicle,5000,1,source) end addEventHandler("onVehicleExplode",getRootElement(),respawnVeh) Adder function addNew(source,command) if (isObjectInACLGroup("user."..getAccountName(getPlayerAccount(source)),aclGetGroup("Admin"))) then if (isPedInVehicle(source)) then local x,y,z = getElementPosition(getPedOccupiedVehicle(source)) local model = getElementModel(getPedOccupiedVehicle(source)) local rotX,rotY,rotZ = getVehicleRotation(getPedOccupiedVehicle(source)) local file = xmlLoadFile("vehicles.map") local veh = xmlCreateChild(file,"veh") xmlNodeSetAttribute(veh,"model",model) xmlNodeSetAttribute(veh,"posX",x) xmlNodeSetAttribute(veh,"posY",y) xmlNodeSetAttribute(veh,"posZ",z) xmlNodeSetAttribute(veh,"rotation",rotZ) xmlSaveFile(file) xmlUnloadFile(file) outputChatBox("*INFO* The vehicle has been successfully added and will be created in 5 seconds.",source,255,255,0) outputDebugString(getPlayerName(source).." has mapped a "..getVehicleName(getPedOccupiedVehicle(source)).." in "..getElementZoneName(getPedOccupiedVehicle(source))..", "..getElementZoneName(getPedOccupiedVehicle(source),true)..".") setTimer(function() createVehicle(model,x,y,z,0,0,rotZ) end,5000,1) end end end addCommandHandler("addcar",addNew) And the car locations are stored in a map file Luas For car shop:https://forum.multitheftauto.com/viewtopic.php?f=91&t=78063 Look at the luas on the first post
  4. Lemme Guess Original Script was made by me right?
  5. Can you give me it in an accual script fourm because this I dont really under stand with all the extra things
  6. Ummmmmmm How would I set it so you can only veiw it from like a few hundred feet away
  7. How can I make it so you can only see this blip from a little bit away? local blip = createBlip ( 89.8653, -269.70767, 1.278, 58 )
  8. Ok I changed topic name I just need to know how to make it so when someone first joins An Npc driven plane will fly in with the person on board then it will Fade out to a black screen with Welcome to BoD for a few secounds then show Login panel
  9. Well I need to play a video, Or Make it so when you first join u fly into the air port in a Npc driven plane then TP to the spawn
  10. How would I make it so when some one first joins they fly in on an Npc Driven At-400 Into LS air port then it says Welcome to BoD and Shows Login Panel And then after the persons first join it will only show admin panel
  11. Im working on an RP server and I want to make it so when I player first joins it spawns him at SF, LS Or LV air port but I cant figure out how to make it so it randomly picks the location
  12. Yeh I have dat problem 2
  13. Ah Ok Srry and I'll try what you said
  14. The wheels are white because its not loading the vehicle.txd correctly how would I fix this?
  15. It would be good if you made it so u can edit the cars in the shop ingame
×
×
  • Create New...