How to Hide a player from the playerlist ? can someone help me please?
Hey brodski40,
This is very much possible, even without a custom leaderboard!
First I want to say that Kiriot22 was wrong with "You can't really do that. "
You can actually do this, it's a bit "tricky", but possible. This will also hide them from the escape menu
EXAMPLE CODE
local HideFrom = { 'PlayerName1'; 'PlayerName2'; } while true do -- I use a loop in this case because the PlayerAdded event isn't great on the client.. for _,plr in pairs(game.Players:GetPlayers()) do --looping trough players for _,v in pairs(HideFrom) do --looping trough playernames if (plr.Name == v) and plr ~= game.Players.LocalPlayer then --you don't want to destroy yourself.. wait() --in case the game tries to set the player to game.Players while you're setting it to nil plr:Destroy(); --destroys the player object (this does not destroy the player's character or so) end end end wait(2); -- making it not crash end
Note, this needs to be done from a localscript.
If you didn't see it yet, the way of doing it is destroying a player's player object from a localscript
Good things about this way of doing it
Bad things
Alternatives
Have a nice day ^-^
Small edit: I don't think Kiriot22 read the comment in my script that said "you don't want to destroy yourself..", so I'll make it clear for everyone else reading this, this only works for other players, not for yourself, as you don't want to destroy your own playerobject!
You can't really do that. What you can do however is hide the real playerlist and place your own one for it, which you have control of.
There's also an option to copy/paste the playerlist corescript's source from here, but so far I havent seen anybody not run into issues when doing that, so you probably don't want to do it.
Note that even if you do any of the above ways, the player will still be visible in the escape menu and on you game's servers tab.