Hey there. There's a big flaw with your code. Simple fix though. You can't index into StarterGui, which is why you have to do something different. You also have to put the code inside your function, not outside of it.
What I want you to do, is insert a LocalScript into your Frame. What a localscript does, is runs locally, so the frame wont appear on everyones frame.
Code:
local Frame = script.Parent
Frame.Visible = false
game.Workspace.PARTNAME.Touched:Connect(function()
Frame.Visible = true
end)
Make sure to change PARTNAME, to your parts name, you want the Player to touch. Please try to understand the code, as it's better for you. I also highly suggest you try to learn scripting, because it will help you a LOT. Hope I helped, and have a good day.
5 comments
Thank you so much! and I do know coding just not as much.. I will try this now. thank you and have a good day
No problem, have a wonderful day.
It doesn't work.. can you add me as a friend so I can invite you so you can help me with this?
it didnt work
It should work. Make sure it's a localscript and it's in your frame, and make sure to set PARTNAME to your part's name.