Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

What is the difference between Udim2 and Vector 3?

Asked by 5 years ago

Udim2 is the XYZ. Vector 3 is the XYZ.

So what is the difference tho sorry im just a beginner.

3 answers

Log in to vote
2
Answered by
Alphexus 498 Moderation Voter
5 years ago

Before I explain, UDim2 does not have a Z coordinate.

UDim UDim stands for Universal Dimensions. UDim basically is the position and size of GUIs. It takes 2 parameters: Scale and offset.

UDim2 UDim2 is the same thing as UDim but it represents 2 UDims with a 2 dimensional coordinate plane with x and y coordinates. UDim2 has 4 parameters: xScale, xOffset, yScale, yOffset.

Vector3 Vector3 represents a 3 dimensional position of an object not including rotations.

To put it simply, UDim and UDim2 are positions for GUIs and Vector3 is positions for 3D objects.

0
would upvote but i cant User#25069 0 — 5y
0
I upvoted for you Quezzert. CeramicTile 847 — 5y
0
these two comments are wholesome iuclds 720 — 5y
Ad
Log in to vote
0
Answered by 5 years ago

UDim2 does not have Z, and has four parameters. It is used for guis only, because it is a 2d object simply on the player's screen. The four params are X Scale, X Offset, Y Scale, and Y Offset.

Vector3 is for Part positions, which are in a 3d environment. It takes three parameters: X, Y, and Z.

UDim2: UDim2.new(0, 0, 0, 0)

Vector3: Vector3.new(0, 0, 0)

Log in to vote
0
Answered by 5 years ago

Udim2 is for positioning a GUI while Vector3 is for positioning a part

Answer this question