Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

My camera script won't make the camera point down?

Asked by 5 years ago
workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable

workspace.CurrentCamera.CFrame = CFrame.new(22.2, 50, 25.9)
workspace.CurrentCamera.Focus = CFrame.new(22.2, 1.5, 25.9)

This script is suppose to make the camera look down at a giant green button, but it does not work, there are no errors in the output log.

0
it wont work because u didnt give it a CameraSubject F_F 53 — 5y
0
Hmm, okay. I will try that AlphaGamer150 101 — 5y
0
It did not work. AlphaGamer150 101 — 5y

3 answers

Log in to vote
1
Answered by 5 years ago
Edited 5 years ago

AlphaGamer150, you can make a the camera CFrame on a part instead of a position, and make the front surface of the part face down like this:

local camera = workspace.CurrentCamera

camera.CameraType = Enum.CameraType.Scriptable
camera.CFrame = workspace.looker.CFrame

make a part in workspace and make sure the front face of it is facing where ever you want and name it "looker", but you can name it whatever you want, but you need to change the name in the script

0
hmm, I will try that, thanks AlphaGamer150 101 — 5y
0
This worked AlphaGamer150 101 — 5y
0
Thanks for the help! AlphaGamer150 101 — 5y
1
yey User#23365 30 — 5y
Ad
Log in to vote
0
Answered by 5 years ago
wait()

workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable

workspace.CurrentCamera.CFrame = CFrame.new(22.2, 50, 25.9)
workspace.CurrentCamera.Focus = CFrame.new(22.2, 1.5, 25.9)
0
It does not work AlphaGamer150 101 — 5y
0
CFrame.Angles Lolamtic 63 — 5y
0
I will try AlphaGamer150 101 — 5y
0
with CFrame.Angles u cant look down :( Lolamtic 63 — 5y
Log in to vote
0
Answered by 5 years ago

I hope this works :) and also tell me what errors you get if it doesnt work!

workspace.CurrentCamera.CameraType = Enum.CameraType.Scriptable

workspace.CurrentCamera.CoordinateFrame = CFrame*CFrame.new(math.rad(22.2),math.rad(50),math.rad(25.9))
workspace.CurrentCamera.Focus = CFrame*CFrame.new(math.rad(22.2),math.rad(1.5),math.rad(25.9))
1
that doesnt work User#23365 30 — 5y

Answer this question