You may look at this image and think that i have already achieved it, but no.
I achieved this using Humanoid:ApplyDescription(), which makes the hats look buggy and also, once a new player joins, their avatar is shown and everyone thats in the begin screen sees that avatar.
What i am trying to achieve now is clone the localplayer’s character, and put it where the dummy would be and then delete the dummy. I have already tried and failing with this code:
game.Players.PlayerAdded:Connect(function(plr)
if plr.Name == game.Players.LocalPlayer.Name then
local char = game.Players.LocalPlayer.Character:Clone()
char.Parent = workspace.StarterCharModel
char:SetPrimaryPartCFrame(workspace.StarterDummy.PrimaryPart.CFrame)
workspace.StarterDummy:Destroy()
end
end)
If anyone could help me with this problem it would be greatly appreciated. Thanks!
local players = game:GetService("Players")
local player = players.LocalPlayer
local imageLabel = script.Parent
local success, result = pcall(function()
return players:GetUserThumbnailAsync(player.UserId, Enum.ThumbnailType.AvatarThumbnail, Enum.ThumbnailSize.Size420x420)
end)
if success then
if result then
imageLabel.Image = result
end
else
warn(result)
end
Remove the game.Players.PlayerAdded thing. It seems that you are already using a local script, so it is unneeded and is what is causing other player’s avatars to show
You can create a model named StarterCharModel and put in it a character model with the same name of the player.
Each time a player joins the game, you can do: game.Players.PlayerAdded:Connect(function(plr)
if plr.Name == game.Players.LocalPlayer.Name then
local char = game.Players.LocalPlayer.Character:Clone()
char.Parent = workspace.StarterCharModel
char:SetPrimaryPartCFrame(workspace.StarterDummy.PrimaryPart.CFrame)
workspace.StarterDummy:Destroy()
end
end)