Hello developers! I don’t know why my script is not working.
It should set the player camera to the part called “Part” This is a local script that is in StarterPlayerScripts.
task.wait(5)
local part = workspace.Part
local camera = workspace.CurrentCamera
camera.CameraType = Enum.CameraType.Fixed
while task.wait(0.1) do
camera.Focus = die.CFrame + Vector3.new(0,10,0)
end
task.wait(5)
local part = workspace.Part
local camera = workspace.CurrentCamera
local offset = CFrame.new(Vector3.new(0,10,0))
camera.CameraType = Enum.CameraType.Scriptable -- Instead of Fixed
while task.wait(0.1) do
camera.CFrame = die.CFrame + offset -- CFrame instead of Focus
end