So my script (Not a local script) is in a GUI frame. I’m trying to Tween a mesh part and when press the GUI button it does nothing.
- The last output is in line 9 when I press the button
My Script
--Locals--
local Door = game.Workspace:WaitForChild("FrontDoor")
local TweenService = game:GetService("TweenService")
local tweenInfo = TweenInfo.new(5, Enum.EasingStyle.Bounce, Enum.EasingDirection.Out)
local TweenClosed = TweenService:Create(Door, tweenInfo, {Position = Vector3.new(482.308, 61.995, -473.264)})
local TweenOpen = TweenService:Create(Door, tweenInfo, {Position = Vector3.new(482.308, 42.813, -473.264)})
--
script.Parent.MouseButton1Click:Connect(function()
print("lockdown") -- Right here is the last output I get from the script
TweenClosed:Play()
wait(5)
TweenClosed:Pause()
print("Tween Closed done")
--
wait(60)
--
TweenOpen:Play()
wait(5)
TweenOpen:Pause()
print("Tween Open done")
end)
-- Door open Vector3 482.308, 61.995, -473.264
-- Door closed Vector3 482.308, 42.813, -473.264