Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why is my Cut scene not working properly?

Asked by 8 years ago

I am trying to make a cut scene but the cut scene has problems... The camera does not move for the cut scene and when its over a/s do not move the player camera, instead it stays in a fixed position...

It is also making making the camera move either instantly or not at all during the cut scene...

  wait()
    local Player = game.Players.LocalPlayer
    local Char = Player.Character
    local Cam = game.Workspace.CurrentCamera
    local ICover = Player.PlayerGui.IntroCover -- Replace intro cover with whatever you used for your Gui's Name

    Char.Humanoid.WalkSpeed = 0
    ICover.Cover.Visible = true

    Cam.CoordinateFrame = CFrame.new(73.04,11.9,134.03)
    Cam.CameraType = Enum.CameraType.Fixed -- We added this so we can manipulate the camera freely.

    for pos=73.04,11.9,134.03 do -- First Position and figure
        Cam.Focus = CFrame.new(5*pos,1*pos,22*pos)
        wait() -- We add this so the animation is smooth and does not finish instantly.
    end
    wait() -- The time it takes before the next point shows.
    for pos=-2.48, 15.73, 166.62 do -- Second Position
        Cam.Focus = CFrame.new(5,1,22)*CFrame.new(55*pos,44*pos,2*pos) -- We removed the *pos from the first one because we already animated that, The first CFrame value is where the camera last left off.
        wait()
    end
    wait()
--    for pos=0,0,0 do -- Third Position
--        Cam.Focus = CFrame.new(0,0,0)*CFrame.new(0*pos,0*pos,0*pos)
--        wait()
--    end

    ICover.Cover.Visible = false
    Cam.CameraType = Enum.CameraType.Follow
    Char.Humanoid.WalkSpeed = 16

1 answer

Log in to vote
1
Answered by 8 years ago

Just use camera Interpolation

cam:Interpolate(cframeposition,cframepositionlookingat, time)
Ad

Answer this question