How would I make your camera lock onto a part?

So in the game The Rake Remastered there’s an effect they did where when you see the monster, your camera sort of “locks on” to him. It makes you look in his direction and i’d like to know how to do that. I understand how the effect with the FOV is done I just don’t understand how the camera locks onto the Rake like that.

^ Credits to Bbrendofc on YouTube for the video. It would’ve taken too long to get the video I needed if it wasn’t for them.

1 Like

In a local script, this is written on phone so except Miss-spelling

local camera = workspace.CurrentCamera
local part --MUST be a part, give location, player will look at it.
game:GetService("RunService").Heartbeat:Connect(function()
	camera.CFrame = CFrame.LookAt(part.Position , part.Position)
end
--you can use tweenService, this is just a simple script to get you started.
2 Likes

So i ended up using this!

local Tween = TweenService:Create(camera,tweenInformation,goal):Play()

Thanks for the start I had no idea about CFrame.lookAt.

Your welcome, its barely used thats why alot of people might not know about it.

1 Like