Help with smooth cutscene

Hello!

I’m trying to make a smooth cutscene in which your camera traverses through a vent to the other side, however it doesn’t work as smoothly as intended. video

local rsv = game:GetService("ReplicatedStorage"):FindFirstChild("vententer1")
local cam = game.Workspace.Camera
local player = game.Players.LocalPlayer
local ts = game:GetService("TweenService")
local vp = game.Workspace.vp1
local vpe = game.Workspace.vp1end

local tweeninf = TweenInfo.new(
	1,
	Enum.EasingStyle.Linear,
	Enum.EasingDirection.Out,
	0,
	false,
	0
)

local tweenventinf = TweenInfo.new(
	1,
	Enum.EasingStyle.Quint,
	Enum.EasingDirection.Out,
	0,
	false,
	0
)


local tween1 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2A.CFrame})
local tween2 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2B.CFrame})
local tween3 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2C.CFrame})
local tween4 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2D.CFrame})
local tween5 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2E.CFrame})
local tween6 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2F.CFrame})
local tween7 = ts:Create(cam, tweeninf, {CFrame = game.Workspace.campart2G.CFrame})
local vpt = ts:Create(vp, tweenventinf, {CFrame = game.Workspace.vp1end.CFrame})

rsv.OnClientEvent:Connect(function()
	vp.CanCollide = false
	vpt:Play()
	wait(0.6)
	cam.CameraType = Enum.CameraType.Scriptable
	player.Character.HumanoidRootPart.CFrame = game.Workspace.tppart2.CFrame
	tween1:Play()
	wait(0.5)
	tween2:Play()
	wait(0.5)
	tween3:Play()
	wait(0.5)
	tween4:Play()
	wait(0.5)
	tween5:Play()
	wait(0.5)
	tween6:Play()
	wait(0.5)
	tween7:Play()
	wait(0.5)
	cam.CameraType = Enum.CameraType.Custom
	end)

The camera and the vent cover are being tweened.

The cutscene in general just looks choppy and isn’t quite right. Thanks for any help.

1 Like

Well… i dont know how to help without a video… the script seems fine…

1 Like

horror game untitled - Roblox Studio (gyazo.com)

It seems your Cframe blocks are too far apart… How CFrame and tweening works is that the coordinate frame holds the exact position and orientation… tween matches it down to the time. That is how tween works.

So, your camera wont have rotated all the way until the END of the tween.
This is probably what is making it look choppy.

You might need to add more blocks, or more tweens to fit the orientation. The way to fix the orientation with more blocks is to make the CFrame blocks closer. The way to fix the orientation with the tweens is to make seperate tweens for rotation and position.

And also, your camera has no time to breathe… this means it will turn immediately when the tweening is done. you should fix that

1 Like

Okay. After following some of your advice, here is what I’ve come up with. horror game untitled - Roblox Studio (gyazo.com)

1 Like

Looks good. I hope your game goes well!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.