I've been trying to change a SurfaceGui's parent to PlayerGui, can anyone help me out?
Script
local ScreenGui = script.Parent
ScreenGui.Parent = script.Parent.Parent
game.Players.PlayerAdded:Connect(function(plr)
plr.CharacterAdded:Connect(function(char)
if char == true then
ScreenGui.AncestryChanged:Connect(function(child, parent)
print(child.Name.." is now a child of "..parent.Name)
end)
ScreenGui.Parent = game.Players.LocalPlayer.PlayerGui
end
end)
end)

2 comments
where is the script located
The script is in the SurfaceGui