Hey all,
I’ve seen it before but not sure how it is done. How do you tween a gui from both sides?
Hey all,
I’ve seen it before but not sure how it is done. How do you tween a gui from both sides?
Can you elaborate further? I’m not sure I understand what you’re trying to get at
Set the GuiObject.AnchorPoint property to Vector2.new(0.5, 0.5)
. It will set the AnchorPoint to the center of the object instead of the top left.
ok, it didn’t work?
It is a textbutton inside a frame with a uilistlayout. I set the anchor point value but it still tweens left to right.
Could we see your script so we can help out a little more?
you can see the script, hierarchy, and that anchorpoint is set to 0.5, 0,5.
gui still tweens left to right.
Replace the :TweenSize()
with:
local tween = TweenService:Create(
new,
TweenInfo.new(0.8, Enum.EasingStyle.Sine, Enum.EasingDirection.In),
{Size = Udim2.new(1, 0, 0.14, 0)}
):Play()
Enum is an error?
eeeeeeeeeeeeeeeeeeee
Oops forgot a comma, try now (I edited the reply)
“Unable to cast dictionary”
pretty sure it’s about the UDim2?
local tween = TweenService:Create(new.Size,TweenInfo.new(0.8, Enum.EasingStyle.Sine, Enum.EasingDirection.In),{UDim2.new(1, 0, 0.14, 0)}):Play()
You forgot to type in Size =
here
Change line 36 for this:
TweenService:Create(new,TweenInfo.new(0.6),{BackgroundTransparency = 1}):Play()
Transparency is not a TextLabel property.
But everytime it’s written like that it has an error.
local tween = TweenService:Create(new.Size,TweenInfo.new(0.8, Enum.EasingStyle.Sine, Enum.EasingDirection.In),{UDim2.new(1, 0, 0.14, 0)}):Play()
“Unable to cast dictionary”
@BawTheSeal says to use this:
TweenService:Create(new,TweenInfo.new(0.8,Enum.EasingStyle.Sine,Enum.EasingDirection.In),{Size = UDim2.fromScale(1,0.14)}):Play()
ok, this works now, but it still tweens left to right.
You must replace this:
UDim2.fromScale(1,0.14)
For this:
UDim2.fromScale(-1,0.14)
it just tweens right to left now, off the screen.
Explain what you want, I still don’t understand xd
I want the textlabel to tween both sides at once.
Something like this?