so i tried making a ProximityPrompt make a UI visible when you interact with it.

heres the script:

script.Parent.Triggered:Connect(function()
	game.Players.LocalPlayer.PlayerGui.Shop.Frame.Visible = true
end)

at this point i was just getting confused. im still new to lua, ive been learning it for about 6 months now.

heres the error.

Workspace.shop man.Head.ProximityPrompt.Script:2: attempt to index nil with 'PlayerGui'

also no it does not have to do with Triggered in my last post about this someone said the event was PromptTriggered which was not true.

please help. thank you