All this does is literally just clone the scripts and destroy the old ones. IT IS NOT CLONING. (printed and it isn’t nil) i tried modules EVEYTHING I WILL RIP MY HAIR OUT
for _, scripts in pairs(workspace.LoadedMaps:GetDescendants()) do
if scripts:IsA("Script") and scripts.Enabled == false then
local clone = scripts:Clone()
clone.Enabled = true
end
end
task.wait(0.2)
for _, scripts in pairs (workspace.LoadedMaps:GetDescendants()) do
if scripts:IsA("Script") and scripts.Enabled == false then
scripts:Destroy()
end
end
script.Enabled = false
You don’t parent the scripts anywhere ? I’m guessing you’d have to do
for _, scripts in pairs(workspace.LoadedMaps:GetDescendants()) do
if scripts:IsA("Script") and scripts.Enabled == false then
local clone = scripts:Clone()
clone.Enabled = true
clone.Parent = workspace.LoadedMaps --(or whatever you wanna place them in)
end
end
task.wait(0.2)
for _, scripts in pairs (workspace.LoadedMaps:GetDescendants()) do
if scripts:IsA("Script") and scripts.Enabled == false then
scripts:Destroy()
end
end
script.Enabled = false