Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

why wont this script work? ( ProximityPrompt not making a ui visible when interacted with )

Asked by 3 years ago
Edited 3 years ago

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

Answer this question