|
| 28 May 2017 02:59 PM |
I wrote this script under StarterPlayerScripts and it doesnt seem to be working correctly:
local camera = workspace.CurrentCamera local player = game.Players.LocalPlayer
local function setupCamera() camera.CFrame = CFrame.new(workspace.pos.Position, workspace.Part.Position) end
setupCamera()
Instead of placing the camera where I want it, it places the camera on some position based on where my camera was before I clicked "play" in studio. Why is this happening?
|
|
|
| Report Abuse |
|
|
|
| 28 May 2017 03:02 PM |
you're giving the rotation of the CFrame a Position Vector3 value, try giving it a Rotation Vector3 value?
|
|
|
| Report Abuse |
|
|
|
| 28 May 2017 03:12 PM |
| A rotation vector3 value? I thought the camera just places itself at the first ####### ##### ### ###### at the second vector3 value. |
|
|
| Report Abuse |
|
|
|
| 28 May 2017 03:14 PM |
places itself at the first VectorthreeValue and pointsAt the secondVector 3 value.
|
|
|
| Report Abuse |
|
|
|
| 28 May 2017 03:36 PM |
ahhh I got it. I had to change the camera type to "scriptable"
|
|
|
| Report Abuse |
|
|