Hi, I have a question, I've made a Teleport Gui for Players on Mermaid High and It's worked in a part that i made on December 2020 but when i change the Gui for another it's doesn't work.
local Part = script.Parent
local Debounce = false
Part.Touched:Connect(function(hit)
if Debounce == false then
Debounce = true
if hit.Parent:FindFirstChild("Humanoid") then
local plr = game.Players:GetPlayerFromCharacter(hit.Parent).PlayerGui
script.ScreenGui:Clone().Parent = plr -- replace "ScreenGui" with the name of your ScreenGui
end
wait(1)
Debounce = false
end
end)
Also i changed the Name on ScreenGui in the script and stop working
When it's opened: https://gyazo.com/e3da7e8b5c4ed37bc965e4681ecb9548
When it's not opened: https://gyazo.com/49fc25b4c7b71fe68f30143bf85ea0d3

9 comments
Clarify what you're trying to do. Also check in the output for any error messages
Don't see any reason why this shouldn't be working, maybe make sure of your screengui being visible look at your explorer to make sure it actually doesn't get placed in your playergui
Ok, Ty
The Gui doesn't are in the player gui, What i do?
plr.PlayerGui
Must be in the Player gui or no?
For a GUI to display for a player, it has to be in PlayerGui. If you put your GUI in StarterGui it'll automatically put it in PlayerGui, then you can use the Enabled property on the ScreenGui to enable and disable it.
Okie. Tysm
But the Gui doesn't show when touch a part