Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make textlabel change position using tween service?

Asked by 4 years ago
01local TweenService = game:GetService("TweenService")
02local label = script.Parent
03 
04local Info = TweenService.new(
05    5--Length
06    Enum.EasingStyle.Sine, --Easing Style
07    Enum.EasingDirection.Out,  --Easing Direction
08    0, --Times repeated
09    false, --Reverse
10    1 --Delay (seconds)
11)
12 
13local Goals =
14{
15    Position = UDim2.new ({0.54, 0},{0.359, 0});
View all 22 lines...

Layout: https://i.gyazo.com/011f7d0f8baebd83a09ee9c93a2b0a54.png

I am trying to make the text label change position using the tween service

0
TweenPosition and TweenSize Pupppy44 671 — 4y

1 answer

Log in to vote
0
Answered by
sngnn 274 Moderation Voter
4 years ago
Edited 4 years ago

Your code is fine. You just mixed up a word. Instead of using TweenInfo.new, you used TweenService.new.

By the way, you don't need to go through all that to tween positions. You could instead just use TweenPosition.

1gui:TweenPosition(UDim2,EasingDirection,EasingStyle,Time,Override,Callback)

And there's no need to put the {},{} in your UDim2s. It's unnecessary.

Ad

Answer this question