script.Parent.MouseLeave:Connect(function() TweenService:Create(script.Parent, argument, {ImageColor3 = Color3.fromRGB(138, 138, 138)}) end)
I need help, I don't know what to put for the 2nd argument on this script, as I've forgotten a bit of lua. I'd appreciate it if someone helped me.
You need TweenInfo
. Having TweenInfo.new()
means you would be using the defaults.
More info on TweenInfo here.
Here's an example:
local tweenService = game:GetService("TweenService"); local tweenInfo = TweenInfo.new( 1, -- Time Enum.EasingStyle.Quad, -- the easing style Enum.EasingDirection.InOut, -- easing direction 0, -- repeat count false, -- reverses or not 0 -- delay amount before starting ); local goal = { Size = Vector3.new(10, 10, 10); } local tween = tweenService:Create(workspace.Part, tweenInfo, goal); tween:Play();
If you would like to see how EasingStyles look, I suggest TweenSequence Editor plugin, which can be found here.