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

What is UDim2.new used for?

What is UDim2.new used for and what does it mean?

2 answers

✓ Accepted answer

UDim2.new is used for creating a new UDim2 (similar to how Vector3.new creates a new Vector3).

UDim2 is a data type ROBLOX added for positioning GUIs (just as Vector3 was added to position things such as blocks). UDim's have an Offset and a Scale, and UDim2's have an X offset and Scale and a Y Offset and Scale (hence the name UDm2, since it is made up of 2 UDims).

If you want to learn how to actually use UDims for creating a GUI, there are many tutorials available on different websites. Here's a link to one ROBLOX wiki tutorial: http://wiki.roblox.com/index.php/Beginner%27s_GUI_Tutorial

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