Help With Camera

I made a script that makes the player’s camera look at a part, like a cut seen.

-- Function to stop camera movement and reset to player's view
local function resetCamera()
	cam.CameraType = Enum.CameraType.Custom
end

I don’t know how to make the camera do this

instead of this

Screenshot 2024-02-05 at 12.01.41 PM

You can use CFrames and just use trial and error method to get the best one so far, I worked a lot with CFrames before so this might work:

cam.CFrame = Part.CFrame * CFrame.new(0,5,7) * CFrame.Angles(math.rad(-30),0,0)

you can really just keep changing the CFrame parameters and see how the camera changes. but this should work ^

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