Recently I have this problem on my game where when I close my gui and try to open it via script it does not open. I am trying to open a frame by checking the visible bool to true. Here is my script
local dialog = require(game.ReplicatedStorage.Modules.Dialog)
local plrr
local cooldown = false
function option1()
plrr.PlayerGui.MainGUI.Dialog:Destroy()
plrr.PlayerGui.MainGUI.GunShop.Visible = true
end
function option2()
plrr.PlayerGui.MainGUI.Dialog:Destroy()
end
script.Parent.MouseClick:Connect(function(plr)
dialog.CreateDialog(plr, "Gun Dealer", "ay, choose any gun quickly, ight?", "Alr", "Nevermind", option1, option2)
plrr = plr
end)
and here is my close script
script.Parent.MouseButton1Up:Connect(function()
script.Parent.Parent.Visible = false
end)
Sorry for my bad code