From venuslockscript, 6 Months ago, written in Lua.
Embed
  1. --// This script is mainly just for some quick cash at the start of each tier and to complete harvest quests. To make lots of money you need to set up your factory.
  2.  
  3. --// Settings
  4. _G.Running = false --// Set to false to disable the script.
  5. _G.AutoPickup = true --// Set to false to disable auto pickup.
  6. _G.AutoSell = true --// Set to false to disable auto sell.
  7. _G.Target = "Tree" --// Type item you want to harvest here.
  8.  
  9. --// All possible items to harvest. \\--
  10. --// Tier 0: Tree, Rock
  11. --// Tier 1: CopperOre, Sand
  12. --// Tier 2: GoldOre, IronOre, HardwoodTree
  13. --// Tier 3: SuperwoodTree, ResiniteOre, TitaniumOre, Diamond, UraniumOre
  14. --// Tier 4: UltrawoodTree, IceCrystal, RedmetalOre, BluemetalOre, LaveCrystal, TungstenOre
  15.  
  16. --// Don't edit anything below this point unless you know what you are doing \\--
  17.  
  18. --// Find our grid
  19. local MyGrid
  20. for _,Grids in pairs(workspace.Grids:GetDescendants()) do
  21.         if Grids.Name == "Owner" and Grids.Value == game.Players.LocalPlayer then
  22.                 MyGrid = Grids.Parent
  23.         end
  24. end
  25.  
  26. local Material = loadstring(game:HttpGet("https://raw.githubusercontent.com/Kinlei/MaterialLua/master/Module.lua"))()
  27.  
  28. local X = Material.Load({
  29.         Title = "Made By: Guybrush#8178",
  30.         Style = 3,
  31.         SizeX = 250,
  32.         SizeY = 350,
  33.         Theme = "Dark"
  34. })
  35.  
  36. local Y = X.New({
  37.         Title = "Factory Simulator [OVERHAUL]"
  38. })
  39.  
  40. local A = Y.Toggle({
  41.         Text = "Enabled",
  42.         Callback = function(Value)
  43.                 _G.Running = Value
  44.         end,
  45.         Enabled = false
  46. })
  47.  
  48. local B = Y.Toggle({
  49.         Text = "Auto_Pickup",
  50.         Callback = function(Value)
  51.                 _G.AutoPickup = Value
  52.         end,
  53.         Enabled = true
  54. })
  55.  
  56. local C = Y.Toggle({
  57.         Text = "Auto_Sell",
  58.         Callback = function(Value)
  59.                 _G.AutoSell = Value
  60.         end,
  61.         Enabled = true
  62. })
  63.  
  64. local D = Y.Dropdown({
  65.         Text = "Resource:",
  66.         Callback = function(Value)
  67.                 _G.Target = Value
  68.         end,
  69.                
  70.         Options = {"Tree", "Rock", "CopperOre", "Sand", "GoldOre", "IronOre", "HardwoodTree", "SuperwoodTree", "ResiniteOre", "TitaniumOre", "Diamond", "UraniumOre", "UltrawoodTree", "IceCrystal", "RedmetalOre", "BluemetalOre", "LaveCrystal", "TungstenOre"
  71.         },
  72. })
  73.  
  74. while true do
  75.         wait()
  76.         pcall(function()
  77.                 for _,Cut in pairs(workspace.Harvestable:GetDescendants()) do
  78.                         --// Auto harvest when near.
  79.                         if _G.Running and Cut:IsA("Model") and Cut.Name == _G.Target and Cut.Parent.Parent.Name == "Harvestable" then
  80.                                 game.Players.LocalPlayer.Character:MoveTo(Cut:FindFirstChildWhichIsA("BasePart").Position)
  81.                                 wait(.25)
  82.                                 if game.Players.LocalPlayer:DistanceFromCharacter(Cut:FindFirstChildWhichIsA("BasePart").Position) <= 50 then
  83.                                         game:GetService("ReplicatedStorage").Events.Harvest.Harvest:FireServer(Cut)
  84.                                         wait(.5)
  85.                                 end
  86.                                 --// Auto pickup when near. You can only carry one type of item and only 15 of that type. (Vehicles hold more but this is not currently set up to use them)
  87.                                 if _G.AutoPickup then
  88.                                         for _,Pickitup in pairs(MyGrid.Entities:GetChildren()) do
  89.                                                 if Pickitup:IsA("BasePart") then
  90.                                                         if game.Players.LocalPlayer:DistanceFromCharacter(Pickitup.Position) <= 50 then
  91.                                                                 game:GetService("ReplicatedStorage").Events.Inventory.PickUp:FireServer(Pickitup)
  92.                                                                 wait(.5)
  93.                                                                 --// Auto sell harvested items when at capacity. (Requires a sellzone on your grid)
  94.                                                                 if _G.AutoSell then
  95.                                                                         for _,Sellit in pairs(MyGrid.PlacedObjects:GetChildren()) do
  96.                                                                                 local Carried = game.Players.LocalPlayer.Character:FindFirstChild("CarriedItem")
  97.                                                                                 if Sellit.Name == "SellZone" and Carried and tonumber(Carried.Handle.AmountGui.Amount.Text) >= 15 then
  98.                                                                                         game.Players.LocalPlayer.Character:MoveTo(Sellit:FindFirstChildWhichIsA("BasePart").Position)
  99.                                                                                         wait(1)
  100.                                                                                         game:GetService("ReplicatedStorage").Events.Inventory.PickUp:FireServer(Carried.Handle)
  101.                                                                                         wait(1)
  102.                                                                                 end
  103.                                                                         end
  104.                                                                 end
  105.                                                         end
  106.                                                 end
  107.                                         end
  108.                                 end
  109.                         end
  110.                 end
  111.         end)
  112. end