Welcome back, my fellow game developers.
In this video, as you can see,
we've created a victory,
seen nothing too special,
nothing too fancy, and just have the victory.
We have press any key, we collect,
we go to the main menu,
we start game, we just start again.
We have this weird for some reason,
we have the weapon not working properly.
We'll deal with that later on
for some reason when we move
through the levels might be
something got lost along the way.
But there is something I want to do in
this introduction and I would not think
of while doing the video and
that is adding the layer right here.
What I'm going to do is right-click in
the victory Canvas and the UI.
It will be very simple.
You will remember to do this.
I will call this D layer.
I will add the sprite to him,
send him to the night upsized.
And then I will create an animation
which is in the assets animation.
And let's see, I do believe
I made the dancing player in here.
Let's remove this and create my own dancing player.
So save that.
Yes, I want to replace them.
And then I will create the animation
of the dancing players or select these two,
set them in here,
and let's look at that.
Okay, that's too fast.
Stop, stop, stop, stop, stop, stop.
Copy this, paste it in here.
And let's see how that looks.
That's still extremely fast.
Let's add them five apart.
And yet it doesn't look very good.
But yeah, we, we would like to have
the player doing the Cancun on each side.
So we set one here, duplicate it,
set one here, but we are going to
make the scale of this minus one.
So now when we run the game,
I mean we run the victory screen. There you go.
We have two ken, Ken's,
the victory and plus NEG,
and then we go to the layer.
Excellent. So as you can see,
obviously there is a problem here.
We will look into it later on, but for now,
let's not waste any more time and let's get to
the victory screen finally.
0 case.
So now that we have a title screen,
we also want to create a vector screen.
So let's go ahead and do just that.
I'm going to go into my sprites,
that I say sprites, I meant my scenes.
And in scenes I'm going
to go ahead and create a new scene.
So right-click Create.
Oh, where's the scene?
And here, there we go.
So scene, and this will be
the victory screen or
Vector3 scene or whatever you wanna call it, hit Enter.
And let's just add it to the build settings right now.
So I'm going to drag the victory seen screen right here.
There we go. Open it up.
As you can see, we have
absolutely nothing will keep this thing simple.
It's very easy.
So I'm just going to go to your Canvas and this
will be the victory Canvas.
Nothing too much in here,
so just the canvas scaler that's set to 1920 by 1080.
So here we go, 1920.
Then AT, and you're very familiar with what's going on.
There is just one thing that will be maybe
just a little bit particular.
So I'm going to know not just yet,
not the challenge, just yet.
Let me just do a couple of things in here.
So this is our victory scene.
Let's see how it looks in game.
Okay, so right-click, let's create a image,
image here, and let's make sure that it
fills up the whole screen just like that.
Let's make it completely black.
Or you can keep it wide,
you can do whatever we want.
So I'm going to set to black.
And in here I'm going to say that I
also want to add a text Mesh probe.
The stacks.
Much pro will be the victory text.
There we go.
Let's make it auto size, increase the max.
And let's just make it a bit bigger.
There we go. Let's change, make it bold.
Make it in the middle.
Set it to the Robo.
And let's remove the underlay from here.
I'm not liking that underlaid that much water,
so let's just try it in here.
Victory with a couple of exclamation marks
and will increase the max to
fit this entire screen. There we go.
So factory.
And then what we're going to do is we're
going to duplicate this text,
move it down a bit,
and maybe sizes down.
Oops, and this will read.
Whereas it, so this will be the press any key.
And in here, press
any key to return to main menu.
So there we go, press any key to return to the main menu.
Let's just run this game and see how that looks.
And there we go.
So as you can see, victory press any
key to return to the main menu.
Very simple, nothing very complicated.
So I'm going to issue you
a small challenge to make
the text appear after two seconds.
So create an animation that makes the text appear after
two seconds and do this without any code.
And if you want an extra challenge
that I haven't included in the slide,
you can also create a way
for us to press any kind of button.
So we don't need to do a bit of research here.
So we press any button and then we go to the main menu.
That is also a challenge for you to do on both sides.
So that out of the way,
pause the video right now and then go to the challenge.
Okay, welcome back.
So what we're going to do in here
is we're going to just create an animation.
And we'll go into the assets animations
and let's create a new folder for the victory.
Text.
Opened up, opened up,
and hear beer.
After two seconds.
And I feel, look how many folders now we have.
And I feel this oh,
project was about creating
as many folders as you possibly can.
So welcome to the newest version
of creating the most folders that you can.
Anyways, let's continue on.
So we have this right here.
We're going to access the press any key text.
And in here I'm going to add a canvas group.
So this group.
So now we can play around with the Alpha.
There we go. And let's remove
the interactivity and the blocking the re-cast.
And in here we're going to press
record and after two seconds.
So we'll start off at 0.
And at the 2 second mark,
we are going to stay at 0 and maybe add the ticket,
maybe 1 second to load.
So in here this will become one.
But at the 2 second mark.
So as you can see, this will progress slowly.
So no, I don't want it to be like that.
I want to add 0, have this.
And how are we going to make the salt appears on its own?
Well, this will be probably a bit shocking to you,
but when we run the game,
this will happen all on its own.
So we start the level.
Then we come 12. There we go.
So we have the text appearing.
Obviously we do not want to have looping.
So I'm going to go to
the victory and make sure that we don't loop.
Now the next thing to do is to have
us press any key to go back to the main menu.
So I'm going to go into the scripts in here.
And where should we added?
Let's just add it in the UI.
I think this is a good place for it.
And let's right-click create C-sharp.
Victory. No, Actually, you know
what you are is a bad place for this.
Anyways, victory screen.
And this will be extremely simple.
But where should I put it?
If not in the UI folder?
Scripts, Let's see, traps,
weapons, menus, yeah, monument.
Sure, menu is a better place.
So let's drag this victory and to the menu folder.
And in menu folder, let's just add
the victory to the victory Canvas.
And in here Let's double-click opens
up, remove the start.
We don't need it for now.
And because we are going to
be changing from scene to scene,
we'll just add the UI scene manager or seen management.
And in here we are going to say
the input dot get key down or not,
sorry, not get key down because we
don't want any specific key.
So in here, I hope you tried to do a bit of research.
There is something called the any key down.
And we're just going to say that, and this is enough.
And you can see right here returns true.
The first frame, the user hits
any key or even a mouse button.
So then we are going to go to
Scene Manager dot load seen.
And we are going to load
the first scene because we know that always,
always, always the title menu will be
the first C. So save that.
We go back into our game.
We are going to run the gain.
So there we go, victory. Two seconds.
Press any key to continue at Demos button.
And now we are on
the title menu scene
and something that I forgot to tell you.
And that is that you can
actually maybe add some kind of music in here.
So you can see we can exit, start the game.
And there we go. We are again starting the game.
Whoa, what is that?
What is that?
Seems like some kind of flame thrower.
I think there is a small problem,
but let's not worry about that for now.
We'll fix the problem later on.
Obviously there is some kind of error and some kind of
part of the code because of the way we are transitioning,
but don't worry about that later on.
Maybe I believe the last section where we
actually do the advanced unity or advanced C-sharp,
One of those, we actually create
a very sophisticated way of going through levels,
keeping everything with us.
So we got out of the way.
Thank you for watching. I hope you are enjoying.
I hope you are staging all of your files.
Staging all of your files,
committing all of your changes.
Just made a victory screen.
Commit the changes.
And I'll see you in the next.