Creating a Loading Screen
Allowing user feedback during long load scenes.
Once you have finished the loading screen, it is time to tie everything together by having the loading screen bridge the different scenes together. This is also a great method to let the players know that the game is still loading albeit a little long.
Creating a new Scene:
We start by creating a brand new scene, this scene will contain the loading elements. In this scene, we are provided with an background image and one progress bar image along with an overlay image for the progress bar. Start by creating an Canvas with an image element.
Set the anchor to free form and zero out everything (Left, Right, Top Bottom and Pos Z). This would align the image to fit the entire screen space.
Next, do the same process with the Progress bar and overlap elements, but refrain from using the free form anchor. Instead, we will anchor the progress bar on the middle left.
Position the progress bar on top of the red section, make sure you leave a bit of gap between the red and yellow bars.
Then in the Image type, we are going to select “Filled” and the Fill Method should be set to “Horizontal”. With this setting, this should give us the standard loading bar sequence.
Now we add some nice textures to the progress bar by positioning the overlay just on top of the progress bar. Since it is just a overlay object, we don’t need to do anything.
In the next Article, we will learn to script the loading bar and how to apply it during loading sections of the game.