local B=game:GetService("\085\115\101\114\073\110\112\117\116\083\101\114\118\105\099\101")B.InputBegan:Connect(function(B)if B.KeyCode==Enum.KeyCode.Q then if script.Parent.Tela.Visible==false then script.Parent.Tela.Visible=true script.Parent.Tela.Mouse.Modal=true else script.Parent.Tela.Visible=false script.Parent.Tela.Mouse.Modal=false end end end)script.Parent.MouseButton1Click:Connect(function()if script.Parent.Tela.Visible==false then script.Parent.Tela.Visible=true elseif script.Parent.Tela.Visible==true then script.Parent.Tela.Visible=false end end)


local key = game:GetService("UserInputService")

key.InputBegan:Connect(function(input)
	if input.KeyCode == Enum.KeyCode.Q then
		if script.Parent.Tela.Visible == false then   -- Se a tela estiver invisivel 
			script.Parent.Tela.Visible = true         -- Fica visivel
			script.Parent.Tela.Mouse.Modal = true
		else                             -- Se não:
			script.Parent.Tela.Visible = false
			script.Parent.Tela.Mouse.Modal = false
		end	
	end
end)

script.Parent.MouseButton1Click:Connect(function()
	if script.Parent.Tela.Visible == false then
	script.Parent.Tela.Visible = true
	elseif script.Parent.Tela.Visible == true then
		script.Parent.Tela.Visible = false
	end
end)
