- Home /
Best way to create cutscene without buying from the asset store?
I am working on a project and i want a cutscene which is about 20-30 seconds long.. And I will have many, the longest I guess will be for about 1-2 minutes... Is there a way to create cutscenes and not make an giant animation? Or is it best to make a giant animation? The cutscene will include the world and running and jumping so t me it seems easiest to not have to create an animation ad animate that you walk
I'd write a custom cutscene manager, it shouldn't be too difficult. Start with delcaring a custom class which holds any info about what a GameObject does during a cutscene: at which point of time it does something, where it moves to (and additional waypoints and how long it waits in between), at which speed it moves, same for rotation, etc. Create an array of your custom class, the elements will be the "keys" of your timeline. Then, in Update(), just use a timer to keep track of the cutscene time. Each frame, check all elements in the array wether they have reached the time to do something, and if yes, make them do whatever they should do.
Answer by ScaniX · Jul 06, 2016 at 10:38 PM
I did something like that as well. I have a main class DialogSystem (weird name as it was initially only intended to do the messages). You can call Add() with implementations of an interface (DialogStep in my case) which has methods like: Update(), IsAsynchronous(), IsFinished(), CanBeSkipped(), StepOver() (to finalize some values in case the whole step is skipped before it was even started).
The DialogSystem has a queue of all added steps and gets a new one if all synchronous steps are finished. In its Update() method it calls Update() on all current steps (zero or one synchronous and zero or more asynchronous).
I have several implementations, like:
WalkTo: Moves the player across some waypoints to a destination.
Transition: Has a callback that is called with a float from 0 to 1 to animate just anything.
Callback: For a oneshot thing like turning something on/off
I use this for a lot of things inside of the game. In case of a real cutscene the first step is always to show the cutscene camera overlay (black bars) and disable player input. And the last one undos those steps to give the control back to the player.
If the cutscene gets complicated it can be quite troublesome to get the timing right, because you will have to check it out in play mode again and again as there is no time slider like in the Unity animation (unless you make one yourself), but what I did to improve this situation is to add a method to be able to skip to a specific step in my animation, so I won't have to play it from the beginning while testing.
Your answer
![](https://koobas.hobune.stream/wayback/20220612084244im_/https://answers.unity.com/themes/thub/images/avi.jpg)