Is there a specific way you can make a headshot fit better into an imagelabel as I made a circle imagelabel but the hair of a headshot goes out of it, and help would be appreciated
You can use UICorner | Roblox Creator Documentation on the ImageLabels that have the Headshot image.
That’s what I’ve done but what I mean is that how would I make the actual headshot image smaller as stuff like the hair gets cut out of the imagelabel which makes it look bad
This might help.
From roblox
local Players = game:GetService("Players")
local player = Players.LocalPlayer
-- Fetch the thumbnail
local userId = player.UserId
local thumbType = Enum.ThumbnailType.HeadShot
local thumbSize = Enum.ThumbnailSize.Size420x420
local content, isReady = Players:GetUserThumbnailAsync(userId, thumbType, thumbSize)
-- Set the ImageLabel's content to the user thumbnail
local imageLabel = script.Parent
imageLabel.Image = content
imageLabel.Size = UDim2.new(0, 420, 0, 420)
No… Not really. I already have that as a thing but what I want is to make the actual headshot smaller but keep the headshot inside of the imagelabel > that doesn’t change anything
What is the thumbnail size you have it set to?
Size420x420 > changing it any lower and higher does absolutely nothing to the size for me > only decreases quality of the image
Oh, well I am not sure that there is a way to get a avatar headshot where the camera is zoomed out so that the hair doesn’t cut out.
You can check these posts and see if there is maybe a different avatar headshot type which you would like. (And which doesn’t cut out certain hats or hairs.)
When I use this code and scale the image label it scales but like @MatkeFTW said idk if there is a way to get the image zoomed out enough for someone’s large accessories don’t get cut out.
this is the edited version
local Players = game:GetService("Players")
local player = Players.LocalPlayer
-- Fetch the thumbnail
local userId = player.UserId
local thumbType = Enum.ThumbnailType.HeadShot
local thumbSize = Enum.ThumbnailSize.Size100x100
local content, isReady = Players:GetUserThumbnailAsync(userId, thumbType, thumbSize)
-- Set the ImageLabel's content to the user thumbnail
local imageLabel = script.Parent
imageLabel.Image = content
that doesn’t change much from the original script
The only way that I can fix this problem is to use the script above but change local thumbType = Enum.ThumbnailType.HeadShot
to local thumbType = Enum.ThumbnailType.AvatarThumbnail
. With this, you get the entire avatar without any cutout parts, but you do get the entire avatar, not just the headshot, so I think you could do this and add a frame or something to cover up the avatar leaving the avatar headshot exposed. Other than this I don’t think there is a better way to do this.