HI, In the code I made it tells me (line 7) closeButton is not a valid member of ScreenGui "Players.xXDskaCapyXx.PlayerGui.ScreenGui" (xXDskaCapyXx it's me)
local open = game.Workspace.openPart local close = game.Workspace.closePart local frame = script.Parent local closeButton = frame.closeButton
frame.Visible = false
local function ShopMenu(otherPart)
local player = game.Players:FindFirstChild(otherPart.Parent.Name) if player then player.PlayerGui.ScreenGui.Shop.Visible = true player.Character.Humanoid.WalkSpeed = 0 end
end
local function closeMenu()
local player = game.Players.LocalPlayer player.PlayerGui.ScreenGui.Shop.Visible = false player.Character.HumanoidRootPart.CFrame =
CFrame.new(close.Position.X,close.Position.Y,close.Position.Z)
player.Character.Humanoid.WalkSpeed = 16
end
open.Touched:Connect(ShopMenu)
closeButton.MouseButton1Click:Connect(closeMenu)
here is the whole code please I need help thank you in advance