I'm trying to make a Developer Commands Gui. I made it and made a script that makes it visible only to me, but for some reason, it only works once. This is the script:

local Players = game:GetService("Players")

Players.PlayerAdded:Connect(function(player)
	player.CharacterAdded:Connect(function(character)	
		if player.UserId == 251936426 then
			player:WaitForChild("PlayerGui"):WaitForChild("DevCommands"):WaitForChild("DevCommandsButton").Visible = true
		end
	end)
end)

2 comments

0

Can you expand, what do you mean by only showing once? You mean when you reset it doesn't come back?

0

Yes.