#im working on making this gui open when a proximity prompt is pressed can someone please help
1 messages · Page 1 of 1 (latest)
just put a script in the part and do
local part = script.Parent
local prompt = part.ProximityPrompt
prompt.Triggered:Connect(function(player)
local gui = player.PlayerGui:FindFirstChild("Gear")
if not gui then return end
gui.Enabled = not gui.Enabled
end)
tysm il give it a go
It would technically be better to put a local script in the gui itself that defines the part and does the same as above, but I'm too lazy to explain that
wait so i just use a normal script?
You can, yeah
If you're doing the method of putting in the part
Might want to make it so the run context of the script is on the client, though
Won't matter in most cases but might as well
when i interact with the prompt nothing happens
Wait a sec, I'll check if I did something wrong rq
** You are now Level 12! **
i do have to go to school in a few min so i can show you more after
Do you have the screen gui itself disabled to make it so the gui doesn't show up, or are you making the stuff in it to not be visible
just not visable
This method just enables and disables the screen gui itself, you'll have to personalize it a bit if you want it to switch the visibility of individual frames and stuff