Day 54 — Preparing a cutscene in Unity

Connor Fullarton
2 min readMay 8, 2021

Hey and welcome!

Now let’s get started with looking into composing a cutscene for our game! Let’s open up the main scene for the game which is located in Game > _Scenes. Once on here click on the sleeping guard object that’s by the security desk and then set its active status to false.

We’re going to be composing a cutscene where our main character steals a keycard off the sleeping guard so we need tohide this guard as we’re going to be using an animation that we can film. Head over to Game > Prefabs >Cutscenes and then drag the Get_Card_Cutscene into the hierarchy and position this animation over by the desk.

The position I went for here was -1, -2, -110. With that in place it’s time to start adding in cameras to film our cutscene. At the top you’ll notice a tab called Cinemachine, click on that and then add in a virtual camera. Rename this to OTS (Over the shoulder) shot and then position your scene view into a position looking over Darren from behind and then press CTRL + Shift + F to center the virtual camera to where you’re looking.

Try and set it so that the dead zone (the square in the center) is just to the left of Darren’s head. Now we’ve got our first shot but to make use of Timeline which we’ll be looking into in the next articles we’re going to need a second shot to switch to. Create another virtual camera and call Mid Shot and center the camera so it looks like this.

This time try to get the deadzone to focus on the keycard lying on the guard’s lap.

With that done go ahead and create two empty game objects, call one of them Sleeping Guard Cutscene and the other one Virtual Cameras. Drag and drop the two virtual cameras into this and then drag and drop that into the sleeping guard cutscene object along with the animation itself. This keeps everything a bit neater and easier to track.

In the next article we’ll be looking into making use of this prep work with Timeline.

--

--

Connor Fullarton

Hey and welcome! My name is Connor and my goal here is to put out a daily post for a full year about my game development journey.