In part of my game, I am using an images to display a loading GUI, but I want each box to expand in all directions then later shrink to their original size. How would I accomplish this?

for i = 1,10,1 do
	wait()
	script.Parent.Box1.Size = script.Parent.Box1.Size + UDim2.new(0,1,0,1)
end
wait()
for i = 1,10,1 do
	wait()
	script.Parent.Box1.Size = script.Parent.Box1.Size - UDim2.new(0,1,0,1)
end

1 comment

0

I would use tweening http://robloxdev.com/articles/GUI-Animations (You only need GUI:TweenSize() here)