Hey, this GUI that's supposed to tween a shop down wont work. I am aware that I can't close it, but the opening part won't work. Any fixes? I'd say the only possible error would be in the variables, but im pretty sure the variables are correct. Thanks!

local player = game.Players.LocalPlayer
local StarterGui = game.Workspace:WaitForChild("StarterGui")
local ScreenGui1 = StarterGui:WaitForChild("Youtube")
local GUI = ScreenGui1:WaitForChild("Background")
local ScreenGui2 = StarterGui:WaitForChild("ScreenGuia")
local OpenorClose = ScreenGui2:WaitForChild("Openandclose")

OpenorClose.MouseButton1Click:Connect(function()
	GUI:TweenPosition(UDim2.new(0.5, -200,0.5, -150), 'Out', 'Bounce', 1)
end)


  • Clubberoni

5 comments

0

Its not in the variables im pretty sure, just redid them, still won't work.

0

Did you name them those specific names?

0

Yes

0

Are you sure it's not because your Gui is already in the position you're trying to tween to? Also try lower case C in connect.

0

you forgot to add the last parameter, in which it is a bool of if the gui tween can be changed midway