Hello, I've been trying to make a gate that opens vertically. Yet it doesn't work at all.
script.Parent.PromptButtonHoldEnded:Connect(function(plr)
local original = script.Parent.Parent
local up = script.Parent.Parent.Parent.Arrival
if plr.Team ~= game.Teams.CD then
local goalData = {CFrame = up.CFrame}
local tween = game.TweenService:Create(script.Parent.Parent,TweenInfo.new(4),goalData)
tween:Play()
goalData = {CFrame = original.CFrame}
local tween = game.TweenService:Create(script.Parent.Parent,TweenInfo.new(4),goalData)
tween:Play()
print("hi")
end
end)

1 comment
Tweens don't automatically yield, you'll have to add a wait(4) before starting the second tween