?Hi and thank you for looking at my question, I made a pause menu which where it'll open if you press down a certain key, but it isn't working. Not one bit, here's the code of Lua that I made for this.
repeat wait() until game.Players.LocalPlayer
local p = game.Players.LocalPlayer
local m = p.GetMouse ()
local folder = p.PlayerGui:WaitForChild("Pause Gui")
local guitoopen = folder ["StarterGui"]
m.KeyDown:conect(function(key)
if key: lower() == "p"then
if guitoopen.Visible then
guitoopen.Visble = false
else
guitoopen.Visible = true
end
end
end)
I have no idea why it is acting this way. So If you can help me, that'll be great!

2 comments
Thank you for trying, but the error is still present however.
I've edited my answer. Also, have you tried fixing the typos?