Advertisement
HowToRoblox

CutsceneScript

Jan 25th, 2020
4,449
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.57 KB | None | 0 0
  1. local cams = workspace:WaitForChild("Cameras")
  2.  
  3. local cam = workspace.CurrentCamera
  4.  
  5. local tweenService = game:GetService("TweenService")
  6.  
  7. wait(4)
  8.  
  9. cam.CameraType = Enum.CameraType.Scriptable
  10.  
  11.  
  12. for i, camPart in pairs(cams:GetChildren()) do
  13.    
  14.     local tweenInfo = TweenInfo.new(2, Enum.EasingStyle.Quint, Enum.EasingDirection.InOut)
  15.    
  16.     local goal = {CFrame = cams[i].CFrame}
  17.    
  18.    
  19.     local tweenToNextCamera = tweenService:Create(cam, tweenInfo, goal)
  20.    
  21.    
  22.     tweenToNextCamera:Play()
  23.    
  24.     tweenToNextCamera.Completed:Wait()
  25.    
  26. end
  27.  
  28. cam.CameraType = Enum.CameraType.Custom
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement