Tween camera without affecting orientation

Hi, I’m trying to make a death camera that looks down at the player and moves upwards.
I’m having difficulty tweening the camera upwards without affecting the orientation.

game.ReplicatedStorage.DeathEvent.OnClientEvent:Connect(function(character)
	CurrentCamera.CameraType = Enum.CameraType.Scriptable
	local offsetcframe = character.Head.CFrame*CFrame.new(0,5,0)
	CurrentCamera.CFrame = CFrame.lookAt(offsetcframe.Position, Vector3.new(-90,-180,0), Vector3.new(0,5,0))
	
	TweenService:Create(CurrentCamera, TweenInfo.new(game.Players.RespawnTime+1), {CFrame = character.Head.CFrame * CFrame.new(0,15,0)}):Play()
	
end)

You can make a CFrame without the Orientation values by doing this
CFrame.new(character.Head.Position)

i think the issue is with the second cframe value though. it moves to 0,15,0 just the orientation messes up.
your solution also gives a CFrame expected, got vector3

Maybe try something like this.

CFrame = character.Head.CFrame + Vector3.new(0, 15, 0)

“attempt to perform arithmetic (mul) on Instance and Vector3”.

I’m not sure you can add those together.

goal.CFrame = CFrame.new(humanoidRootPart.Position + Vector3.new(0, 5, -10))

solution for anyone else!

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