You can write your topic however you want, but you need to answer these questions:
What do you want to achieve? I want to get a clear understanding on what are both Udim and Udim 2 Values
What is the issue? I saw a youtube tutorial use a udim/udim2 value and i’m unsure what those are
What solutions have you tried so far? I looked for videos on Youtube but there’s no videos explaining this
After that, you should include more details if you have any. Try to make your topic as descriptive as possible, so that it’s easier for people to help you!
Hello, so i’m new to udims and saw some scripting tutorials use a udim/udim2 value and i want to get a better understanding of what we use udim/udim2 values for so i can apply that knowledge and have a better understanding when working with the udims.
UDim2 is a value that contains X and Y - scale and offset, like this: UDim2.new(XScale, XOffset, YScale, YOffset)
It’s used in UI sizing and position
UDim is the same but without the offset values
EDIT: I’m wrong about the UDim. As @ThanksRoBama said, UDim is scale AND offset
A UDim is a pair of numbers, one for scale/“relative” the other for offset/“absolute” measurements. E.g. for position or size. AFAIK it isn’t actually used for anything.
A UDim2 is a combination of two UDims, one for X and one for Y. It’s used for setting the size and position of UI elements.
Thank you for the explanation i have a clearer understanding now. Thanks for your help
The scale of a UDim2 is equal to the percentage that it takes on the screen.
If we were to resize a gui like this: UDim2.new(1,0,1,0)
It would take the whole screen.
The offset is equal to the position in pixels.
Meaning that if you resize a part like this: UDim2.new(0,80,0,80)
It would look big on smaller devices, but small on larger screens.
A variety of GuiObject stylers/layouts use UDim values for their properties. For example a UICorner’s “CornerRadius” property.
Oh cool, haven’t played around with those yet