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

My camera manipulation is not working?

I have been learning lua for a small time and this week I picked up Camera manipulation. But for some reason my script is not working. There are no Outputs as well. Take a look at the script.

local cam = workspace.CurrentCamera

cam.CameraType = "Scriptable"

cam.CoordinateFrame = CFrame.new(-152.2, 40, 186.6)

cam.Focus = CFrame.new(36.4, 1, 145.2)

2 answers

wait() --important, a player needs to load first

local cam = game.Workspace.CurrentCamera
cam.CameraType = Enum.CameraType.Scriptable --i always use Enum, I think it's better
cam.CFrame = CFrame.new(-152.2, 40, 186.6) --you can just use CFrame

--Focus is not for CFrame, its for Objects!

Example:

cam.Focus = game.Workspace.Part

That should work^^

2 comments

0

@Bertox, thanks, but the Focus says, "Cframe expected, got object"

0

Oh, sorry

cam.CoordinateFrame = game.Workspace.[Put block its on here].CFrame* CFrame.Angles(-152.2, 40, 186.6)

1 comment

0

You probably copied it from somewhere, and that wasn't his question

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