How can I make a Camera Script to move the camera at the beginning of the game?

Hi, I tried to write a script where when the game starts the camera is fully on and seconds later the camera is down to be able to play. I tried to do it with cameraOffset, but I think it would be better to make the script create a block and the camera to be in the block, so that when the block is lowered, the original position is set.

1 Like

You need to be more detail in what you want as I do you understand what you want.


  • Menu were the camera rotation is based on the mouse position
  • Camera slowly moves round the map

Oh Im sorry. I try to explain myself well but my English is not my native language.

O now I understand so you want the camera to start at one point and move the the players character

1 Like

Make sure you set the client’s camera type to scriptable first, then you can only set e CFrame of the camera using the scripts.

1 Like

Yes, I tried to do it with the Humanoid Offset Camera but the result is very different.

It can be done using TweenService

(33) Roblox Cutscene Script Tutorial - YouTube

I really didn’t think it would come out. Well, in part it worked but when the camera is finished it does not stick to the head again

Set the camerasubject to the player’s humanoid

local TweenService = game:GetService("TweenService")
local Head = script.Parent:WaitForChild("Head")
local speed = script.Parent:WaitForChild("Humanoid")

speed.WalkSpeed = 0

local parte ="Part")
parte.Parent = workspace

local parte2 ="Part")
parte2.Parent = workspace

local parte3 ="Part")
parte3.Parent = workspace

local weld ="Weld")
weld.Parent = parte
weld.Part0 = Head
weld.Part1 = parte
weld.C0 =,200,0)

local weld2 ="Weld")
weld2.Parent = parte2
weld2.Part0 = Head
weld2.Part1 = parte2
weld2.C0 =,100,0)

local weld3 ="Weld")
weld3.Parent = parte3
weld3.Part0 = Head
weld3.Part1 = parte3
weld3.C0 =,7,0)

parte.Orientation =, 0, 0)
parte2.Orientation =, 0, 0)
parte3.Orientation =, 0, 0)

local camera = game.Workspace.Camera
local cutsceneTime = 3

local tweenInfo =

function tween (parte, parte2, parte3)
camera.CameraType = Enum.CameraType.Scriptable
camera.CFrame = parte.CFrame
local tween = TweenService:Create(camera, tweenInfo, {CFrame = parte2.CFrame})
local tween2 = TweenService:Create(camera, tweenInfo, {CFrame = parte3.CFrame})

camera.CameraType = Enum.CameraType.Fixed
camera.CFrame = Head.CFrame
speed.WalkSpeed = 7
tween(parte, parte2, parte3)

At the end of the script:

camera.CameraSubject = variableOfThePlayer.Humanoid

I get the orange line in variableOfThePlayer
and this error
Workspace.NUTRICORP.LocalScript:64: attempt to index nil with 'Humanoid'

Because it means the player object

local player = game.Players.LocalPlayer

camera.CameraSubject = player.Character.Humanoid

Ah, I fixed it, it should be inside the end, not outside