✓ Accepted answer
The TweenPosition function has multiple parameters (variables you put in the parenthesis)
This is how you would do a correct tween (implying you want a linear tween over 2 seconds)
local settings = script.Parent
local graphics_q = script.Parent.Parent.Graphics_Q
settings.MouseButton1Click:connect(function()
graphics_q:TweenPosition(UDim2.new(120, 0, 0, 0), "Out", "Linear", 2)
end)
The first parameter is a new position you want to tween to, the next one is either "In", "Out", or "InOut", this is setting the EasingDirection, next is the EasingStyle, the third is the time it takes for the tweening to complete. There is also an optional fourth boolean you can put (true or false) that will allow you to "override" the function and stop it to do a separate tween.
1 comment
Thnaks again magic beard...