local target = workspace.Part local camera = workspace.CurrentCamera camera.CameraType = Enum.CameraType.Scriptable camera.CameraSubject = target local angle = 0 while wait() do camera.CoordinateFrame = CFrame.new(target.Position) --Start at the position of the part * CFrame.Angles(0.4, angle, 0) --Rotate by the angle * CFrame.new(1, 1, 10) --Move the camera backwards 5 units angle = angle + math.rad(2) wait (5) game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Humanoid game.Workspace.CurrentCamera.CameraType = "Custom" break end
this script will not work, plz help
You have a few problems with your script:
-You have a while loop that only runs once.
-You lack a loop that will rotate around the part
local target = workspace.Part local camera = workspace.CurrentCamera camera.CameraType = Enum.CameraType.Scriptable camera.CameraSubject = target local angle = 0 while angle < math.pi*2 do --this will do one full rotation before returning the camera to normal camera.CoordinateFrame = CFrame.new(target.Position) --Start at the position of the part * CFrame.Angles(0.4, angle, 0) --Rotate by the angle * CFrame.new(1, 1, 10) --Move the camera backwards 5 units angle = angle + math.rad(2) wait() end game.Workspace.CurrentCamera.CameraSubject = game.Players.LocalPlayer.Character.Humanoid game.Workspace.CurrentCamera.CameraType = "Custom"