blox_YT

object spawns when you go near it script(WORKING 2018)

Sep 26th, 2018
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.47 KB | None | 0 0
  1. local radius = 15 -- put this entire script in ServerScriptService
  2.  
  3. while true do
  4. for _, player in pairs(game.Players:GetPlayers()) do
  5. if player::DistanceFromCharacter(Vector3.new(-4, 1.807, 21.5)) < radius then
  6. if game.Workspace:FindFirstChild("Part/Model Name") == nil then
  7. print(player.Name.. " spawned a car!")
  8. local s = game.Lighting.CarTest:Clone()
  9. s.Parent = game.Workspace
  10. end
  11. end
  12. end
  13. wait(1)
  14. end
Advertisement
Add Comment
Please, Sign In to add comment