Hello, I am making a box opening system, however at the end of the animation for the opening tween moves some pixels for no reason, completely destroying the fluidity that I want to obtain, I have already tried everything.
function resetLine()
LineFrame.Position = UDim2.new(0, 0,0.5, 0)
for _, i in LineFrame:GetChildren() do
if i.Visible then
i:Destroy()
end
end
end
Button.Activated:Connect(function()
local items = openCaseF:InvokeServer("default")
if items then
local schem = LineFrame:FindFirstChild("itemSchem")
local t = TWEEN:Create(LineFrame,
TweenInfo.new(7, Enum.EasingStyle.Exponential, Enum.EasingDirection.Out),
{["Position"] = UDim2.fromScale(-9.5, schem.Position.Y.Scale)})
resetLine()
for i, r in items do
local pos = UDim2.new(schem.Position.X.Scale + (schem.Size.X.Scale + 0.01) * (i - 1), 0, schem.Position.Y.Scale, 0)
local item = schem:Clone()
item.Name = "item".. i
item.Position = pos
item.rarityFaded.ImageColor3 = rarities[r[1]]["Color"]
item.Parent = LineFrame
item.Visible = true
end
task.wait()
t:Play()
print(items[55])
end
end)