How to make the Camera move with a part

Hello,

All I want to know is how I can make the camera move with a Part. So what I mean is that the player sees in what direction the part is pointing. The part can move so I need to have the camera to move with it.

I already have the camera set to the part but I have no idea how I can make the camera move with the part.

If anyone knows how to do this please help me!

2 Likes

Use run service in a local script

local RunService = game:GetService("RunService")
local Camera = workspace.CurrentCamera --- make sure the camera is scriptable

RunService.RenderStepped:Connect(function()
	Camera.CFrame = -------Then just put your parts cframe here
end)
8 Likes