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

What's the best method to make a single gui line?

Asked by 4 years ago

I'm trying to make a line that resembles a ruler line (for a media timeline). Is the best way to make a line in general a frame with the properties:

line.UDim2.new(0,2,0,100) --2x100 (Thin line)

Or is there another common / convenient method the community uses? This frame method just seems off to me, I'm pretty new to scripting and studio.

0
nope thats about the best way there is Wafflecow321 457 — 4y

1 answer

Log in to vote
1
Answered by
sheepposu 561 Moderation Voter
4 years ago
Edited 4 years ago

I'm pretty sure that is the best way to make a line. Since you are new I'll give you a tip so you don't make the same mistake as me. Roblox will automatically use the offsets for Size and maybe position when it comes to frames, buttons, etc. Use the first parameter so that it resizes based on the screen. Using the offset makes it a set amount of pixels and then it looks weird on different screens. The first parameter uses a decimal as like a percentage. Here's an example of a line using the first parameter

line.UDim2.new(0.001, 0, 0.1, 0)

Hope this helps!

Ad

Answer this question