I would like the image to be placed randomly across the screen but keep it relative to the players window so even if they resized it it would fill from the left border to the right border, but by doing (0,1) it only places on either the right side or left side. So i was wondering if anyone had a solution for this
local t = tick()
for i = 1, 5 do
local bubble = Instance.new("ImageLabel")
bubble.Name = "bubble"
bubble.Position = UDim2.new(math.random(0, 1), 0, 0, 0)
bubble.Size = UDim2.new(0, 100, 0, 100)
bubble.Parent = Player.PlayerGui.Loading.Frame
bubble.Visible = true
end
edit: this is the line im talking about
bubble.Position = UDim2.new(math.random(0, 1), 0, 0, 0)

1 comment
I'm also wondering if there's a possibility i can use camera.viewportsize? but im not sure how to implement it