TheNadie

Ninja Masters Auto farm

Mar 9th, 2019
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.34 KB | None | 0 0
  1. local Options = {
  2. ["Start Area Back"] = true, -- Starting Area (true if you wanna farm it)
  3. ["Autumn"] = true, -- Autumn Area (true if you wanna farm it)
  4. ["Frostland"] = true, -- Frostland Area (true if you wanna farm it)
  5. ["Inferno"] = true, -- Inferno Zone (true if you wanna farm it)
  6. ["Voidland"] = true,
  7. }
  8.  
  9. local Weapon;
  10. _G.StopFarming = false
  11. function GetWeapon()
  12. local Found = false
  13. for i,v in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  14. if v:IsA("Tool") then
  15. if v:FindFirstChild("Katana") then
  16. Weapon = v
  17. Found = true
  18. end
  19. end
  20. end
  21. if Found == false then
  22. for a,b in pairs(game.Players.LocalPlayer.Backpack:GetChildren()) do
  23. if b:IsA("Tool") then
  24. if b:FindFirstChild("Katana") then
  25. b.Parent = game.Players.LocalPlayer.Character
  26. Weapon = b
  27. Found = true
  28. end
  29. end
  30. end
  31. end
  32. end
  33.  
  34. GetWeapon()
  35.  
  36. function CheckWeapon()
  37. for i,v in pairs(game.Players.LocalPlayer.Character:GetChildren()) do
  38. if v:IsA("Tool") then
  39. if v:FindFirstChild("Katana") then
  40. Weapon = v
  41. return true
  42. else
  43. return false
  44. end
  45. end
  46. end
  47. end
  48.  
  49. local NotDoneYet = false
  50. repeat
  51. wait()
  52. for i,v in pairs(game.Workspace.NPCs.Spawns:GetChildren()) do
  53. if v.Name == "Start Area Back" and Options["Start Area Back"] == true or v.Name == "Autumn" and Options["Autumn"] == true or v.Name == "Frostland" and Options["Frostland"] == true or v.Name == "Inferno" and Options["Inferno"] == true or v.Name == "Voidland" and Options["Voidland"] == true then
  54. local a = v:GetChildren()
  55. for i=1,#a do
  56. if a[i].Name:match("Ninja") then
  57. if a[i]:FindFirstChild("Humanoid") and a[i].Humanoid.Health > 0 and a[i]:FindFirstChild("HumanoidRootPart") then
  58. local ItsNil = false
  59. repeat
  60. wait()
  61. if game.Players.LocalPlayer.Character and game.Players.LocalPlayer.Character:FindFirstChild("HumanoidRootPart") and a[i]:FindFirstChild("HumanoidRootPart") then
  62. if CheckWeapon() then
  63. game.Players.LocalPlayer.Character.HumanoidRootPart.CFrame = a[i].HumanoidRootPart.CFrame + a[i].HumanoidRootPart.CFrame.lookVector * -3
  64. wait()
  65. Weapon:Activate()
  66. wait()
  67. Weapon:Deactivate()
  68. else
  69. GetWeapon()
  70. end
  71. else
  72. ItsNil = true
  73. end
  74. until ItsNil == true or a[i].Humanoid.Health <= 0 or _G.StopFarming == true
  75. if _G.StopFarming == false then
  76. wait(0.9)
  77. else
  78. wait()
  79. end
  80. if _G.StopFarming == true and NotDoneYet == false then
  81. NotDoneYet = true
  82. wait(1)
  83. end
  84. end
  85. end
  86. end
  87. end
  88. end
  89. until _G.StopFarming == true
Add Comment
Please, Sign In to add comment