I'm new to coroutine.
local DoIt = true local Dot3 = coroutine.create(function() script.Parent.Dot3:TweenPosition(UDim2.new(.55,0,.3,0),"Out","Bounce",.1,true) script.Parent.Dot1:TweenPosition(UDim2.new(.55,0,.4,0),"Out","Bounce",.1,true) end) local Dot2 = coroutine.create(function() script.Parent.Dot2:TweenPosition(UDim2.new(.45,0,.3,0),"Out","Bounce",.1,true) coroutine.resume(Dot3) script.Parent.Dot1:TweenPosition(UDim2.new(.45,0,.4,0),"Out","Bounce",.1,true) end) local Dot1 = coroutine.create(function() script.Parent.Dot1:TweenPosition(UDim2.new(.35,0,.3,0),"Out","Bounce",.1,true) coroutine.resume(Dot2) script.Parent.Dot1:TweenPosition(UDim2.new(.35,0,.4,0),"Out","Bounce",.1,true) end) while DoIt do coroutine.resume(Dot1) wait(1) end
What i'm trying to do is, the first "Dot" is suppose to "Bounce" and when its up in the air, the second one should start to "Bounce" while the first one continues to go down. Why won't it do that? .. No Output,
The 2nd and third Rise. Then nothing happens.
Coroutines are actually evil, and very misleading.
Don't use coroutines for this. TweenPosition already runs asynchronously - Try looking into the Callback parameter of the GUI Tween Functions.