ptL9qSZ51rITi2

Dh auto farm found from robloxscripts dot com

Mar 6th, 2023
32
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.51 KB | None | 0 0
  1. _G.AutoFarm = true
  2.  
  3. -- // Variables
  4. local Jogador = game:GetService("Players").LocalPlayer
  5. local Drop = game:GetService("Workspace").Ignored.Drop
  6. local Cashiers = game:GetService("Workspace").Cashiers
  7. local opens = Cashiers:GetDescendants()
  8. local num_opens = #opens
  9.  
  10. -- // Functions
  11. function Farmando()
  12. while _G.AutoFarm do
  13. for _,f in pairs(Jogador:FindFirstChildOfClass("Backpack"):GetChildren()) do
  14. if f:IsA("Tool") or f:IsA("HopperBin") then
  15. if f.Name == "Combat" then
  16. f.Parent = Jogador.Character
  17. end
  18. end
  19. end
  20. wait()
  21. end
  22. end
  23.  
  24. function FarmandoLoop()
  25. while _G.AutoFarm do
  26. for _,obj in pairs(Drop:GetDescendants()) do
  27. if obj:IsA("ClickDetector") then
  28. local pos1 = obj.Parent.Position
  29. local pos2 = Jogador.Character.HumanoidRootPart.Position
  30. local distance = (pos1 - pos2).Magnitude
  31. if distance <= 20 then
  32. fireclickdetector(obj)
  33. end
  34. end
  35. end
  36. mouse1click()
  37. wait()
  38. end
  39. end
  40.  
  41. function OpensLoop()
  42. while _G.AutoFarm do
  43. for i = 1, num_opens do
  44. if opens[i].Name == "Open" then
  45. Jogador.Character.HumanoidRootPart.CFrame = opens[i].CFrame
  46. wait(12)
  47. end
  48. end
  49. i = 1
  50. wait(10)
  51. end
  52. end
  53.  
  54. -- // Main
  55. coroutine.wrap(Farmando)()
  56. coroutine.wrap(FarmandoLoop)()
  57. coroutine.wrap(OpensLoop)()
Add Comment
Please, Sign In to add comment