Nepzerox
(noah)
October 5, 2021, 8:21pm
#1
Hey there! Right now, I’m creating an admin system and am trying to work with the commands frame that informs the player about the commands in it. I’ve been trying for a while and am not able to get it to go straight down. While it almost goes straight down, it doesn’t to a point where it’s significantly noticeable.
The frame:
My code:
script.Parent.MouseButton1Down:Connect(function()
script.Parent.Parent.Parent.Commands:TweenPosition(UDim2.new(0, script.Parent.Parent.Parent.Commands.Position.X.Offset, 1, 0), "Out", "Quad", .3)
end)
Any help or feedback would be greatly appreciated.
(Yes, I know the UI is ugly, I’m still working on it)
1 Like
I think you should use math.rad. Idk if it applies to tweenservice tho.
1 Like
Nepzerox
(noah)
October 5, 2021, 8:29pm
#3
It doesn’t, and even if it did, isn’t that usually for rotation?
D0RYU
(nici)
October 5, 2021, 9:13pm
#4
Nepzerox:
.Offset
why are you messing with the Offset and not scale?
1 Like
overflowed
(overflowed)
October 5, 2021, 9:14pm
#5
Maybe replace the 2nd argument (script.Parent.Parent.Parent.Commands.Position.X.Offset
) with:
script.Parent.Parent.Parent.Commands.AbsolutePosition.X
I’m speculating that the Commands panel has a scale component that isn’t accounted for when you tween it
1 Like