So basicaly i made a Randomiser script which gives you random tool when it gets number 1 then script disables themself, so i made another script wich have to enable this script again if its disabled, but its didnt enables it.
Randomiser
local ToolNames = {"Red Bottle", "Blue Bottle"} local Storage = game:GetService("ServerStorage") local Part = script.Parent.Parent local ClickDetector = Part:WaitForChild("ClickDetector", 5) ClickDetector.MouseClick:connect(function(Player) local Backpack = Player:WaitForChild("Backpack") local Val = script.Parent.Parent.Value local Tool = Storage:FindFirstChild(ToolNames[1]) Val.Value = (math.random(10)) if Val.Value == 1 then Tool:clone().Parent = Backpack print ("You found something!") script.Disabled = true else print ("Didnt found anything bruh") script.Disabled = true end end)
Checker
local Part = script.Parent.Parent local ClickDetector = Part:WaitForChild("ClickDetector", 5) while true do if ClickDetector.Randomiser.Disabled == true then wait(5) ClickDetector.Randomiser.Disabled = false else ClickDetector.Randomiser.Disabled = false end end
Im not getting any error!!