No errors in output for some reason this script is supposed to say when player gets to 100% show slots which it's a 5 block GUI and then the slots are what goes in the 5 blocks but this all works but then when it's told with math.random this is incomplete this is only for slot1 but the robloximage is supposed to be put in slot1 please help?
plr = game.Players.LocalPlayer
script.Parent.MouseButton1Click:connect(function()
local check1 = plr:WaitForChild("leaderstats")
if check1 then
local Percent = check1:WaitForChild("Percent")
if Percent then
Percent.Value = Percent.Value + 1
local Amount = plr.PlayerGui.CaseClicker.CaseClicker2.Search
Amount.Text = "Search For Crates : "..tostring(Percent.Value)..tostring("%")
if Percent.Value == 100 then
Percent.Value = 0
plr.PlayerGui.Chooser.Slots.Visible = true
local crates = game.ServerStorage.Crates
local commonclone = crates.Common:Clone()
local uncommonclone = crates.Uncommon:Clone()
local Rareclone = crates.Rare:Clone()
local Ultrarareclone = crates.Ultrarare:Clone()
local Epicclone = crates.Epic:Clone()
local Legendaryclone = crates.Legendary:Clone()
local clones = {commonclone,uncommonclone,Rareclone,Ultrarareclone,Epicclone,Legendaryclone}
local choice1 = math.random(1,6)
if choice1 == 1 then
commonclone.Parent = plr.StarterGui.Chooser.Slots.Slot1
if choice1 == 2 then
uncommonclone.Parent = plr.StarterGui.Chooser.Slots.Slot1
if choice1 == 3 then
Rareclone.Parent = plr.StarterGui.Chooser.Slots.Slot1
if choice1 ==4 then
Ultrarareclone.Parent = plr.StarterGui.Chooser.Slots.Slot1
if choice1 == 5 then
Epicclone.Parent = plr.StarterGui.Chooser.Slots.Slot1
if choice1 == 6 then
Legendaryclone.Parent = plr.StarterGui.Chooser.Slots.Slot1
end
end
end
end
end
end
end
end
end
wait(1)
end)
