How can I make a player list in a GUI?

No, I’m not trying to recreate the leaderboard on the top right corner of the screen.

So I have this GUI here (i’m not close to good with guis)

And for every player that joins, I want to replace the UsernameHere text with their name. Yes I know how to set the name for every player in game but I want to know how I can duplicate it so if there is two players, show both of them, three players, show three, but if one of them disconnects it goes back down to two. Here is the structure if it helps.

image

How can I accomplish this?

2 Likes

Basically you could use,

game.Players.PlayersAdded:Connect(function()
end)

and whenever a player is added, clone the usernameHere thing and change the details to the player’s details.

And whenever a player is removed, just remove their clone.

3 Likes