Hello,
I’m trying to animate a menubar have it go back to the original state when closed, but it’s not going too well due to how toe buttons work (ignore the incorrect buttons and the missing labels, that’s not an issue because it’s not programmed yet).
Because of this I was wondering what my best option is? Right now I have it working like this:
if Child:FindFirstChild("UIAspectRatioConstraint") then
task.delay(.45, function() --// wait for our animation
Child["UIAspectRatioConstraint"].Parent = ActiveMenu["Button"]
end)
else
print("no constraint!!")
local Constraint = Instance.new("UIAspectRatioConstraint")
Constraint.AspectRatio = 1
Constraint.Parent = ActiveMenu["Button"]
end
local TINfo = TweenInfo.new(.45, Enum.EasingStyle.Quart)
local ResetTween = TweenService:Create(ActiveMenu["Button"], TINfo, { Size = UDim2.new(0.198, 0, 0.696, 0) })
local ExpandTween = TweenService:Create(Child, TINfo, { Size = UDim2.new(.438,0,.696,0)})
ResetTween:Play()
ExpandTween:Play()
However, this behavior is definitely causing the snapping in the video. What’s my best option here?
Thanks.