Camera Script not working properly

  1. What do you want to achieve?
    A menu with the camera seeing a scene

  2. What is the issue?
    I used the code
    In the Menu, A LocalScritpt

workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable
workspace.CurrentCamera.CFrame=workspace.Statue.Model.Statue.HumanoidRootPart.CFrame
workspace.CurrentCamera.FieldOfView = 50

But it did not work, it did not show the scene that it is supposed to show

it should show this statue


but it showed the character instead

3. What solutions have you tried so far?
I looked in to the CurrentCamera in the workspace while testing, The CameraType did not set to Scriptable, it is still Custom for some reason.

1 Like
 workspace.CurrentCamera.CFrame=workspace.Statue.Model.Statue.HumanoidRootPart.CFrame

your second line, why are you saying HumanoidRootPart, is that a part of the statue

I think you forgot to set the ’ camera subject’

it is a part of the statue, there is no error at all, but it just dont work

and how do you set the camera subject?

1 Like

you would say:

workspace.CurrentCamera.CameraSubject = workspace.Statue.Model.Statue.HumanoidRootPart

or you can create a variable like this:

local CurrentCamera = workspace.CurrentCamera
local Statue = statue.Model.Statue.HumanoidRootPart


CurrentCamera.CameraType = Enum.CameraType.Scriptable
CurrentCamera.CameraSubject = Statue
CurrentCamera.CFrame = Statue.CFrame
CurrentCamera.FieldOfView = 50

You should use Enum.CameraType.Scriptable instead of a string.