Making a menu and I want it to have this cool hover effect. I’ve played with a hover effect with gui in the past and knew what I was doing. Well all of a sudden it doesn’t do what I want it to do. I have no idea what I have done wrong. Local script is inside the gui.
https://gyazo.com/e14f34a9c8696b86ad3f4eecad77b6b2
script.Parent.MouseEnter:Connect(function()
script.Parent:TweenSize(UDim2.new(0, 350,0, 165),"Out","Linear",0.2, true)
script.Parent.CasualButton:TweenSize(UDim2.new(0, 316,0, 75),"Out","Linear",0.2, true)
script.Parent:TweenPosition(UDim2.new(0.047, 0,0.269, 0),"Out","Linear",0.2,true)
script.Parent.ImageColor3 = Color3.new(1, 1, 1)
script.Parent.CasualButton.TextColor3 = Color3.new(0, 0, 0)
end)
script.Parent.MouseLeave:Connect(function()
script.Parent:TweenSize(UDim2.new(0, 334,0, 100),"Out","Linear",0.2, true)
script.Parent.CasualButton:TweenSize(UDim2.new(0, 245,0, 40),"Out","Linear",0.2, true)
script.Parent:TweenPosition(UDim2.new(0.757, 0,0.753, 0),"Out","Linear",0.2,true)
script.Parent.CasualButton:TweenPosition(UDim2.new(0.128, 0,0.299, 0),"Out","Linear",0.2,true)
script.Parent.ImageColor3 = Color3.new(0, 0, 0)
script.Parent.CasualButton.TextColor3 = Color3.new(1, 1, 1)
end)```