Issue with Tween Size

This is a script when you hover it makes it bigger. Its not working:
The sound and it prints works.

local sound = game.ReplicatedStorage.OtherSounds.MouseEnter_Leave

script.Parent.MouseEnter:Connect(function()

sound:Play()

print("MouseEntered")

script.Parent:TweenSize(UDim2.new(0, 382, 0, 121))

end)

script.Parent.MouseLeave:Connect(function()

sound:Play()

print("MouseLeft")

end)

edit: I know its the tweenSize line because without it everything works fine.
The printing works AND there are no errors at all

2 Likes

All help greatly appreciated!!!

You need to provide the rest of the arguments of the TweenSize function.

So do I need to do all of them?

Shall this work?

object:TweenSize(UDim2.new(0, 382, 0, 121, Enum.EasingDirection.InOut, Enum.EasingStyle.Sine, 0.5))

didnt work for some reason…

I added the arguments but its not working

You put all the arguments inside the UDim2

1 Like

Why is this- No, thats not right, I do position tweening and you-

What he means by that is that your Udim2.Values should be inside a bracket, and every other arguments outside.

the reason the tween isn’t working is because your button is the same size as the size you’re trying to tween. try chaining it to something slightly bigger.

2 Likes

Yeah, like this


object:TweenSize(Udim2.new(0,0,0,0),”In”,”Quint”,1,true)


1 Like

Only for the second time and above.

1 Like