How to get ImageId of a decal?

I am working on a game with a feature that involves custom images but i have trouble loading them, i realised that it’s because an image has a different id to a decal, how can i get the image id from a decal?

There’s a pretty simple way of grabbing them.

I use the BTRoblox plugin for stuff like this. After you install the plugin to chrome or whatever you use, reload the Roblox website and navigate to your decal. From there you’ll see a few buttons above it, one of them allowing you to go directly to the image variant of your decal.

Hope this helps

1 Like

well i guess that helps, but i was looking for a way to do that through a script, or in the roblox website, since any player should be able to add images

1 Like

If you are just trying to get an ImageId from a decal, you can probably just make a string rbxassetid:// type of thing.

So like try,

local Decal = script.Parent.Whereitis.Decal
local ImageId = "http://www.roblox.com/asset/".. Decal.Texture

Check API Out, it will help you.

1 Like

Ok, so i by doing this I can convert the decal ID to iage id?

1 Like

Nope didn’t work, apparently decals also use image id.

Go to Decal properties then click on Texture. Copy the Id.

1 Like

I have to automate the process with a script as it is supposed to be custom image ids inputted by the player

I guess I’m not seeing the problem, if they provide the ID, you use the ID on the brick you are applying the image to via script. Does that not work?

No, the Image ID is different to the content ID, which is the most readily available one.

I guess I don’t know what the difference is. But, if they are providing the ID, why do you need to know where they get it?

The content id won’t load an image when placed in the image property of a decal, ImageGui,ImageLabel, etc.
Studio changes content id for the corresponding image id when you set it manually but that does not work on scripts for some reason.

1 Like

Where are you getting the content id? I do this all the time, i grab the ID from the URL paste it into the decal or texture field in Studio and it works. ? Maybe studio converts it for me somehow?

yes, that’s the content id. Studio automatically converts it.

let me explain further if you dont mind, the content id stores a decal, along with all of it’s properties, one of them being the image id, when you type the content id manually into the image property, the studio already knows to create the decal, parent it to nothing so it doesn’t show up, get the id property, and replace the content id for that one.
Therefore, that’s all i have to do
neat

3 Likes