Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Make a camera follow an object?

Hi, there's many scripts that have a camera that follow a player, except what I want is a camera to follow an object named "ball" which corresponds to a soccer ball to make a TV kind of system but I'm unsure of how to get the camera to follow the ball instead of my character, if anyone could help I'd be really grateful.

2 answers

✓ Accepted answer

Use CameraSubject.

local cam = workspace.CurrentCamera
cam.CameraSubject = workspace.Part

More info here. Please accept answer if this helped!

3 comments

0

make sure it is set to scriptable as well, for more effects

0

Yes. Forgot to add.

0

Thanks, but what I'm looking for is a fixed camera point that points the direction of where the ball is and that doesn't follow it's every move.

local cam = workspace.CurrentCamera
cam.CameraSubject = workspace.YourPart
cam.CameraType = Enum.CameraType.Scriptable

or you can watch these vids to help https://www.youtube.com/watch?v=bkDp4fRbVZU&t=2s

https://www.youtube.com/watch?v=AOTEg91eXAc

https://www.youtube.com/watch?v=LdwNqyknyPU

4 comments

0

You could format your code aswell...

0

i just did lol

0

has he replied yet???

0

Thanks, but what I'm looking for is a fixed camera point that points the direction of where the ball is and that doesn't follow it's every move.

This discussion is preserved as it was. New answers, comments, and votes are closed.