I’m attempting to create a tooltip UI, this tooltip UI will pop up using :tweenposition.
The issue is, that sometimes it bugs out because a tween is already ongoing when the mouse leaves the icon.
The script does not have individual scripts pointing to each one of the objects which it should tween on.
for i, v in pairs(script.Parent:GetChildren()) do
if v:FindFirstChild("NeedsToBeTooltipped")then
v.MouseEnter:Connect(function()
script.Parent.ToolTip.TextLabel.Text = v.Name
script.Parent.ToolTip:TweenPosition(UDim2.new(0.365, 0,0.947, 0), "Out", "Quad", 0.3)
end)
v.MouseLeave:Connect(function()
script.Parent.ToolTip:TweenPosition(UDim2.new(0.365, 0,1, 0), "Out", "Quad", 0.3)
end)
end
end
I’ve recorded a video that might be helpful if you don’t understand what I mean.
If video doesn’t load- Dropbox - Desktop 2020.11.05 - 21.36.28.02.mp4 - Simplify your life