2AreYouMental110

2 player wizard tycoon (WIP)

Dec 10th, 2021 (edited)
1,206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 4.75 KB | None | 0 0
  1. getgenv().autodropper = false
  2. getgenv().autocollect = false
  3. getgenv().autodeletekill = false
  4.  
  5. local library = loadstring(game:HttpGet(('https://raw.githubusercontent.com/AikaV3rm/UiLib/master/Lib.lua')))()
  6.  
  7. local window = library:CreateWindow("2 player wizard tycoon")
  8. local buying = window:CreateFolder("buying")
  9. local interacting = window:CreateFolder("interacting")
  10. local deletion = window:CreateFolder("deletion")
  11. local guns = window:CreateFolder("guns")
  12.  
  13. buying:Button("yellow tycoon buttons",function()
  14.     local player = game.Players.LocalPlayer.Character.HumanoidRootPart
  15.     for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]["Cool yellow"].YellowSecond:GetDescendants()) do
  16.         if v.Name == "TouchInterest" and v.Parent.Name == "Head" then
  17.             firetouchinterest(player, v.Parent, 0)
  18.             wait()
  19.             firetouchinterest(player, v.Parent, 1)
  20.         end
  21.     end
  22.     wait(.1)
  23.     local player = game.Players.LocalPlayer.Character.HumanoidRootPart
  24.     for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]["Cool yellow"].YellowFirst.Buttons:GetDescendants()) do
  25.         if v.Name == "TouchInterest" and v.Parent.Name == "Head" then
  26.             firetouchinterest(player, v.Parent, 0)
  27.             wait()
  28.             firetouchinterest(player, v.Parent, 1)
  29.         end
  30.     end
  31. end)
  32.  
  33. buying:Button("red tycoon buttons",function()
  34.     local player = game.Players.LocalPlayer.Character.HumanoidRootPart
  35.     for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]["Medium red"].RedFirst.Buttons:GetDescendants()) do
  36.         if v.Name == "TouchInterest" and v.Parent.Name == "Head" then
  37.             firetouchinterest(player, v.Parent, 0)
  38.             wait()
  39.             firetouchinterest(player, v.Parent, 1)
  40.         end
  41.     end
  42.     wait()
  43.     local player = game.Players.LocalPlayer.Character.HumanoidRootPart
  44.     for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]["Medium red"].RedSecond.Buttons:GetDescendants()) do
  45.         if v.Name == "TouchInterest" and v.Parent.Name == "Head" then
  46.             firetouchinterest(player, v.Parent, 0)
  47.             wait()
  48.             firetouchinterest(player, v.Parent, 1)
  49.         end
  50.     end
  51. end)
  52.  
  53. interacting:Button("dropper button",function()
  54.     local player = game.Players.LocalPlayer.Character.HumanoidRootPart
  55.     for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]:GetDescendants()) do
  56.         if v.Name == "ClickDetector" and v.Parent.Name == "Button" and v.Parent.Parent.Name == "Mine" then
  57.             fireclickdetector(v)
  58.             wait()
  59.             fireclickdetector(v)
  60.         end
  61.     end
  62. end)
  63.  
  64.  
  65. interacting:Toggle("auto dropper button (lags a little bit)",function(bool)
  66.     getgenv().autodropper = bool
  67.     print(on)
  68.     if bool then
  69.         dropper()
  70.     end
  71. end)
  72.  
  73.  
  74.  
  75. interacting:Toggle("auto collect (buggy)",function(bool)
  76.     getgenv().autocollect = bool
  77.     print(on)
  78.     if bool then
  79.         collect()
  80.     end
  81. end)
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90. function collect()
  91.     spawn(function()
  92.         while getgenv().autocollect == true do
  93.             local player = game.Players.LocalPlayer.Character.HumanoidRootPart.Position
  94.             for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]:GetDescendants()) do
  95.                 if v.Name == "TouchInterest" and v.Parent.Name == "Giver" and v.Parent.Parent.Name == "Essentials" then
  96.                     v.Parent.Transparency = ".9"
  97.                     v.Parent.CanCollide = false
  98.                     v.Parent.CFrame = CFrame.new(player)
  99.                     wait()
  100.                 end
  101.             end
  102.            local player = game.Players.LocalPlayer.Character.HumanoidRootPart.Position
  103.             for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]:GetDescendants()) do
  104.                 if v.Name == "TouchInterest" and v.Parent.Name == "Giver2" and v.Parent.Parent.Name == "Essentials" then
  105.                     v.Parent.Transparency = ".9"
  106.                     v.Parent.CanCollide = false
  107.                     v.Parent.CFrame = CFrame.new(player)
  108.                     wait()
  109.                 end
  110.             end
  111.         end
  112.     end)
  113. end
  114.  
  115. function dropper()
  116.     spawn(function()
  117.         while getgenv().autodropper == true do
  118.             local player = game.Players.LocalPlayer.Character.HumanoidRootPart
  119.             for i, v in pairs(game:GetService("Workspace")["berezaa's Tycoon Kit"]:GetDescendants()) do
  120.                 if v.Name == "ClickDetector" and v.Parent.Name == "Button" and v.Parent.Parent.Name == "Mine" then
  121.                     fireclickdetector(v)
  122.                     wait()
  123.                     fireclickdetector(v)
  124.                 end
  125.             end
  126.         end
  127.     end)
  128. end
  129.  
  130.  
Add Comment
Please, Sign In to add comment