Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

I need some help displaying the player's pic?

I am using a script from Stickmasterluke and I changed it a bit. Now I cant display the pic of the player and I need to use the pic for a game that I am making. can someone fix my script?

game.Players.PlayerAdded:connect(function(player) -- You have the player! 
plr = player.Name
print(plr)
end)
function check()
	if plr and plr.Parent~=nil then
		sp.Image="http://www.roblox.com/Thumbs/Avatar.ashx?x=120&y=225&Format=Png&username="..plr
	end
end

check()
plr.Changed:connect(check)

2 answers

That thumbnail URL only allows certain image widths and heights. 120 by 225 is not valid.

sp.Image="http://www.roblox.com/Thumbs/Avatar.ashx?x=110&y=110&Format=Png&username="..plr

1 comment

0

The more you know (;

Try This:

game.Players.PlayerAdded:connect(function(player) -- You have the player! 
print(player.Name)
end)
function check()
    if player and plr.Parent~=nil then
        sp.Image="http://www.roblox.com/Thumbs/Avatar.ashx?x=120&y=225&Format=Png&username="..player.Name
    end
end

check()
player.Changed:connect(check)

This discussion is preserved as it was. New answers, comments, and votes are closed.