Disable Playerlist isn't working

Hi guys

I want to hide playerlist, however, game:GetService("StarterGui"):SetCore("ResetButtonCallback", false) is working but game:GetService("StarterGui"):SetCore(Enum.CoreGuiType.PlayerList,false) isn’t working. I put it on StarterCharacterScripts. What is the problem of this code?

local succeed
repeat
	succeed = pcall(function()
		game:GetService("StarterGui"):SetCore("ResetButtonCallback", false)
		game:GetService("StarterGui"):SetCore(Enum.CoreGuiType.PlayerList,false)
	end)
until succeed

1 Like

Replace:

:SetCore(Enum.CoreGuiType.PlayerList,false)
with
:SetCoreGuiEnabled(Enum.CoreGuiType.PlayerList,false)

You should also add a wait() in case it will yield forever, which leads to crashing the client.

2 Likes