Why is my tween not pausing inside a loop?
Asked by
4 years ago Edited 4 years ago
I have this script where it tweens the camera cframe and the blur, but I can't pause it in a loop.
01 | local plr = game.Players.LocalPlayer |
02 | local TS = game:GetService( "TweenService" ) |
03 | local camera 1 = game.Workspace.Camera 1 |
04 | local camera 2 = game.Workspace.Camera 2 |
05 | local camera = game.Workspace.CurrentCamera |
06 | local blur = game.Lighting.Blur |
08 | local TI = TweenInfo.new( |
10 | Enum.EasingStyle.Linear, |
11 | Enum.EasingDirection.Out, |
16 | local BlurTI = TweenInfo.new( |
18 | Enum.EasingStyle.Linear, |
19 | Enum.EasingDirection.Out, |
25 | local blurtween = TS:Create(blur, BlurTI, { Size = 50 } ) |
30 | local unblurtween = TS:Create(blur, BlurTI, { Size = 0 } ) |
33 | local camtween = TS:Create(camera, TI, { CFrame = camera 2. CFrame } ) |
34 | camera.CameraType = Enum.CameraType.Scriptable |
35 | camera.CFrame = camera 1. CFrame |
46 | script.Parent.MouseButton 1 Click:Connect( function () |
49 | camera.CameraType = Enum.CameraType.Custom |
50 | script.Parent.Parent:Destroy() |
Does anyone know how to pause the tween?