I made a script when a player joins a GUI is visible but the GUI does not pop up?
local Frame = script.Parent
game.Players.PlayerAdded:Connect(function()
Frame.Visible = true
end)
I made a script when a player joins a GUI is visible but the GUI does not pop up?
local Frame = script.Parent
game.Players.PlayerAdded:Connect(function()
Frame.Visible = true
end)
I had a very similar problem. This is what I came up with make a part and then put it over spawn and edit the script.
script.Parent.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
local plr = game.Players:GetPlayerFromCharacter(hit.Parent)
if plr then
if not plr.PlayerGui:FindFirstChild("GUIClonedfromtouchblock") then
local clonedgui = script.Parent:FindFirstChildOfClass("ScreenGui"):Clone()
clonedgui.Name = "GUIClonedfromtouchblock"
clonedgui.Parent = plr.PlayerGui
wait(2)
script.Parent.TouchEnded:Connect(function(hit2)
if hit == hit2 then
game.Debris:AddItem(clonedgui,0)
end
end)
end
end
end
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.
2 comments
Why not just leave it visible in studio?
Is ScreenGui.Enabled == true?