How to get an image of an accessory with :GetProductInfo()

I want to know how I would achieve a system where if the player typed a hat ID into a textbox, I would be able to get the image and name of the accessory, and be able to equip the player with it.

How would I get the image? I know of the IconImageAssetId thing, but for some reason its always set to 0.

For example if I use an Image Label, I set the Image to this hat ā€œBeautiful Hair for Beautiful Peopleā€ using the script below,

ImageLabel.Image = string.format("rbxthumb://type=Asset&id=%d&w=420&h=420",ASSETID)

The same goes for any image objects.

3 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.