Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I get the players image and put it on a part?

Asked by
sameb556 -12
3 years ago
Edited 3 years ago

I'm making a game and it involves the players image on a part, I've tried to put a surface gui on to a part and then put a image label with a local script inside it

local Players = game:GetService("Players")

local player = Players.LocalPlayer

local userId = player.UserId

local thumbType = Enum.ThumbnailType.HeadShot

local thumbSize = Enum.ThumbnailSize.Size420x420

local content, isReady = Players:GetUserThumbnailAsync(userId, thumbType, thumbSize)

local imageLabel = script.Parent

imageLabel.Image = content

imageLabel.Size = UDim2.new(0, 420, 0, 420)

but this doesn't seem to be working.

0
The problem is, that local scripts will only run inside startergui, starterpack, startercharacter and starterplayer. ColdFoxy07 76 — 3y

Answer this question