What are Cinemachine and Timeline?
It’s no secret that AAA games cultivate cinematographic concepts and incorporate them into their interactive worlds to form an enhanced experience. You would think that carrying out such a meticulous task would entail countless hours of coding to reach such a level of precision, however, as game engines and editors have evolved, so have their capacity to carry out complex tasks without having to create them from scratch. This brings us to the stars of today’s article — cinemachine and timeline in the Unity Editor.
Objective: Learn what Cinemachine and Timeline are, why you should use them and how to install Cinemachine in Unity.
Table of Contents
· What is Cinemachine?
· How to Install Cinemachine
· What is Timeline?
What is Cinemachine?
Cinemachine is a powerhouse when it comes to crafting cameras that can achieve cinema-level quality. This Emmy award-winning feature consists of a modular suite of camera tools completely dedicated to easing the use of multiple cameras in your scene with an added cinematographic touch unique to its repertoire. By adding virtual cameras native to cinemachine, you can create a myriad of different shots to craft truly intricate scenes. No longer will you be struggling to handle the often clunky main camera to get the best shots!
This tool is so sophisticated that it can be used in films as much as it can be used for game development. When it comes to the development side of things, it significantly reduces the workload and speeds up the development process by allowing you to test, apply and iterate on demand. Furthermore, this is not limited to cutscenes alone, they are fully applicable to gameplay from first-person shooters, to even top-down games(any kind of game really!)
I will be going over how to use it and camera features more in-depth in the article, but for now, let’s find out how you can install this for your project!
How to Install Cinemachine
- Go to Window → Package Manager
2. Search for Cinemachine in the search bar then click on Install once you find it.
Note: If you have trouble finding it, make sure you selected Unity Registry in The Packages dropdown menu.
If an error message pops up after installation, simply restart Unity. This will allow it to register Cinemachine as an available package.
3. To make sure Cienmachine is properly installed, you can access its repertoire via the right-click menu in the Inspector.
or via the top GameObject menu.
Now that we’ve covered Cinemachine, let’s explore Timeline!
What is Timeline?
If you’ve ever used a video editor, you might feel right at home with Timeline since they essentially accomplish extremely similar functions with similar interfaces. Timeline is a built-in feature in Unity that allows you to edit sound, animations, control objects, particles…etc. Timeline enables you to create a sequence with all the necessary elements in a place where they will play out in a linear fashion; you can think of it as an advanced version of the animation window. Things like chest opening sequences, victory sequences and such can be achieved through this.
You can find Timeline under Sequencing in the Window menu.
When your Timeline is populated, it might look kind of like this.
The segments marked in the image above are where the main bulk of actions happen in the timeline, these are known as tracks.
The main types of tracks are as follows:
- Activation Track: Activates or deactivates objects
- Animation Track: Controls the transforms of an object, including animation.
- Audio Track: To control audio whether it’s sound effects or music.
- Control Track: Overall control over objects and any controllable elements.
- Playable Track: scripting
When you use Cinemachine in combination with Timeline, you have the most control over your scenes and intricate gameplay elements. In the coming articles, I will be exploring cinemachine, and then I will be doing the same with Timeline. Once both have been explored, I will be discussing how they can be implemented together.