Advertisement
Prephy

Camera script

Feb 3rd, 2021
285
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. local camera = workspace.CurrentCamera -- finds the camera
  2. local Run = game:GetService("RunService")
  3. local part = workspace.CameraView -- name of my camera part
  4. camera.CameraType = Enum.CameraType.Scriptable
  5. camera.CameraSubject = part
  6.  
  7. local function OnChanged()
  8. camera.CFrame = part.CFrame
  9. wait()
  10. end
  11. Run.RenderStepped:Connect(OnChanged)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement