Hello, I want to make a cut scene animation when i press a button to play and the camera moves between 2 objects. The issue that i am experiencing is that when i press the button, it does the animation but i want the final position of the camera to be facing the other way around because it faces toward the original brick that it was positioned on. I have tried to rotate the brick but that didn’t make a difference.
My code:
local Camera = game.Workspace.CurrentCamera
local Player = game.Players.LocalPlayer
local pos2 = game.Workspace:WaitForChild("CustomCamPart")
local pos1 = game.Workspace:WaitForChild("CamPart")
local controls = require(game:GetService("Players").LocalPlayer.PlayerScripts.PlayerModule):GetControls()
controls:Disable()
script.Parent.MouseButton1Click:Connect(function()
Camera.CameraType = Enum.CameraType.Scriptable
local timeTaken = (Player.Character.Head.Position - pos2.Position).magnitude * 0.05
Camera:Interpolate(pos2.CFrame, pos1.CFrame, timeTaken)
wait(timeTaken)
end)
repeat wait() until Player.Character
Camera.CameraType = "Scriptable"
Camera.CFrame = game.Workspace.CamPart.CFrame
script.Parent.Enabled = true
script.Parent.Parent.Parent.Spawn.MouseButton1Click:connect (function ()
script.Parent.Enabled = false
Camera.CameraType = "Custom"
end)
I currently have a position behind the camera where the player is frozen, this is for a feature in the future and i want the camera to face the player.
I want it to face here:
but…
it ends up facing here:
i want the animation to play but to still be facing the way i am in the first image.