#How do i make a gui popup when you interact with a proximity prompt

1 messages · Page 1 of 1 (latest)

eager cloud
#

I put a proximity prompt in a rig and when ypu interact w it i want it to popup a gui

wise valveBOT
#

studio** You are now Level 1! **studio

summer panther
#

``local Players = game:GetService("Players")
local player = Players.LocalPlayer
local playerGui = player:WaitForChild("PlayerGui")

local popupGui = playerGui:WaitForChild("PopupGui")
local yesButton = popupGui.Frame:WaitForChild("YesButton")

-- Change these paths to match your rig and part names
local proximityPrompt = workspace:WaitForChild("Rig"):WaitForChild("Head"):WaitForChild("ProximityPrompt")

proximityPrompt.Triggered:Connect(function()
popupGui.Enabled = true
end)

yesButton.MouseButton1Click:Connect(function()
popupGui.Enabled = false
print("Yes button clicked!")
-- Put any additional logic here for Yes action
end)
``

Put the ProximityPrompt inside a Part in your rig.

fallen island
#

yo

#

so

#

i don't think u are supposed to use Enabled if u want to make the gui visible to the player then u have to use .Visible

fickle oyster
#

enabled is for UI events I believe

wise valveBOT
#

studio** You are now Level 1! **studio