How would I use CFrame.Angles to change camera angle?

Hello! I am a relatively new developer, so please pardon any mistakes with logic, grammar, etc.

  1. What do you want to achieve?
    I am currently trying to make a camera script that faces the logo of my game.

  2. What is the issue?
    I cannot figure out how to implement CFrame.Angles into the camera script. If I try to implement CFrame.Angles on the same line as the CFrame, there would be no effect.

Code:

wait(0.5)

local camera = workspace.CurrentCamera
local CameraPartForTitle = game.Workspace.CameraPartForTitle

camera.CameraType = "Fixed"
camera.Focus = CameraPartForTitle.CFrame
camera.FieldOfView = 60
camera.CFrame(-22.7, 168, 30) CFrame.Angles(45, 0, 0)

I think I may be using the wrong camera type, but I am not sure which one to use.

You Use the Scriptable CameraType to Script the Camera


To Change the Camera Angle, you do this:

camera.CFrame = camera.CFrame * CFrame.Angles(45,0,0)

This isnt how you use CFrame Either, It’s like this:

camera.CFrame = CFrame.new(-22.7, 168, 30)
1 Like

Wow. I look like a fool posting this. Thanks!

Not Really,

Its kind of a common thing when getting used to CFrame

Here is some Documentation, Sorry if it looks overwhelming.

Should help you understand it better.

1 Like

I’ve gotten the basic idea of Luau, so it isn’t a mess to me.

Thanks for the resource though.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.