Hello i am trying to make when player is sitting it displays players thumbnail on part.
But i am new to scripting and i can’t figure it out. Could you help me?
You can use a SurfaceGui or a Decal to display the player’s image on the part. To get an image URL you can use for the player sitting down, you can use the playerService:GetUserThumbnailAsync API.
--//You can configure these
local THUMBNAIL_TYPE = Enum.ThumbnailType.AvatarThumbnail
local THUMBNAIL_SIZE = Enum.ThumbnailSize.Size420x420
local function setPartImageToPlayer(player)
local image;
pcall(function() image = game:GetService("Players"):GetUserThumbnailAsync(player.UserId, THUMBNAIL_TYPE, THUMBNAIL_SIZE) end)
if not image then
warn("Something went wrong when displaying image for ["..player.."]")
else
--//Display image URL
end