Ok, so I have a couple of GUI's in my place that rely on the TweenSize and the TweenPosition methods to work, but for some reason the methods are no longer working. They worked a few days ago, then suddenly they stopped working for some reason. I know it's not a script error because I get no errors when I access the developer console, and only the GUI's that have a TweenSize or TweenPosition method in them are not working. I'll provide some code:
function LevelUp(Player,Rank) local LevelUp = script.LevelUp:Clone() local Main = LevelUp.Frame Main.RankImage.Image = _G.Ranks[Rank][4] LevelUp.Parent = Player.PlayerGui Main.RankImage:TweenSizeAndPosition( --This is the line that doesn't work. It doesn't error or anything like that, it just doesn't work. All the code underneath it works though UDim2.new(0,60,0,80), UDim2.new(0.5,-30,0,0), Enum.EasingDirection.Out, Enum.EasingStyle.Linear, 0.2 ) wait(0.2) Main.RankNum.Text = "Rank: "..Rank local TitleText = "You have ranked up!" for i = 1,string.len(TitleText) do Main.Title.Text = string.sub(TitleText,1,i) wait(1/20) end wait(4) LevelUp:Destroy() end
Here's another block of code:
local NextRankXP = _G.Ranks[NextRank2][2] local RankScale = (PlayerXP - _G.Ranks[PlayerRank][2]) / (NextRankXP - _G.Ranks[PlayerRank][2]) RankBar.Tray:TweenSize(UDim2.new(RankScale,0,1,0),"Out","Sine",0.5) --Again, this doesn't work
Note #1: These lines of code are in normal scripts, not in LocalScripts, but that shouldn't be the problem because they were working before in normal scripts
Note #2: The tween methods work just find in play solo mode and in server mode, but not in play mode
Please help!
According to RbxDevTips, "Yesterday's client update broke TweenPosition/TweenSize when called from server scripts. Call them from local scripts instead."