Hi
I have a problem with GetUserThumbnailAsync because for some reason it’s not loading the image.
The game is published and api/http access is enabled.
It doesn’t throw any errors in the output.
code: (local script)
local Players = game:GetService("Players")
local player = Players:FindFirstChild(playerName)
-- 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
plrPicture.Image = content
And I have another question which I think may be the problem. Will it work while play testing in studio with 2 players or it only works with actual accounts?
It wont, the dummy clients have fake userIds(-1, -2, -3 etc.) which wont show valid results. Also the in-game image size has nothing to do with the error.
PS: To test your code functionality, you could use game.CreatorId(if it’s a published place) or pretty much any actual id(just make sure to change it back to player.UserId when publishing the game).