Level Dialogue


I needed something that will tell the player how well they did each level. So I need to make a Level rating system that will show at the end of each level. 

To help me make this I watched this tutorial. I first had to make the layout for it. I used the diamonds that the player collects to represent how well they did each level. I added a button below to allow the player either to replay the level or go on to the next level depending on how well they did the level. 

Next, it was to code everything together to make it all work. I first had to change my script for the chest to load the level dialogue whenever the player collides with it.  Load Level Status script

Once this was working I then had to code it so that depending on how many diamonds the player collects it will be given the player that many diamonds in the dialogue. For this, I used the gameobjectag to see how many "diamonds" there wherein the game before and working out a percentage of how well the player did collecting them.  Level Status code if the player got below 33% it will hide the gameobject button next level and make the replay button game object active set to true.

Get Sully

Leave a comment

Log in with itch.io to leave a comment.