Basically am cloning a frame on a gui where inside the frame there is the player’s thumbnail and his name, but what happens is if there are two players in that player table (which is basically the players sent from the server that are playing in game), the frame cloned are two of the same person and two of the other person how can I correct this? I have identified that the problem is because it iterates twice, so how can I alternatively make it work or something?
The code
meetArgs.OnClientEvent:Connect(function(plrTab)
local thumbType = Enum.ThumbnailType.HeadShot
local thumbSize = Enum.ThumbnailSize.Size100x100
for i, plr in pairs(plrTab) do
local clone = frame:Clone()
local id = plr.UserId
local shot = players:GetUserThumbnailAsync(id, thumbType, thumbSize)
clone.UserThumb.Image = shot
clone.Username.Text = plr.Name
clone.Parent = script.Parent.Screen
script.Parent.Visible = true
script.Parent.Time.TimeScript.Disabled = false
end
end)