Basic to Intermediate Unity 3D - Create a Marvel Hulk's First Person Shooting (FPS) Game in 3 Hours | Rexcel Cariaga | Skillshare

Playback Speed


  • 0.5x
  • 1x (Normal)
  • 1.25x
  • 1.5x
  • 2x

Basic to Intermediate Unity 3D - Create a Marvel Hulk's First Person Shooting (FPS) Game in 3 Hours

teacher avatar Rexcel Cariaga, Virtual Reality Game Professor

Watch this class and thousands more

Get unlimited access to every class
Taught by industry leaders & working professionals
Topics include illustration, design, photography, and more

Watch this class and thousands more

Get unlimited access to every class
Taught by industry leaders & working professionals
Topics include illustration, design, photography, and more

Lessons in This Class

31 Lessons (3h 25m)
    • 1. Introduction to this Course

      0:49
    • 2. Installing Unity 2019

      1:31
    • 3. Creating a New Project in the Unity Hub

      2:04
    • 4. Installing Standard Assets

      2:27
    • 5. Terrain Part 1

      9:34
    • 6. Terrain Part 2

      8:23
    • 7. Terrain Part 3

      11:33
    • 8. Basic Transform Coding

      10:35
    • 9. Transform vs Translate and Start vs Update

      11:26
    • 10. Input Movement via Game Controllers

      10:29
    • 11. Particles

      6:49
    • 12. Adding a Teleport View

      5:54
    • 13. Teleport Character

      6:18
    • 14. Rigging Thanos

      9:16
    • 15. Rigging Hulk

      5:42
    • 16. Animating Thanos

      8:46
    • 17. Animation Hulk Part 1

      6:30
    • 18. Animating Hulk Part 2

      8:26
    • 19. Animating Hulk Part 3 (Jump)

      5:25
    • 20. Animating Hulk Part 4 (Smash)

      5:10
    • 21. Fixing Hulk Collisions and Teleport

      5:43
    • 22. UnderWaterScript for Hulk

      4:06
    • 23. Shooting Animation for Hulk

      8:40
    • 24. Destroy

      3:53
    • 25. Instantiate

      8:09
    • 26. Transform Forward

      6:23
    • 27. Coding the Shooting for Hulk Part 1

      9:34
    • 28. Coding the Shooting for Hulk Part 2

      4:46
    • 29. Coding the Shooting for Hulk Part 3

      4:02
    • 30. Adding Sounds FX and BGM

      5:08
    • 31. Publishing Your Game

      7:50
  • --
  • Beginner level
  • Intermediate level
  • Advanced level
  • All levels
  • Beg/Int level
  • Int/Adv level

Community Generated

The level is determined by a majority opinion of students who have reviewed this class. The teacher's recommendation is shown until at least 5 student responses are collected.

295

Students

--

Projects

About This Class

Hi there! Do you want to learn Video Game Development?  Do you want to know how EA Games, Blizzard, Ubisoft, etc, create their games? 

In this course, I will be teaching you basic to intermediate Unity 3D by creating your own Marvel's Hulk Shooting Game. 

We will start by creating an environment (terrain) from scratch by adding trees, grass, and water.  We will then animate Hulk and Thanos within Unity. We will also add codes in our project to create a shooting game. Since this course is Marvel Avenger's inspired, we will also add a teleport portal in your game similar to that of Dr. Strange's superpower. At the end of this course, you will have your own standalone game which you play in Windows or MacOSX and show it to your friends. 

What you'll learn from this lifetime-access course: 

  • Learn the Unity Interface
  • Design your own Environment from scratch - no prior knowledge required!
  • Learn Basic and Advance Coding in C# 
  • Create Particle Effects in your Game
  • Animate and Code 3D Characters - no prior 3D knowledge required!
  • Add Sounds in your Game
  • Develop your own Shooting Game - no prior programming knowledge required!
  • Add the Main Menu
  • Publish your Game for Windows and Mac



  • 3a7c2f66


License Attribution: 
Hulk Model 
http://www.cadnav.com/3d-models/model-43309.html

Thanos Model
https://sketchfab.com/3d-models/fortnite-thanos-1ad8e412639d4bd78bef9c3ea72b502c


Meet Your Teacher

Teacher Profile Image

Rexcel Cariaga

Virtual Reality Game Professor

Teacher

I'm a game developer and multimedia arts instructor with professional experience in desktop and mobile game development. I love conceptualizing gameplay designs emphasizing user experience and psychology of mobile game patterns. My key strengths include project management, process optimization through the evaluation of new technologies, graphic design, and 3D modeling.

As a proud professor of game development, my students have successfully landed a job in the game industry Gameloft, Casual Connect, Aarki, Inc., and BoomZap entertainment. 

I have also conducted several talks and workshops. Among one of them was at the Pocket Gamer's Connect Conference in London, the biggest mobile games show in Europe, where I conducted a talk about UX in Mobile Game Design.

See full profile

Class Ratings

Expectations Met?
  • Exceeded!
    0%
  • Yes
    0%
  • Somewhat
    0%
  • Not really
    0%
Reviews Archive

In October 2018, we updated our review system to improve the way we collect feedback. Below are the reviews written before that update.

Why Join Skillshare?

Take award-winning Skillshare Original Classes

Each class has short lessons, hands-on projects

Your membership supports Skillshare teachers

Learn From Anywhere

Take classes on the go with the Skillshare app. Stream or download to watch on the plane, the subway, or wherever you learn best.

Transcripts

1. Introduction to this Course: In this course, you'll learn basic and advanced unity. Three D by creating a Marvel Hawks first person shooting game for this course, I don't know that and use the treaty models or as it's from this legs, which, as you can see our girl to royalty free and this course you will learn how to create the Terran from scratch. We will also be adding trees, grass as well as water. In our terry, you learn how to coat as well as animal called El Thanos with immunity. Since this course was inspired by Marvel, we will be also add your portal similar to Dr Strange superpowers. At the end of its course you're in, you will be able to have a stand alone game. So without further ado, I welcome with the discourse CIA. 2. Installing Unity 2019: Hi there. Let's start installing unity. So just simply go to this link. So let me copy this one and paste it. Community is free. So all we have to do is use the personal addition. And if you don't have an account yet, you could simply create an account by clicking on this one and creating united. In my case, I'm gonna log in. Since I already have an account, and I will just simply sign it with my user name and password. Let me sign in. Oops. They have their own password. It's seat. Yeah. All right. I haven't simply click on individual and click on get started. Start here. So you will be redirected to this page. Supplicants, start here. I agree. And download. So this would install. Now slip me. Refresh that one way. Have a slow Internet. So this will install now. Unity. Hope so. Let me post it after installing and once that is installed, open unity home and you would see this one. All right, so it's here in the next lesson, See, in order so that we could create a new project 3. Creating a New Project in the Unity Hub: once unities installed, we have to install now version of unity that you want. So in my case, have installed 2018 in It's 1000 19 version. But if you don't have this one, just click on add and they look for the latest version of the discretion of unity that you want installed. So let's say what install this one disc liquor next, and he could not add her. Check the following modules so under it allows you to publish your meeting project in Android. This check boxes first for Iot XT and as well for Lennox Max, html five and Windows. Well, I have installed this woman's there, checked so in your case is clicking next if you have. If you have checked all of this, then click on the check box and just wait for it to finish the install. So since I haven't since I have already installed them, I'm cyclically canceled and community project is here. All right. If you want to add more modules, just click on this one and add modules. But let's start to create a new project supplicant project. Let's click on new, and this would allow you to choose or the creator project in the versions that you want installed. So I'm just I'm just going to click this one, and this one now would allow you to name your project. So let's call this, for example, as unity of injurious project and then save that project in this holder. In my case, I'm gonna say that here, make sure you check this treaty box or this treaty icon since we're going to create a treaty, came and simply click on create. And there we go. So in the next lesson, I'm gonna discuss now the interface off unity and we're going to create that a simple Terry . So we'll see you in the next lesson. 4. Installing Standard Assets: just tell your interface if you don't have the same interfaces me because this will change early out by, for example, doing this one. So this are your default views. All right, So you could accuse anybody that you like. In my case, I usually I like to use the two by three. Now, before we start, we have to don't know the start standard as it's from unity to Goto Window and then general as its store. So this would open up a new window. Just wait for it. I'm gonna post the video. And on this asset store window is workweek, where we condone load several I attempts from the store. You could download scripts through the object sounds, whatever you have. But in our case, we want to don't know the standard assets from unity. It's a good thing to have this under in every creating a new project, especially if you're starting with unity. So I think it's this one. So you have to make sure it's from the unity technologists, and it's double click on this one. And once you have this one, you know, have to download it, right? So this click on download want to click on download, Click on import. So once you have to want to click on import this Poppel open end, it will prop you to import the assets or the assets will be including your project. Fight that difference supposed to video. So once you're finished downloading an important thing, this was now pop off and simply click on import. So what, you click on Important you should see. Now this is progress Bar and that basically it basically put this assets in your project folder. So if we just wanna wait for this one and look at the Athens holder No, I have the standard as its folder. So if you look at the standard folder or the standard assets holder, you have your several assets that we can use, such as water, three east grass and so on. So we're gonna use that in the next lesson. So that's it for this Chapter eight, and we'll see you in the next lesson. 5. Terrain Part 1: So this is basically units unities inter faced. This is the scene window where where we will please all our objects sounds, characters, trees dress here in our seen window, and whatever replaced in her seen window will appear in our hierarchy window in text format . Below it is the viewing window which our player sees while playing the game. The project window is your library or your asset library. Off course, all the assets that you all Tunisian in your game you will import here in our as they are in our project window. The inspector window is a properties off. Our game objects. So for them in camera, for example, if I click this one, there's all other properties of my main camera and you would see what cyclic Maimane camera it shows the view off water game looks like. So this camera preview ISS this given to us well now, in order to navigate around unity are in the treaty workspace. All you have to do is press out and left drugs. So out left drag that Would you let that would lead to irritate here relate trip clarity, interview out medal drive that would make your banner of you and then out. Right, Jack, That's making Zoom in or zoom out so long, Right that though so out left drag is your irritate You, uh, middle drag is your view, and then you're out. Um, right track is your zoom in or out Now let the first create their game object here. So game object three The object And then it's every example the puke So that you once I placed the cube here This cube now appears on my higher Q window. Now, if I click on out and left drag that helped her take my view out right, right, Drag at the zoom in and out left Drank that Let me plan my view off course. We could also move our objects here by pressing the bill You in arms w and are so they thought This are all this Keys are now beside each other in her keyboard from W is move the object e Israel teacher object And then our is your scale object. So if I click this one I press w that let me move my object and then e that would let me repeat my object are and let that would let me skill my object notice when I retain scale end transform the values here also changes. So this is another properties of my cube. Now, if I move my main camera notice now, the main camera is my view. If I move my main camera, my view also moves. All right, So go ahead and try that one and let me pass this video. So let's create a tearing after you trying this one. Now that you know the controls, let's now create a Terry. So let me believe this one. And then let's create a Terry. It's a game object taken game, object, treaty and Terry. So there's no military. They put the mouse over here and press f. So I'm selecting the object here and press F while my mouse is here. This allows me to zoom in on my object. The good thing about this one is if I click and tearing. Look at the properties here. You could now sculpture Terry, since click this one. Let me shake my brush. Change the shape of my brush, my brush I snow passages This strength and I I paint that think he's made brush is even more. And if I paint this would no allow me to create a Terry. So let me Chris Capacity. So know this. Now I'm creating now mountains there. Go see. So I did. Simply now I ate my own Terry. My old environment, which later we will texture Is this the first brought in here that would allow you to sculpt military. And next this morning I would allow you to race. You're tearing a specific height. So, for example, if I choose this for fear, let's say this brush and let's say the height this let's make it lying. Notice what happens when if I paint over here so that doesn't raise military. However, wasn't creatures the specific eight of 90? It would allow you to create a plateau there. See, the third bottom now allows you do allows you to switch and returning. So, for example, if you look at this one here, it's quite rugged. So let me now, smoothing that one symbolic. Select a brush, change your birth size the capacity and notice when I painted the kind of melts it or small since it the air go. So let me increase capacity, Isabel. So that knows. Well, since my Terry. So go ahead. Designed the decide military. I m take those that we're gonna play this one, your person or your character would be just this big. Yeah, this your pain, your person would be just this big out of all your out of out of all the size of your Terry . So go ahead, Skull proletarian. I'm gonna post this video. I'm gonna make my own turning And then later on, we're gonna take short and some trees and grass on our terry. So this is no my tearing. Now we just Indian the lights. So that is my tearing And you would see now I could now picture this one. So in order to take sure this one dis click on this worth brush and click on edit textures So edit at that short in Quicken Celek. Now, the first sector that you select is basically the grounder overall texture of your caring. So let me choose a tear in here. Let's say want this one. So double click this one and simply click on. And what status addict? That is not the texture of my Terry. Now it looks kind of silly in on, uh, on a view that is far away. But if I zoom in, that's now my texture. Now you could also also paint another text short, so it's the same process. So click on this one and the textures at that sure trick and select and say, for example, I want to add a little bit of green, so I'm going to select this one. Click on add now select it over here. And now if the opacity now is 100. If I pay in capacities 100 it overlaps my carrying or the texture of my tearing. But let me put that back. But say I want to lessen. The opacity is, well, it's a target strength notice if I paint over it, it's not that it's not that a bake. So if you're good at painting, you could add more texture frequented the same process. They just simply brand the textures with your with your main picture. There we go. So that's at another picture and picture Celek, and that's have any deeper example. I want this one. I'm going to select this one and put some rocks over here. Oops. If you would see, it doesn't really think that all because the opacity is loves. I'm gonna make that 90. This will just target strength. There you go. So making that the 100 the area go so sad like this, will you would see now the texture changing here, See, so being paint the picture. So I'm gonna post this again, and I'm going to see in the next video, and I'm gonna have now a bullet texture tearing. And on the next page, Oregon Add some trees, gas as well as some or all right, so I'll see you in the next video. 6. Terrain Part 2: So this is now my tearing. So let's add some trees so you could add some trees. By clicking on this, I can hear click of any trees at three. And then on this pop up window, select this one and select a tree that you want. So I want this tree, for example. I'm simply gonna double take this one click an act after adding I could not paint some trees. So let me no less in the brush ice. This is the area off your three and the tree density is how close are the trees from each other? So let me lesson this one off course you could play with her height, randomness of the height. Let me they don't want to click dry click dry collector I clicked, right? All you have to. This is simply click in track. Let me add more trees. So any three and three so like this one. And let's have another type of ST Say this one, for example, Gonna double click this one and click on add there Go simply pain collector. I click track electric. They work for this type of tree. Over here it's mass place treats their go. So this is kind of fun, right? Right. So now that you're good with the tree slits at, so yes, so you could add some grass back clicking over here, the paint details and click on any details on grass picture so similar to the tree, We're going to click on this one and select your grass. Now, this is from the standard assets. Or just make sure the perfect off the grass starts with dress. So let me just type ingress and let's say want this one supplicant add And this what I want you to see Notice that when I think over here nothing of peers. However, if I zoom in, you would see now the grass here the reason why s unity only renders the grass wants Your player is near the view So let me just now has some grass If you want to delete the grass for some trees this press control So select the grass that you want to delete and click on control Hold control and simply track. So I want some grass over here Over here as well go. It's adds ingress here. Click directly that I wanted to see anything. But if I zoom in, you would see the grass over there. All right, Now, I want you to see this one. Good thing about this one ISS if I tried to play my game notice. Now the grass is sway at sea, so you click in the pay portal on top and see now the grass s swaying. So let me stop this one. This one, and let's add so water. In order to add some water, click under standard assets over the assets. Look for your standard assets and the environment and click on water. She could no have different types of water. This Make sure you click on the prefab folder. Can this one? This one basically has a clear type of water here. I tracked this one here. If you could see it, what's there? But let me fresh f to focus. So that's one type of water, which is quite clear. Another one would be this one. It's it's a little It's also clear sea. They're so that's another type of water. But let's leads. There's another type of water here. It's other order for the beef ups folder. You could have this one Why is this? Yeah, that's right. So let me change the colder There it is. Well, less this. You could change the quarters if you want. By clicking other properties over here. It's a one type of water. Let me delete this one. You could also use this one. See? So that's one type of order that you could use could also have the water basics. We have three difference. That's four different types of water. Another one would be this one. Since I click and drag Chris depth. That's another type of water. Okay, let me get this one in another type of border. So I think I'm gonna use this one. So notice Here it is. It's circle. So what you can do now is to if you want. If it's only just one portion of the only one portion, you could just around them them by by Terry. There. All right, so that's one type of water, and I think of the naps. Um, water here is well, so to duplicate this press control the the have some water over here. Ski lift, their pressing our e Think I'm good. Let's see. Yeah. Let me just pull that one up and another water Here. There you go. Well, that I wanna smell. So that's it. So let me just add war treats just to make it happen. Environment, Environmental, Green Vice. There you go. Now, now that you have been now that you have your environment, the good thing about this one is could automatically create your first person controller. You just have to search here. The character is first person controller. That's ugly. The standard assets characters, first person controller, pretty fams. And then you have your FBS controller, and I'll simply drag this FBS controller in my Terry. There you go. I'm gonna breast after zooming on my player. And what I want you to do is to move that player so that it doesn't intersect with the ground. Right? So let me change the view to White. That was I could see now my tearing. So this is my scene window, and they just make game window. All right, So if you look at here, can't see my tearing all you have to do, zoom out or just slicker select retiring from the hiker window and press f No. All right, that's my game. or this is my environment. And if I want to play, they simply drag my F best controller here. Click and give you entry. Complain now That's now. Once this place, you could now use the arrow keys are the W A. C keys and your mouse bottom are your mouse. Move your mouse, the scrolled and been impressed. W. And I'm now moving inside my Terry Space Barton shop. See? And I could look now around my Terry. It's good. So now in the next lesson, we're gonna add some treaty objects using using objects from the assets store so that we have more environments like buildings. And so what? But in the meantime, go ahead and play and enjoy your Terry, and I'll see you in the next lesson. 7. Terrain Part 3: now that you have your environment and grass. Reese on the textures is what it's water you could as well now at some through the objects . Good thing about unity is they have a lot off allowed off assets that are free in the nascent store to go the window general and then as it store. And over here could church 1000 tons off assets that you want to use. It's in our case. I want I want to search for through the object. And then if you look at the drop down building, I want to add so environments and say I want to add Now I want some free objects. So just comprising and click on the three groups or inside. Click on the free assets. So if you want to buy them as well. So there you go. See, for example, he just looked for whatever you want and say, for example, that sebi want this buildings here. So, for example, this one So click on that one and take a look. Or that's one gigabyte. Go ahead, take a look and if you're and if you want that one, simply click on download and after kicking on download. It didn't ask you to import. So in my case, I added Now the blue I think it was the forgot with this blue Smith or the blacksmith there . I don't know that this one click on it. I don't know that this one click and import after importing it is asked to import your objects. So let's just wait for this one. I think in there, so groups already imported it. So if this does not appear, just click on import. So this is now I think it's this one treaty forge now usually, if you if you don't look anything from the acid store, it's under the preset pre fabs folder. So all the between fortune would have to take a look like on this one. So this is a scene when No, let's go back this one village in towns and usually there under the free fams folder. So you could have been buildings, Francis and so on. So I think I'm gonna look at this one, and I'm gonna simply jacket dropped this one here. So if Lincoln f There you go, see? So I have one here missing Mother one. Here, let me move that one over here. The data press e there. Don't rest after focus. I don't really want them here. Let's look for others. So about about the base. Also, This not this one about defenses. Oh, so this is just the fence. That's nice. Let me add more state. And it seems someone let me focus on my player. So click on there. Fgs controller. Yeah, let's say, let's add another object beside him, probably. And mother, about this one. Yep, this one. So let's control control detail duplicate. So over here, let's have something like this. Control de. I think for a Mac after use command command. All right, let's have another building over here. Let's have a stable there. Now this. What do you want? To the seat If I'm gonna go ahead Lee in my game and let's see, So Paris that's gonna happen are the problems it's gonna run. So make this white and again. So that's lost for this to my game game game view. But I also want to have pressed f so their right to this might gave you Let me play. No idea. You want to play this one. Our character should not collide with our should collide with our environment. But notice if I go here. Oops. Oh, classical lighter already. So that's good. But there are times when it doesn't have a collider. So I'm gonna show you what this that looked like because there are some instances where you're we're treating environment. There's no collider. So where was that? You think it's over here so f there, you know? Great. If I click this one and if I play both is what happens. Oh, one bicycle lighter. That's good. Okay, let me just show this one thing. It's very important. Another tree. The object which has no collide because there's some instance sense where your environment that you're going to download that Snow collider. And you're going to run through some problems that he passed this one. And I'm gonna add another three d building or acid where the as it has no collide. All right, so I have another object here. So this came from free three d dot com. And this This did not come from from the unity as its store. So sometimes there won't be proud. There will be problems like this. So if I play my game, notice what happens here. So if I go over here, they work through it. Know this now that May character just passes through it and we don't want that. We want something like this. We want something like this. And what's my character bumps into an object. We wanted to collide like that. So how do we now change the properties of this object here of this treaty? Object here in such a way that it won't collide. They don't get good. Collide with this view over this object that can play this one all you have to do now here this is simply selector object and let's add the box collider. So over here under Inspector Tap, if you can see that this broke the window and then or just make this window default or, in my case, to buy three, let's go back a white and let's find that again. So it's this one, the press f right. So in Inspector window, just click on add component and look for the box. Go later. So you have different types of colliders. If you go to component and then face six, you have your box spherical either. And so hot. So this one here is also the same as the components here. So this is just a short cut. If you felt remember I said just look for the component here. So a Component box collider And this was now have a box collider there. So you could edit the collider. Some, for example. I could make this like this. And so what? All right, so in my case, I wanted to be so let me edit Tickle either. And over there, just click on those loans here and I think we're good. So know this now what would happen if May character bombs onto this object? Let's go back notice before we were passing through it. But this time it's now colliding. See the area go. Oops See? I can't pass through it anymore If I just able. However, the collider notice what will happen to make men check this one. Oops. OK, it's in check and play. Well, let's go back and notice what would happen since box calendar is unchecked on the component the or the inspector view, I could now pass through it and like before I could check this one and I will not be able to. I won't be able to pass through it. I want you to see another thing. All right. So before you finish this video, I could also add a rigid body component. So a component, then rigid body. Okay, so let me Now pull this one up. Know this If you scrap this checked, if I play this one, this object now would fall. Oops. How you You were not able to see that? Let's make that baking again back here, breast. Okay, so notice my watchtower. I'm gonna uncheck. I'm gonna check. Use gravity. And right now it's floating through the crowd. So notice now if that I play this one. There you go. All right, Because it's now a rigid body and we checked Use gravity. All right, so let me escape, and then let's go back. So let me just check use gravity. I know that's what could happen now, since this is urgent, body notice What would happen if I bump into this object? So it is a collider as well as a rigid body group. Sorry, I think it popular treat. So let's see. Just be that on there That's not bump it with three that scale. That one. Let me that smaller there. So let's see first, what would happen? All right, so no, this there. And I go and bump with that object there. If I add a rigid body notice what would happen if I bump onto this object? I could now push it. All right, So you could add a rigid body component to your tree. The objects, if you want this objects to be, push about. All right. So I'll see you in the next lesson for the basic scripting, So go ahead and trying to design their environment. 8. Basic Transform Coding: Welcome back. A lot of you have been asking how to save this project. So before we start coding, let's start first with saving this project. So fire basically safe. Seen s. And then it's a good idea that all of your folders are all of your seen. Sorry, Nolan Folder. So I'm gonna put that in my scenes. Holder. Let's call this, for example, has never won. See, that's there You go. So next let me first grade. Can you seem so? This is just be a dummy activity. And what do you want now is to basically to call our objects. I'm going to create now a three d object. And let's make that the cube. And what I want here is to call this one what's impressed me? W a s d keys. I want this or any kind. What? This? I want this cube to move. No. So just take north of the following access. So the the blue Arrow first of your Z access. As you could see, that I can hear the X axis is a red arrow. And the white axis is your, um why access the green Arizona, my access and what we want now is to manipulate the position of irritation in the scale off our cube through coding. So we know what we want to do now is to click on the Cube, and we want to add a script component. So Lincoln and a component just wait for that one and then click a new script and it's call this ass you movement controls and simply create. And at So once his address script now will be found here. And all you have to do is to edit this script is to simply double click on it. So let me double pick on it. So she couldn't see you have a TV here and want to double pick on it. The software visual studio will open up, so they just wait for that one to open up and let me first crossed the video. All right, so this is now my script window. You could as well edit the script in any text editor by default. Unity is linked with visual studio, but for example, if you want, if you want to edit it in sublime or let's say moat bag all, you could have all you have to do is to edit the preferences, so just simply goto file are Unity, preferences and Riendeau. I think it's editor preferences for five preferences, but it's in the under. It's under the preferences window. So click of external tools. And you would see now the visual studio is my default scream any part. So let me go back here later. Visual studio and let's put now are cube on the 00 access by resetting our thens form values or click on this one and clicking reset by default. This with 0000 and the cube is not gone. It's on the 00 accents. So click on the cube and simply press if Okay, so now, in order to in order to In order to script this one, What you need to do now is to end the following components the position irritation as well as the scale. Let me use the fun, Sykes. All right. Now, for the position, you call it the local positions Irritation recalling our you will angles. So this is the holding or the script count report. All right. Do you know you won't understand this yet, but you will see it later on and unscripted. So skin is basically your local skill. No sin for working in three D. We have our X, y and Z values, or what we call our back 13 rectory. Three, since we have three values X y Z values. So, for example, if I want to change the game object they want do does form it up or moving up, change the position so it transformed the script restaurants form. Where did they get that from? Here Transform that I want to change what? I want this gene to change the local position where so is it with the new very 30 and then your X, y and Z values. So if they want to move it up, so that's a positive wise zero, Let's say 22 units up and then zero. So the court basically says Transform. Now the cube. There's from the local position of the Cube on this new X y Z position zero for the X to further wife moving on parents and zero for the that access. So if I simply copy this one and they put that on the start and I'll save my game, notice what happens So if I play this one, the Cube Now let's rephrase the Cuba moves off. Let me play that again. Let me just zoom out. So play the Cuban national Move up. There we go. You could as well change now. Irritation again for the irritation. It's basically Euler angles, all right, so let's try that. And we want to retain that. So transform the fewer angles in the new Vector three. And I want to irritate it. Let's say on the X access by 45 degrees for 45 00 So far, everything this code law, What you could see now is the Cuba will move up and also to take on the eggs access. So the X axis is known, My right arrow. So have this. Everything should work. So rotation works is if I retake on the X access. Think of it just resting this arrows. If I twist my ex access, it irritates somehow like this. So it's a new that controls E. Let's go back to the good. Save it Book is what happens if I play. Uh huh. There you go there, Cube. Now irritates. See? Lastly, you have your When was the last one. The last one is my local skin. So for this scale. So if you want, you could comment this one. This basically avoids the coat and poultry Nicole that extends form this cancer pins for dot local scale. And let's transform it, for example, twice original size. So if I make it 1 to 1 What this all happens as it would skill if one times the original during your skill of the cubes, it won't do anything because it's one. But for this one on the white access, it would scale it twice. The Why the why size off my of a cube. So let's see what happens here. That that's here. Basically, if I scale this one using this code, this would scale now, upwards, they save looks. There's an error in my coat. If you'd sit ins form, it can be used. Oh, sorry. This should be sick with the new victor. All right. Started that one. Uh huh. But scale. See? There you go. All right. So another, I think that you need to know is every girl if we're gonna work with decimal points, we call it float. So, for example, if I want to change the position into a decimal point value. It's a water. Transform it to the X access by 3.5. No, this day I right here. If I say if I play this one so living for save this one. If I play, there's an error. It says Float back to Earth refloat. Why, in any programming language, float is equal to any number with decimal points. So if you're working with any number with decimal points, we call that the float. So in order for your script for your script to work, just press F and let's see what happens. I play this one who know this pressed F. I think I didn't see that once would have been seeing it again. You're putting five F Let's play that again. This not full. Oh, call. Let's see, uh, 0.5 f 3.5 in. That should work, though we put an f here, that's I think we have to put it if there because all of this now are floats because the place is decimal point here. So play. There you go. So that would now work sea. So the position now move to the right, but you 0.5 access. So why did they put an F here in an f here? Besides not having ah, decimal point? Because once your factory t components or X y Z violence now is afloat value. This now is a float. All right, so another. For this to be read, you have to have on f suffix meaning this x y Z values at as a whole. All right, so go ahead and try this three end. I'll see you in the next lesson. So trade this on any object and I'll see in the next lesson for our input keys. 9. Transform vs Translate and Start vs Update: There is no big difference between the local possession. The transform, local position and transform Don't translate When we say to his firm. Look local position. Remove the object to the new position. If it didn't sleep the object we move the object relative to his original position. So let me explain that be showing this great. So, for example, if the X y Z position will make character Blue Vector three and Satan is formed, that local position is equal. Do do 20 my cube here, this one, my circle here that's 2 to 0 will be here. That is, form local position. If it's 3 to 0 3 to 0, that would be 3 to 0. It would be somewhere here. That translate, however, removed the object relative to its original position. So if I say transform patron slate, let's say make that 210 What this does ISS We move the object to units to the right on the X access one unit. Do the white access has up in general units, zero units understand access. So if we use this Colton's front of translate, we moved to units to the rights one to and then one unit to the white upward so we could go there. So this is for difference. Late. You could do. For example, cans four. Don't translate. Let's say negative three. Negative to zero. What this does, Basically it moves now are object. Three units of the left. That's negative. Two units upward are doing It's not worth. That's down on the white access and gear units on the X access. So if we use this cold, remove negative three. So one, 23 and then negative. Two units on the X access. That's 12 And this is now our new position using our translate could. So why is that important? If you could see here, you go back to our records. Let me now. First did this one. It's close, this one. A lot of windows are opening up the huh hopes. Okay, X this when they go back to our code, this one. So if you would see we have two functions here the start and the update. All right. So start. Basically. Reacher called once, but for the data, Treacher codes while your game as running. So all throughout everything it'll put inside up, they function our game now. Iran's or the gold now is being read continuously by unity. So let's start first. With this start, it's going to use it. This form that translate. So let me first move this one somewhere here. No tests. The new position is now here, so let's move it forward to transform doctrines. Lake moving forward. 00 Let's say to save this one. So this would move under that access. Meaning forward referring to the blue arrow here. This Maisie access, if you could see there. Uh huh. And see. All right, so let me receive this one. And if I play this now, notice my cube. They didn't only move to units forward. That is, if my code is under start function. If, however, I move this one or I call, cut this one and place it on the date function. No, this happens. I play this one. This was no continuously move forward so that their rights it's moving forward. So same thing if you want to move backwards under easy access. So let me just make this negative. Save it. There you go. So let's see. So this cube now should move backwards on busy excess. All right, so if you would see that's Maisie access and it's now moving backwards. So knowing those concepts in mind, we could not control our cube using our keeper controls. So let me start first with our up and down coats were forward and backwards So forward I'm gonna press my w key in the backcourt I'm gonna press my s key So take note to backsplashes our comments. So how is the corporate this one? So if input input plot meaning input Something on my keyboard. So get key down. What did your importing their keyboards of peacoat, but w an opening close bracket. So with this opening close bracket, what would happen now if you press the letter w I wanted to move forward with this form Doctrines late. Let's move forward zero zero on the access because we want to move it forward. He would see that the Blue Arrows way said access. And then it's saying one semi colons, semi colons like a period. Basically that enger coat. So what happens now If I play this one and see what happens? Okay, Just wait for this to become the Blue Arrow. Now what would happen here now, is that if I press by w key, I'm moving forward. The problem here s I have toe pack by double it every now and then. I can't just hold my double key. See www. Www So instead of doing that one instead, off years and get key down, just use get key. So when we use get key, you could now hold W and this is called Run. You don't have to attack that, doesn't you? Again, Let's save that one save and let's play. Oh, let's play So this week for the Blue Arrow before you could play. So sometimes if it call doesn't recuse Forgot to say Mitt. So w There you go brush that Lords movie. So it's the same thing with the S key is going to simply copy this one. Brass it here. Let's make that negative. So notice what that happened here The books click on the stage first W yes, it's working. Let's first see the cold. Okay. See, I just work out, deceive its control s Lee, that one I see. So w that's See, that's from your how come into Ricky and see that we just first crossed this one that I'm going to find the error okay from the errors instead of nobody's. It's conflicting. I just have to change this one to pass. All right, So sorry for that one. So we just just this change the W while ago to save this dress. So let's play that again and see so w s W s Samir. Go. So let's do the left and right. Keys for the left and right keys. You won't move it like this because a normal person. Now, if he moves to the left or left there, right, you're basically moving at that way, then moves forward. So that's what we're gonna do so similar that there's four vs translate. So we have what we call that transform, doctor, take. We retain the object relative original position. So you are ready to do that and get I'm gonna simply copy this 10 maybe rebel. So that's irritate left. And then it's have their date, right? So f again in pork, not in port, not get key. And I'm gonna press my achey So key code not a so this iss There s a what would happen Happy now transform the date 010 Now, why is it what is the value one? Why didn't put the value on the white access notice If a person irritates, you know, trying to trace the arrow. So if this one irritates notice now, think of it. Just resting the green arrow, irritated like that and then do the same thing for the left. This s the press. Sneaky. Going to simply copy this one instead of the letter. A letter e d in this one. Negative. So let's see if that works. So I'm gonna play that one. W very go great fast if you want. It's quite fast. You could now lower this the Upton sleep. Let's make this 0.5 f f f Yeah, if negative think. Thank yeah, so f because it's a float. So go ahead and try that. And I'll see you in the next lesson. So its first time, this one. But if you want, you could now go ahead and you could not go ahead and try your coat. Right. Make this negative. I'm sorry about that one. All right. So we'll see you in the next lesson and try to do this. Coats. All right. So it's here in the next lesson 10. Input Movement via Game Controllers: now that you know how to the cube using keeper controls. What if we want to control the cubes using a joystick Expo controller Rennie device. All right, So instead of doing the input, get keys. We have another call for that. So before I do that, let me first remove my script here to remove component delete, right? No, that's why the new script. So I component Let's go This ax cube controls, So Okay, it's a good idea to put your scripts in one folders will have the scripts folder here, which I will now place the cue controls here. If you don't have this fool, they're just simply go on. Right click create folder. My case and Diskin simply drag it here. All right, let's start. Let me first open the cue controls. So the code is shares. I'm first gonna that the court and have been explain it. So flow Translation. So that could be any name now is equal to input, but get access Vertical. So float. Translation that could be any name and then vertical. Now, where did they get this coat? Input? Get access Vertical. So if you go to edit and the project settings input. You have your access here. So input get access. What? Actually, they want to get my vertical access. So, Felix vertical access it now asked me down. Keep my up key. My Eskimo double icky and motions from the joystick. So that basically is my vertical access in this, uh, value. Now, since this is a float, I'm gonna put Asaf ICS off f. So even if this is not the decimal point, you still have to put an F because in our valuable placed float. So this is not for my W s up and down. So they wanted to move it forward and backward. So that would be now being my that access preference for doctrines late 00500 and in the value of your insulation. So let me say that one save and knowledge that tried to test the court Well, it seems away from the centre into blue and once I'm impressed me. W s keys there W s oh, down, down. If it moves faster, you could as well lesson lesson the lumber here. But they usually at the times Belda time. So what? This This means if it's without that coat, it moves five units per frame. But if this has this one, it moves now five units per second. So again, it's per free without this one. It's per second if it's with this cold. So let me save that one. And let's try again. Let's see nobody's CWS forward backward, disarming Iraq Easy tell moves slower. So let's do the same thing with our heart. Is Anton accents So again? If we go hour, if you go to our project input your heart is on the axis. Not your first to your left and right keys in your and keys. So same thing. So four my left right keys and a and D keys. So this will become irritate left and birthdate back. This has become Move forward and backward. So float prince float Irritation is equal to input. Get access and simply copy this one but its standoff critical. I'm gonna use horizontal tens I'm gonna use now my a nd left and right keys. Now put the semi colon. Now I want you to see this one. If you have noticed, if your script now as this red currently under nights meaning there's an error with your coat. In this case, if I see a red Underline isn't every with Michael. I'm going to simply put a semi colon to and the court. Then transform. Doctor, take zero. And again, we put it on the white Access the station zero. Let me save that one, and let's see what happens. Okay, so unexpected. Symbol double click this one. So there was an s here. Didn't receive this one. And it's late again. So if I'm gonna use my wst keys or my arrow keys, the cube now should move like this. Okay? You don't now run more smoothly, Okay? No. So now that you know how to move the keys or how to move your cube using this for lines of cold Let's see what happens if I have another object. That's another three. The objectivist make the bigger cute. All right there. Okay. So take note of the following components my skull. Que Because my richness, which has the controls, has a collider and my script physical either. This one also has a box collider. So know this. What happens now? If my small cube bumps with the bigger cute and see what happens. So if I'm gonna use May w A s keys since see So you just passes through it even though they both have a collider. So we don't want that to happen. The thing is, what they want now to do here is to make the bigger que a solid object. And even this one we have to make them both a solid object. So that is one of them. If at least one of them could should have a solid object An order for this objects to have a solid object or a solid component. We have what he called a rigid body component. So think of what I think of it. This one solid now the synonym absorbed it is rigid. So let's add now Origen part here. So by typing and component and look for the rigid body component If you check use gravity notice what happens to me a bigger CUC. This was now basically fall down. See Ifo Never I and shake use gravity. No, that's what happens. This will fall down. However, if my small cube bumps into it What is what happens to make you? There you go. It's still passing through it. Why? Because the bigger wall s solid. However, my smaller cube has no solid component. So that's also add a rigid body component and then check Use gravity. No, this now what happens here? So if I move my cube now, this was basically post the cube there. Right, There you go. See? So that's one way to interact with your objects by idea collider and origen body. But what if I don't want this bigger cute to move? I want to have, uh I wanted to have a property in such a way. It acts like a wall. So you have to do now. You have two options here. The first option is to check s schematic. When you see your skin dramatic, it doesn't interact with fake physics. 4th 5th physical forces. There you go. So notice now, my small cube there it can't now interact with the object. So that skinny Matic let me just zoom it for you. There's a victim's pushing now. All right, Another option s instead off using Esquina Matic, you could as well freeze the possession irritation of this cube. So notice now what happens? That's one option. It's the same property. They're so no, there's now it's it's not cinematic, but they have frozen their cuts, strains. And now my smaller cube is not about spark similar to the similar to the property of Can a man take a while ago? Another option? Well, this is what option, but some types doesn't. Rick, I could not increase the mess. All right, But if you have a smaller mass, some types that gets the push through it and it's C if you there ago, all right, so still pushing through it. But see, the bigger ball now is solid. So that's how you interact with our objects inside that were seen. And now that you have now that you know now that you know sorry about that, now that you know basic coding, let's go back to our hook seen, and I'll see you in the next lesson. 11. Particles: So in this lesson, what we're going to do now is we're going to create a particle effects and then we're gonna make our character that report. So in order to do that, go to game object effects and then party consistent. Now, if you would see these are now my particles, The duration is for each particle. After five seconds, it would now looks It will go in a continues operate motion if you check the looping. So after five seconds if you follow on particle here after five seconds, it would disappear if I unchecked loop. However, notice the particle but only appear waas. So after five seconds on the one particle after five seconds, that particle now would disappear. So it both appear here anymore. So they put that one back up. Just click play. Now it could also change. Now the start sites they If I increase this one time left taking and dragging, he could change the size of your particles. Same thing you could add a gravity to make your particles fall down the right. I don't usually change the color here. I change it over the corner of Lifetime, but we'll go there later for the mission. This is the regal. Every time this this would not increase their number off the number of your particle, the particle rate over time. The shape Now, if you would see here is the shape of your emitter. This is not the blue corn here, so let me just make this white and we go back here and shake now. The particle system press f focused. All right, so if it's a goal, notice the blue I can hear. It's a code. It omits the particles emit from a cone for a donor. The particles now will limit from Latona the same thing here mash. So here you go. All right. If you want the change, the gravity modifier fall down as well. Sprite. So go ahead and playing with this one now. Same thing. For example. I want to change now the color over a lifetime. So if I'm gonna click this one click on the check box. So by the four, this s white. But if I want to change the color than a click on this white square here and exchange the call or so click on this note here, let's change the corner, for example, to yellow from yellow. Do Let's click on this one to read. So there you go. All right. So that's how you change colors. Good. This one, Adler colors click on this one. Did see that simple white in the middle. They're all right. So go ahead and play with this properties the velocity off her lifetime, you could make it pretty and so on. So go ahead and play with this property. So I'm gonna pass this video and I'll show you how to do the doctor. Strange particles. Let's play with it. So I'm gonna pause it first, so All right, So now that you're done with with playing with the particles, how do we create the circular particle for our for our particles or for our game? So you are ready to do that? We go again, creates of particles of game object effects in particle system. So they just pressed after focus, and it's put that somewhere where our character is. Do you think your character is over here? This was a good thing. This would make things easier for us. Oh, the character is way over here. There. I think it's here just basis here. Focus. Right. So now that we're here, what you need to do now is to change the shape, do us bright. So this would make now the thing. Our our particles move straight and over the velocity over a lifetime. So check this Rachel bulletin here, Simply increase your why in there. You know how the streak, your Lord property. If you want to make this thing larger, you could skin it. Refreshing this one or simply pressing. Artis killed. Let's put it somewhere here. So this is where our character would teleport weight. Right? So let's see. Gets quite put it somewhere there. Okay? The trees are blocking the way. Let's put it down somewhere in there. All right, Skillet. This time, what do you want now is to change. The properties are the color of our particles. So that's going out to the color. You could change it from the start colder here, Or we could be here out with the colder over a lifetime. Is America like this one? So the caller, Let's make that yellow from yellow. Two yellow in the hopes yellow. Simplest. This note here, this one in yellow. This have orange over here. So click this note and it's making arnage And a little bit of dark Are injury here. Well, let's see. So probably accusing over here. You what? Let's make this Doric Yo. So if you're good with this one, what we're going to do in the next video is we're going to add a sphere where character came. Teleport. So let me duplicate this. What? Just to have a very nice effects or press control D and I see it's moving way over here. Okay. All right. I think I'm good with this one. So in the next video, what we're going to do now is we're going to add the cylinder here, and then we're gonna add a text short for our view. And after that, in the next video, our poster character collides with this. With this particle, it will now teleport to another location. So I'll see you in the next video. 12. Adding a Teleport View: before we start the lesson, I want you to see something here. So if I played a video, No, these down here. So we just wait for the movement into appear so notice. Now, here the particles are just beginning to appear. We don't want that. We'll think what happened is what they play the game. This circle has now already been formed. So how do we do that by simply clicking on their pre warm So click of the particle system, click on pre warm. So make sure you have the settings here you make, then click on pretty warm. So go to the object or go to the default state or the particle that the birth go Go to the particles that you want at its state and this click on prewar. All right, if I wanted to appear like this after it forms district on pre warm. So know this now when I play, the particle style has already being formed. All right, so now this time. So let me and play this one. So press escape. I was in the nest. So this time what do you want to happen now s So let me play this one first and let's go. We're gonna add a sitting there. We're gonna put that cylinders irritated, making this one or press either date and this sitting there now. So are the scale would have the same the ometer off my particles. Right. And blessed are the skill right over there. Lets make a thin Oh, so you could position it three ways of particle again. What happened? Okay, position it somewhere here more so I'm just going to make sure the particles were within the bounce are within the perimeter of my are. The cylinder is within the perimeter of my the particles. Right. Here we go, The physical later. So we're gonna check that leader on? No, but what we want here is that to have a text Sure, officer than view where it would report. All right, so how do we do that? So, in order to create the texture here off of you of your view, we're gonna great now at camera, So game object, hammer and the camera. Now, let's put that in the view that way walked. So it's gonna placed it somewhere, saying over here summary you won't be able. We could able to distinguish where your character is. Probably over here. Yeah, I think it is good. This press and it's C. It is a teleport. They kind of there would tell it forth somewhere here. Okay, So this is the view today. What from a character, An interim teleport somewhere here. So in order to do that So this is a picture that I want? All right. The cover of you is a texture that I want. So in order to fix this or integrate the picture for that view, we simply click on create a new material, right click to eight materials. So material is similar to, for example, if it's a marble would Robert and so on, so material it's safe. For example. This is my view material, all right. And then we could eighth our render. Thanks. Sure for our camera. So rightly eight render Thanks short. It's called is, for example, is the view picture and now over my camera going to select this camera. The camera where my view is you have here the target. Thanks. Sure. So, simply down your view, that sure there now that you have that one. The view material now the albedo or the texture is now my view. Thanks. Sure. So gonna select this one click on this one and then search for your view picture. So see, we have no attack short by the default of our camera. So probably couldn't this one. And now this. With zero that he created. We could not put that on our sitting there. Horsley cylinder. Okay, I can find it here. Are you there? All right. Ah ha Cylinder some district. This one first f And now in this one, I'm gonna simply assign this material to my cylinder. So there you go. So what's the next thing that we're going to do? The next video is water character. Collide through this cylinder, Eric Character now. Good heliport. So, as of the moment, if you would see what's happening here, what's happening here? ISS? If I could live with this one, nothing happens. But what do you work is once your character collides? Here we go. Now the report that you So that's really that's what we're going to do the next video. We'll tell you in the next lesson 13. Teleport Character: So in this lesson Look, we're going to do now is we're going to add a script on our on our FBS controller. So that was it collides with our cylinder here. It will not that supported the view that you want. So the first thing that we need to do now is to find the possession where we want our character, the heliport. So if you look at that, were second camera. Where of us? What we need to get now is the X Y Z coordinates off this camera here. So the exercises 203 11 and 125. So let's put that now. X s 203 11 helps Whiteness 11 and visit access s 25 now again, if you're going, if you're going to do some conditions, we need to make sure that our components are our game. Objects has a collider and a rigid body. So let's start first with the cylinder for the cylinder. It has alkali anger, but it doesn't have a rigid body. So let's other rigid body and unfair use gravity and simply check this position invitation . We now go back to our FBS controller so if you look at our FPs controller, it has a rigid body, but it doesn't have any. Gallagher. So what I'm gonna do now is invented. Great. Now capsule it and this cap soul should be in the same location of your player right to the capsule. Now, passed a collider here and make sure what we're going to do next is to make the caps off a child off the FPs controller by simply selecting this one in dragging that one onto our FBS controller. But this does now. ISS. If you would see here, the cylinder now would follow the movement of our FBS controller. So if I play here, notice now my cylinder on the top video by the top screen for sorry in the top window. It was follow now the movement of my character. So now the thing that we're going to do now is to add the script on our FBIS controller. So that was it Collects without were sitting there here, it could now go to a new position. So let's do that. So other FPs controller, let's add the script. So as component new script, let's call this, for example, asked that aboard Scream, distressed Enter. And now again, it's a good idea that your intel, your scripts, are placed into one folder. So let me just click and drag this one onto my scripts folder Double click, Teleport script. Open up Visual studio. So here's the code. So we need to create the new function of white functions. Avoid on collision. Enter So this is case sensitive. This is uncertain. Syntax community, its capital O Capital, C Capital G and then collection. And then on the second parameter here, that could be any neighbor example object that was hit, right? So what do you want to do now is to find the game object that was hit So opening close bracket and I would paper like this if object that this head the game object. So the name of the game object that was hit Is it going to What? What did I hit? I hate, for example, this game object here, and it's name is Cylinder. Save the name of the game. Object is cylinder with a capital C that's gay sent it there and what do I want to happen? We want to transform the local position to the following the new Vector three. And this is where you put your X y and Z access. So they know this script is attached to our player. So basically the position now this for now will be run toe are clear. The player will not change its position. So the X y Z started 3 11 25 203 11 And I think I was 25. So let me save the code and it see what happens now if our character collects with a cylinder. Let's see, Let me play this one. So look at the bottom window. So notice if I play and I concerned the cylinder. There you go. See, I'm able now to teleport. All right, so let's try that again. But this time, White, now that our code is working, what one last thing that we need to do? Since we don't want this capsule to render, I'm going to select the capsule from the actress controller and then shake mesh render. This is what this doesn't make secretly makes the capsule invisible, but it's still there, and I wanted to have Let's make this 20. It goes from the air, So let's try that again, and it's right to play. Okay, so this week for it to look. And no, it is. Now, if I could lead this portal here, you see, they're Wow. I'm able now to tell apart. So that's that, then I'll see you in the next lesson. 14. Rigging Thanos: So for this lesson, what we need to do now is the down off the hook and tennis models from the Internet. So if you go first with the whole bottle So using this link, the Hong now is that c You could use this for free download computing. So So I think we could don't know this one. And this is royalty free. So just gonna click on download years downhill, and once you click on download, you simply click on the download. Your So once I have done that one you would see now my folder here. So clinically gondola jury for whole and see It's now here so guys know that there are. But I don't know this this a while ago and the trainee here, so I hope that you are. And you could just know extract color. I'm gonna extract this one noble click and then some bittersweet for this one. And I'm gonna I'm gonna use be one as mayor are extractor Where is it? The air ago and simply click now. Simply extract. It's been extract that under What for there Was that under documents? Unity. You mean another resource is and click on. Probably. It's click on extracting this folder and it's choose this one. And OK, so fasting folder. So there you go. So this is now my model for Hook. I'm gonna do the same thing with Thanos. So thank us is on this link and it see if it's free to download. So this dome a tightness you could down the three d model the attribution, the license. Let's see if we could use it so we could use it so we could use it even commercial this nice. So we're going free to share and that that Okay, so thank you for but did this. So thank you for who did this. Okay, but whoever did this Thank you. And the same thing for Hawk. Thank you. All right, so thank you for that one. And now it's download three d model. So let's just log in with Facebook. So, after the loathing, this one, either they did that death one. So it's already here in my folder. I'm not gonna extracted extract. All right, so there. Okay. Now, with this one, we could now rig our characters, So if you go to mix about dot com so make someone of that call. This was now automatically rank and animate our characters, which we can use now in our game. So let's go to Mexico because logging. So if you don't have an account, you talking with your Facebook or your Google drive. So in my case, just seats de nuit. We'll go. Not sure Over here. Oops. You stop my email address. That's okay. So you just have questions. You could just email. All right, so this is slow Rex and get a post the video, and I'll just wait for this one to load. Now Maximo has some before characters and animations, which you can use. You could also clued your own character for maximal Try me if you got the characters here, lets you see the kind of place that you can use. So these were the characters that you can use, but in our case, we want to use hook and tennis soon or other to improve our character. Here. It's kind of snow. Simply click on upload character, and over here you would not drag our our fight. So let's start first, win Faneuil so that it is our in my game. Our game. Let's make fatness is our enemy fourth make panels. Where were you? Where you go? Sourced Let me and sit This one and the LBJ. So this is the finest character. Simply drag and drop it here. So this was no upload the palace character and makes Imo, which now we can define No bulls are the parts of the body, so they just wait for this one. All right, so this is no my whole character. If you would see if it's in the wrong orientation, you could not afford to take that one if you want. But this way character is in the correct position. There you go. Let's click on now. Next. So they're taking the next. We could now define where the chilliness by clicking and dragging this circles on tooth annals. So the chin is right over here. So that's what that here Further arrests. They could also put them here. So there is is over here. Now you couldnt shake you symmetry uncheck, you symmetry if you want to work on the circles individuality. But in my case, I think they're symmetrical. The model is symmetrical. Somebody use the symmetry, so I'm gonna put their list over here. The almost right here. Oh, we're here. And then, lastly from the last one, the knees is well, it's a great. So the niece over here and in the growing over here. So once you're done defining a parts, we simply click on next. So what this does? Is it basically rigs your character? So I'm gonna post the video again. One this notes or why mixing more is rigging jammers. So once they're getting install, you would see now Fallows moving and see if this there any there no problems with Eric. You could just go back and re get if there are problems. But if there are no problems, just click on next. So this was now have Fallows in your integrate in this window, and we could add now the animations. So since this is a non player unplayable character, what do you want now is to find an animation for a tattoos? Let me scroll of this one, and maybe I'm gonna use this here. Okay, so this is sandals. It's cool. It takes a while to load. She could don't know the self. Several animations, as you like, refined several animations that you like. So in my case, what I want now ISS That's see, let's say we want this and you make sure there was that one Internet, this quite snow. So let's say very well swallow. It's like animation. So probably this one. Okay, so what? It's saying They think this was the look, that rifle behind shoulder on tunnels and you would see now that is any meeting the right. So what was done with the animation? It if you have a fast Internet, this animation run smoothly. But right now it's lagging, in my case because I have a slow Internet. But this one, what we can do now is to download the animation so taken, download and and we choose now FB X four Unity, make sure it's tennis check and click on download. Okay, so let's just replace it. Download is a There you go. All right. So I think those is a fire. Neighbors were gonna import that immunity later on. So I'll see you in the next video where we rig hook. We're gonna have a look animation in either animation for work. So I'll see you the next video 15. Rigging Hulk: So in this video, we're going to rig Hook, so open up the they're folder will extend cold in this time we're going to drag Kolok. I thought Oh, BJ So why Lucas Fbx So FBI? Just another three d four months and then Oh, BJ's another three d former. So this was now upload Hook and same thing that we did with Thanos. We're gonna rig this one, so click next and then defined on the chin defined the rest the position of the risks. It's also the fine the yellow boast the elbows Air point here There isn't gonna move it somewhere here the niece as well. So the knees a right over here And lastly, the growing supplicant Next four mix symbol the rig it now for what they did now for for a fan does we had one animation since this our This is our enemy or not, they're non playable character. So the one animation that this one is the put rifle behind back. If I'm not mistaken and then for heart we're gonna have the animations. This will now be our third person controller. So what we need now for whole is the work animation. We also need to have the Idol animation, meaning what? It's not walking right, steady. And of course, we need to have the joke animation as well. Asked that smash animation. So let's check. This is working correctly. So that's work that's working correctly. So click next and then So just take a next into the overnight Nathaniel's and we're going to look for this animations. So that's first choose the IBO for the Idol animation. I want something. Make this. So I want this animation here so don't look like this one. And this would not replace the animation. So if if If you're good with the animation click on download Same thing FX for unity Click on download. So you would see here. So that's downloading. So that's good. The next s we have the walk animation. Now take a look for the walk animation. There is some properties that I want to see where we're gonna check. We're gonna check walking place. So let me have been walk, walk. Okay, Internet, This lights most So I chose this animation, but before I don't know that if you've noticed, Hawk is not staying on the same grade So all we have to do is now to click in placed, so want to click on in place? Hold now it stay on the same. Great. So distract in place and click Download downloads. Oh, non fx for unity download. So let me boss this one again. So it has finished downloading. Next. We want the job animation. So if we get it down to the jump animation also check the in place check box over here. Jump! Let's see who show it's it. So let's just think for a job animation. So I'm gonna post this video when they look for a good job animation. So I found a good job animation, so it jumps high. But this time we have again the check, then please. Checkbooks here. Right? So we don't want our kind of third to move on around the great. Why? Because we're gonna call that one in unity. That's my jump animation. I'm gonna don't know this one again. And it's fbx for unity. Click Download. So while it's downloading, what I want you to do now is to find a good smash animation. Okay, so in my case, I'm gonna find a smash animation and off course. Don't forget to check in place, so don't look for animations and I'll see you in the next video. 16. Animating Thanos: So now that we have every animations, we could now import our animations into unity. So this creates now a new folder directly create folder. Let's call. This is character models and animations. I don't think this one, and we simply now drag it here. So what we're going to do now in this lesson is we're going to create now an animation for Faneuil's. So that's open and a Racine. So that's under scenes. Level one. I won't save this one, and we're gonna put time was somewhere here kid, probably where our camera is. So once our guy Tala parts, he would see her. He would see Palace in a distance. So let's put that here. So assets we go back the characters and animations, and let's put now bangs here is quite small, so it's in the Arctic that's gated, so you could use this one to scale or obey pressing our so by default. Fanis has no color, all right. It doesn't have any texture, so we could fix this one by importing the tech shirts where we don't know that our characters from so better press Now let's make this way over here and looks for a channels breast em. Okay, I knows the breast. F you go right. It's make it quite small. Okay, Now with this, if you go back to the textures where we don't know that our our model, it has here the pictures. So in order to texture Thanos, you have to import this textures into unity as well. Let's put that here simply goody drag and drop that one. And for this dextrous, let's rename this one that's called this s Sandals. Pictures? No, for the text shorts. What we need to do now is to create a material so right click, Let's Secret eight material. So Maty knows, for example, if it's what wanting to be met the world robber and so on. So let's call this, for example, as the body material for panels clicking this one on that material and then on the on the albedo. Look for this picture here the panels body, Sandoz Daniel's body and simply drag this material on the panels. Now you could make the object or the material metallic, if you want. That's fresher. Think it's easy. It's easier for you to see. It's always agree. Another with Aereo so create material this time for the hands. Faneuil's head. Same thing. Albedo. Look for the gauntlet. So simply Jack this conflict material here, another got the material here. Let's make the metallic surface that way. Smoothness, mate. And lastly, they think for the head and the helmet, right click. Create material. Let's call this, for example. Dan was head, then the Lido. So there will be those Attack Scher on those head, and I could hear Nixon smoothness the don it. Let's make it emphatic. And lastly, I think, for the gauntlet we have to drag. They got it as well here on this hand, the then his head. It's for the content. And lastly, for the helmet right click a material. It's called the standards element. So we're just adding textures for a Thanatos. And then let's look for the helmet and drag it. This will there right now. This time, even though even with the we drag the character Fallows animation here, if I play this one, talents will not be moving. Oops, I don't think you could see that one. So let's make this s tube a tree when you go close up on panels, so notice here If I play, Fallows is not moving. Oh, I see. So my I have my controls here. But if you look at my top window where Thanos s it's not even moving. So how do you do that? We do that by adding and I didn't make door controller Animator controller is where we could control our animations. So that's great Now, right click 38 an animator controller and it's called his for example, Ask Daniels controller. So the enemy, either controller, the enemy there controller controls the flow off the animation. All right, so if I double take this one by default, if you look at this graph no animation, no animation is attached to the panel's controller. So what we can do now here is to drive the animation of the tennis controller here. So over time those who would see now the animation here, just symbols. By this I can hear which looked like a play which looks like a play bottom and simply drag their so upon the entry of the game. This would animation play. However, if you've noticed if I play this one, we have an animator controller which has this animation But if I play, values is not yet and mating. How go? Because what we need to do now is over. Tinus controller. We have to put the whole over the gallows game object Here. We have to put the controller to him. As you can see, If I click on panels, there's no controller attached. The Fallows. So the controller that we did a while ago, which is this one? We simply drag that one. So this animator controller off Chanos. So notice if I play this time values is now moving. So let's take this wheat free to play. If you could see now there you go. That is this. Now moving. However, if you would see that animation only played warts. So in order to deal with that one this click on this part in here the play button, click on Edit and simply click This world Sorry Clickers and it and then click on Look time so quick in a play. So this basically would group the animation. Let's pleaded displaying its biggest again and look at the top window you would see now danos animating. And it won't stop the animation, so it's looping. Okay, Let's see. Let's teleport way were you tunnels? Oh, there you are. Right. So that's our love people of character. And in the next lesson, instead of a first person controller, we're going to use hook as our because person controller, So I'll see you in the next lesson. 17. Animation Hulk Part 1: So in this video we're gonna use Whole is our third person controller. So with that, in its first disable, our FBS controllers are medicine like this one. And then shake this one. All right. Its first during the hook either. So it's quite small. Who? It's quite small to mid majors in a large him. Well, let's see. Okay, I didn't learn a little bit more. They think you and they think we're good with this one, right? So similar to what they did with Thanos. We're gonna now important textures for hook to go to the folder that you don't want in a while ago. And over here, let's create the new full over eight older that's called in this war. Thanks. No traffic on this one and simply hold Now those two pictures, the d and the and help me and hook. And so that's great. The new material. Let's go. This has fallen. Make sure. And over here, the Opie does our or the and I'm simply gotta drink that whole Thanks. Sure. Over here. No. What is the end? Instance for Lierman learned is how rough for your and just are. So if ivory example at the normal map. So Nick on that one gun circle and look for Hawk the notice knife. I click on this one. Hope now is a little bit rugged. All right, But if it's without, if it's if it's without the learning, if it's not the whole be there you go. It's a big nugget hawk any means so don't like that one and click Fun. Thanks now. So with this one, we're gonna add now an animator controller for Hook, similar to what he did with panels. Right click Create eight and then let's create Now, honey, major controller, Let's go. This has followed and you make over controller. So don't forget. Want to create a than any major controller We have to attach, not cold shoulder the hook. Simply drag this one to the animator controller component here. So if I thought we'll pick it here there's no animation. Get attach the hook. Say if I play, if I play this one, what is not any meeting? But if well, if we wanted to any make with simply click on the idle animation and dragged here. And don't forget that shake the look, times of edit and make sure you thymus check. Click on a plane. So know this now when I play this one? No, this now. Or should move, They're all right. So what we need to do now is to add a scripting hug so that they didn't know how it can now move forward. Backcourt left and a right. It started at one now. So taking a look, it's at a component new script, and let's go. This ass hold controls. All right? So whole controls no, like this one. So I'm gonna put this Crippen describes folder later on, but its thank miracles now, So the code is similar to chatter to float. Translation. Is it going to input? Get access critical again. Birthday culture. First year that will U S open arrow keys sometimes five f all those that access to its war . No clean slate 00 translation. So let's see if that works. If I play country, they'll move forward and backward. I would say that one forward backcourt. So it is a bit like fast. So let's add now, if it's the remember your times, I'm death belted time. So again, this now moves five units for second instead of performing and see forward backwards. And it's quite slow. So that's change it. For example, this make that thing right. So I'm gonna check that again. Forward. Backwards. All right. So I'm gonna make this 15. Next thing that we have to do now is for the irritations of float. Accreditation is equal to what? Get access. Horizontal. Then times was really did 15. Okay. Didn't transform. Not her date. That's related. That the white accesses a rotation zero. The zoo that works. Okay, so forwards backwards irritates date. Okay, so that's good. So the next lesson, what we're going to do now is if our fork is not moving, they will have this idol animation. But if he's moving, he will now have the world animation. So see, in the next lesson for that coat 18. Animating Hulk Part 2: So in this Nesson we're gonna make our character walk. So let's open up Now the hook. Any major going shoulder. And this time, what we have to do here is to have patch the walk animation. So look for your walk animation and look for the play button under the walk animation and simply fade here. Sure, from Idaho you create now an arrow to walk by right clicking, make transition and then walk. So know this here If this controls the flow of the animation So no, this No, my whole while looking at this arrow. So after the either animation that will now proceed to the walk animation. So again, what we have to do now is to loop the walk animation, clicking the play. Now here's the thing. The thing is, if you look at our animator controller upon the entry of the game and to Goto Idol and then immediately after finishing the either animation, it did not go to the walking animation. We don't want that one. What do you want s It could only go to the walk animation, every press, the key. So in order to do that, we have to find we have to add a condition into this arrow. So before you go from adult to the walk animation, let's add a condition to the transition by clicking on this arrow and under parameters its creaking this one and it's great of bullets animation. So bull now is you're doing force values is walking All right, take note. So born refers to bullion in the value of bullion could either be too or force So on this arrow So this arrow here before you could proceed to this arrow, we add a condition and the conditions should be describing. Plus, the competition should be is walking should be to So with that, let's go back to our record and we're gonna add this one, right? So first things first we need to get No, we need to get this animator component in from Hawk. So we're here public and you may 3rd and we have to get this component to this car, this ass hole animator and then on their start hook any made doors you first to get good boning and we want to get this on. You mean this animate Turco pulling has this as this animator controller which we could now access this animations. So from here, what do you want to do now is if the translation translation is not equal to zero, not people, zero meaning so not equal to zero. That to sign here. So every kind of turn. So this one every character is moving. And what do you want to happen now? His hook. And you made there Don't set bullet set book. And then our variable is walking. We sent now the condition true. All right, let's see that works. So no test. If I play here, let me play first. And what I wanted to see here is after the either animation, it would it would not now proceed to the walking animation. It was just here. However, if I pressed now my off doubt our Arab My up, down left and right keys. You would see now my character walking there Go. All right. See, My currently now is walking. I want you to see another thing here. No, this year. So look at the animator window and look at this scene. Windows Well on top. I'm not pressing my arrow keys, but it's not moving, okay? It has a delay. Why? Because before it proceeds the war, once a press make anarchy, it finishes first the idol animation in order to correct that, the one. So what's be impressed? The arrow key. We don't want the other animation to finish, but he wanted to proceed to the walking animation. So all you have to do now is the pick of this arrow. And uncheck has exit time. So know this when I play notice. Okay? I'm now gonna press me w key. It's now walking right. However, if I released my keys Look at the animation here. It's still walking. So in order to do that, we just make the condition so false, So walking right click, make concession. Go back there. Idle animation. So let this arrow on track has, except time and the condition national be force and we go back to our rescript, and it's simply add an else statement to copy this one. But this time the condition now this loss. So let's shake this one. Okay, so let's just wait for it to play. I'm gonna walk. Walk, released, walk, release, Miroki released my parakeet and so on. Okay, so now that works. perfectly know this. However, my game window is not the view of a player. So what we need to do here is go now on your scene window navigated the view that you like , Probably somewhere here. And it's made caught somewhere. Let's move here. Talk. Very hook, uh, hogs somewhere here. Let's look at somewhere here in there. Okay. All right. So that's better. So Hawk is here and now, but the thing is, we want our game view to be this view here. So with that in mind, all you have to do now is the select your main camera, then game object, allying view. So now if I play notice what happens? The camera is on my same view. However, if May move forward, my camera does not follow hook. How do you fix that one? It's a very simple solution. All you have to do is make this man camera and shot the fork. So I'm simply clicking this one and dragging it here. If I play this one again. No, there's now there. May Cameron. Now for those hook. Yeah, he's walking, he's walking, he's walking. And that's good. All right, so the next less son. We're gonna now animate talk using the smart smash and juncos. All right, so we'll see you in the next lesson. 19. Animating Hulk Part 3 (Jump): So in this video, we're gonna make hook now jump and smash. So with that, if you look at that our previous code, there's a problem in this we're not actually a problem. But if you if you would see if our whole moves to the left or to the right, his feet would be sliding, and we don't want that one. So in order to fix that, all you have to do is tow or statement so or rotation is not equal to zero. So let's try this one again. So know this now if I move to the left or to the right, or or if moves to the left or right, you would see now his feet moving. All right, so there we go. So now this time, we're gonna add now a job animation tow hook. So that's great. Now Ah, it's open up our hook. Any maker. And this time, what we need to do now is to add the jump animation. So look for your jump animation and make sure the jump animation is not set to look. So check this box here and put the jump animation here. Now our character now can transition from walking to shop and idle the jump. So all I have to do now, Mr Adan Ayro, let's make a transition here and from walking to jump we uncheck has exit time. Same thing here are kind of three now again can go from Idol Do job and unshaken now has exit tight All right, so we're going to set the trigger your leader on But let's fix this first after jumping are kind of thing now Can proceed the job to walk if Okay so let's say I have a condition from jump door If is walking is equal to two Just click on the passport in here But this time a check has accepted because we want the jump animation to finish and then the same thing from jump So right click here make concession toe idle In this time the condition is walking physical to false If you would see her ever from idol could jump and walking to junk needs to have needs to have a condition So it also that it will proceed to this animation immediately For this condition the condition is basically a trigger. So click on this one. Well sorry that's a bass player. Click on the prime injuries, then click on. Plus, there's where you just like this one parameter trees looking plus and click on trigger. This time the trigger iss Yes, jumping. So we hear from idle to job, we need to set the trigger, which is is jumping. All right. So before we proceed now from Idaho to jump, we proceed now to this jumping coat. Same thing here from walking the job from this arrow here. Let's have now is jumping trigger. Now that you have our animator controller in placed, what we need to do now is to set a cold. That's once repressor respects Berkey. Our character jumps. So in order to do that, this type and if input not get key down he called not space. And then this type of hook and you made for not set trigger what trigger? This is job being trigger. And so before we text that told, a lot of you have been asking, Where did they get this key codes. If you go to your if you go to your browser just that unity key coats, you would see it here. He called unity that you would see all the key codes here. So the key code, for example, for spaces, This one returned tab space. That's the Kiko right after that. All right. That's all the Kiko said you want to use. Let me save the cold. Let's go back here that see our it's in. Our character is jumping smoothly. All right, So they just week free to play, so jump jumped. There you go. All right, Jump. Jump! It's up. Right. So there's quite a jump there ago. Jumped her pretty good. Okay, so there. Right. So in the next lesson, what we're going to do now s for Hook. Do you have this mash animation? Right. So I'll see you in the next lesson. 20. Animating Hulk Part 4 (Smash): the same process for the for the smash animation is similar to the jump animation. But if you would see somehow in our coat, if I go from walking to job, this some quite of delay. So how do you fix this one? All we have to do now to fix that one s you go through other major controller. If you look at the arrow from walking to job, their transition from walking to jump, even though we uncheck, has it same time. It's quiet. It's quite close. All you have to do is to minimize this transition here, so they think that's good for the adult jump. So just many my step so that there will be a slight delay from from the transition. There you go. So that's better. All right, so in this time it's still the jump, the smash animation. So it's the same process. We jump. So just look for this jump animation here or this mash animation uncheck the look Time go over here and then from idle to smash, we make this incision. I'll check has exit time then from walking to smash. Okay, We also minimize the animation here. Uncheck has exit time. And this time we also need an arrow from smash toe walking Rightly make transition And then the condition should be is walking is able to through for this blue harem here. Then freeze this mash, make concessions and then click on this one This time is walking is going to force. So from the walking to smash animation, I think we also need to have a jump jump to smash animation. So all we have to do is to basically make a transition here and then a make a transition here. So from this smash the jump animation we need to have here that trigger IHS jumping right So he could if if I'm smashing and I got the job with rigorous now said is jumping now for this tree I does here for the jump this mash from the walking to smash and then from the idol to smash We're going to set a trigger So that's straight now a trigger Let's call this ass mashing So that set a trigger from I don't this mash in this time the trigger is mashing from walking to smash Drinker is smashing And then from jump this mash no joke This mash the trigger Is this meshing? Right? So from don't just has exit time as except time That's good. So it will be all the animation toe finished for this For the drop this smash and from smash the idols and smash toe walking so that it would now seem to go beat this mash animation So we go back to our coat in this time that's used the left shift If input not get he does he called but left shipped well they want to happen Then look and you make four sit Dreger and the trigger iss smashing with a capital s there trying to save this one Illustrated testicle So now that do you have your oops trees and hair and etc input what's double team? So let me do this one. So now that you have the basic idea on how to use the animator controller, you could use that animator controller to add more animations to your character. You could have, for example, a shooting animation, crouching animation and so on. So left shift it's up smashed Then teaching that says, let's go back here. Okay, so smash Hey, smash! Okay, so that's it for business. In the next lesson, we're gonna fix now the conditions for holes. If you would see our hope now, escalating with is not colliding with Terry is not colliding with this objects here as well as its not the reporting. We're gonna fix that in the next lesson. 21. Fixing Hulk Collisions and Teleport: So in this lesson, we're gonna fix now the collections for honk if you would see here the problem. That what the problem that we have ISS hold is now passing through the terrence. We don't want that one right. Same thing. For example, if you passes through the house, he looks like a ghost. So we don't want that one. The first thing that we need to do now is to first had a rigid body whole. So whole. Let's add now. Urgent pods. Make sure to check. Use gravity Now, I know this year if I play hold now with fall will fall down. Let's see, Okay, because gravity is turned on. But that's okay, But the thing is, it's not colliding with the ground. So in order, it affects that we need to add a collider. Toe hawks. In my case, I'm gonna add a game. You could add something like this or a component, and then you could have, for example, a capsule collider. But the problem that this one is the capsule collider, it's too big. So if I click on Edit Collider, that is how bigger capsule polenta s. And you have to recites that collider that way. And that really takes a long time. So what? Are you sure you do instead of doing Capsule Collider, I had No, I add a capsule. So game object and then treating object capsule. And they'll make that capsule as biggest hawk. But this time, make sure Yeah, make sure the feet of the cup defeat The base of the capsule is somehow near to the base of the foot off hook. And this one, What we could simply do now is to make this capsule a child off hook. Okay, So if I play this one, notice what happens? Hope now is colliding to the ground with that in mind. Okay, So if I am not colliding with Oops. Did you see that one? Okay, so I'm still colliding with tearing. However, I'm circulating in the house. I'm also colliding with the Terrians to look at the bottom screen. However, Was it collides? Hold now. Is risi Okay? Hold now. This seems to be turning around. So in order to fix that one, there's a simple solution. All you have to do here is to simply, I reckon hook and other rigid body component freeze the X and said rotation. So let's try that one. So there, right, the whole time I was climbing the Terry Go back, Go back, go back. You would see we bumped in the house. It's I'm not colliding with the house. And there are no Tom blinks or irritations that are happening. So that were expert flick perfectly. All you have to do now s Don Shake the mash render So did see that in game view. So look at the bottom screen. What now is climbing the Terry? Right? So we go back now, so I'm gonna put hunk near may tell report it area and we're gonna fix now. The teleport. The teleporter is a Taliban the tele forint coat. So let's just put him back here, okay? This press after focus Very you. Right, So we go back somewhere, That's that here, Right? So it's trying to play this one and see what happens if our character goes through the portal. Okay, so that's good. I'm colliding with this one. That's good. However, if I could like with the Porto, nothing happens. Hey, because our tell apart script is attached to the FPs controller, which we now disabled rights when it's unchecked here. So good thing about this one. Once you have your cold, all you can do now is to simply attached your coats to your new character. So I'm gonna say that caulk and other my ass, its holder. Let's look for the script, the teleported script. So scripts and intel afford script, and I'm simply at the gun attached that the hook. So let's see if that works. So it's a good thing. What are usually doing my projects is people do the assets, and then I descript them. And that's a good way. Since, you know, I just have to recycle the coats. So let's see that. See? So you can go look at the bottom screen. Okay. Tell apart, Hawk, Let's go back here. Teleport there ago, Heart. Now teleport it to a new area. So we're gonna fix now. Another Another bug here. If you would see if Hawk is underwater, there's no underwater coat. Now that they'll fix the collisions, let's now fix the conditions for the underwater coat. So I'll see you in the next lesson. 22. UnderWaterScript for Hulk: the contract for the fog is to basically are the concert for the older water is to basically enabled the fog. So the process is, for example, if I put talk somewhere below here, it's just putting down. Okay, so we're here. All right. Riot over Right over there. Okay, here's the thing. If it's underwater, the concept is this simply enable the fox If you go to render and their window in the rendering knighting settings, you click now on the fog, so flicking funk and then shoes off Kokorin that you like. My case is gonna make it exponential so you could play with the property. So I think I would with this one. If it's underwater, we simply enable the fun, right? And take note off his wife position. It's 0.8 So let's go back now. Let's go put back above water. Let me first miss able the fuck Now that you have said in the same things for the funk it's putting back above me out. Okay, that's nothing over here. Distressed after focused right over here, there. So what I'm going to do here is to simply radical radical toe hawk. So Al Capone in new script. And let's call this, for example, as underwater script books. Oh, let's put this underwater script. Do I think I just did that little white ago? But let's go back to that one underwater script that's edit. That's cramp and its crypt. And the concept is simple is simple. A simple It's like this so f game object again. Game object refers to Hawk because this script is attached to heart that transform its position. It's why possession is less than 0.8 This value here was the value will win. Holik was underwater. What would happen now is less than or equal to point your eight. They're simply enable the fox or other settings. But fuck as a call to truth, of course, else get faced above water. There is simply this able the fund. So let's try this one now. So currently honkies Obama water hoops understanding so they should be within s all right. So don't forget that one to capital s and sent things is with an s with the parole with a plural value. Okay, so let's test this one. Now it is. Let me just close this window So currently honkies above waters, you look at the bottom window But if it is below water, if you go back here feasibly little water no fun now is enabled. If I climbed back up Hunk knows about water. No funk iss disable. We go down, The fog s now in the right. So that's how you deal with the Fog's me. That's how you deal with underwater scripts. Immunity. So the next lesson, what we're going to do now is we're gonna create now a shooting animation or a shooting script shooting animation in script for home. All right, so we'll see you in the next lesson. 23. Shooting Animation for Hulk: So in this lesson, what we're going to do now is to add a gun, toe hawk. And after that, we're gonna animal like animate Hulk shooting with a gun. So let's going out to be at its stored down other guards. General events are general, and then as it store, they could stop in. You could type in research for God and look for a feat assets, but already found my asset here. So I'm just I'm just going to click now import. So this would no import the gun and click now on import again. So I wanted to see what's it's important. You would see now the gun here on your project folder. So we go back here. So where is the gun? Do you think it's this one? No ballistic on this one. And look for the gun that you like. So probably it's I think I'm good with this one. So what we're going to do now is to drag this gun overthrew the hook that's drag it here. So it was quite small. I'm just gonna I'm just gonna increase this one are very skilled, this one the correct sized what I'm going to do here. Let's Is this simply parent? First this gun over read this gun to hook. However, the way to parent this one is not to actually parent and in the Hawk, but parent end at the head off park. All right, so this friend hit here, it's over. Hook, Look, for I think this is hiss right hand. So over here, look for their I tend to the spine. Okay, first that right, right shoulder right are right for our miracles or they're a 10. I'm gonna now apparent that pistol over the holds. Right head. That way, if you would see once I played this one, the gun would just simply follow the movement off Hogshead. So I'm just gonna put it summary here right over there. Okay, so I think we're good. So notice now if I play this one notice now The movement of the garden. Let's see. Okay, Hawk is there. The gun now follows the movement off. Off holds, Right head. Okay, so with that, let's now Emperor, The shooting An image. Informix. Imo. So while ago, what I did was import download download there. You So that you find this one. I don't loaded an animation from mixing, which was the shooting animation. So it's this one. Let me just rename this one. So hope Shoot. Okay, so this came from Mix Imo. So it's important that animation right over here and hook shoot over here so similarly, what we're going to do now, it's to fix our Andy make tour controller. But this time we have another animation called the Shoot Animation. So shoot, click on the shoot here. Okay, So this is the animation, I think. All right. So I didn't rename it to just rename this one the shoot. Okay, so from here, what we need to have now our arrows from each of this component. So from walking right click to shoot. And this would now set the trigger. So let's create the trigger that's going s shooting on check has exit time that the triggering Now ISS is shooting. Oh, sorry. Yeah. Mission. Think and then we go back from shoot do walking. But this time the condition now s is walking is equal to true. I'll do the same thing for idle so the character can can no move from my transition from idle to shoot right click Make the incision right over here. Select this one. The condition now the shooting. And then uncheck has exit time ending from shoot to make transition. It's a like this one and then from is walking Sorry, do faults, right? So from walking to either. Now we also want to concession from smash the shooting. So what you need to do now is to right click make concession from jump to shoot. But this time the condition again ISS where the trigger is issued. All right, Same thing. Go back from shoot to job, right? Like make transition should jump. And then the transition here ISS is jumping. Now that's finished. We're not gonna add an animation from smash to shoot. So smash to shoot. Let's all shake has been present time we're doing Check it Well, it depends on you. So in my case that just see that later on And then from here the conditional Let's unchecked this one. So we wanted to shoot immediately. They think from John Listen Check has its time because he wanted to shoot immediately. So from shoot from smash to shoot the trigger is is shooting And then from shoot to smash the trigger now, ISS if smashing. All right, So now that we have this one, I'm gonna use my left click as my bottom to a bake our character shoot. So we go back now to our script, which is the whole controls. So look for the script. Hold controls. Are you over here? So, what we need to do now s on our left. Click. So left click, you shoot. So what happens here is if input get Porton down. Fire one, That's our left click what they want to happen. So honk any major not set trigger. And then just simply time and s shooting. Well, forget your semi calling. Let's see now if that works perfectly so I'm gonna make this white just to see if there are any errors. We're here. Let's look for hook. What? Your muscle over here and press f to focus where you hook. All right, so let's play this one now. So once I left click our character or hope should be able to have the shoot animation. There you go. Shoot. Right. So Okay, you go about for walking. Shoot. Okay. Walking shoot about jumping. So, Joe, shoot. OK, So that's I think that's good. Okay. About for smashing Neff ship shoot. Okay, now, that's good. What we need to do now, now a character now issue thing. What we can do now in our next video is to add now bullets on our character or fire bullets on the gun. Rights will see you in the next lesson. 24. Destroy: So before we start letting court shoot, we have to first know the foreign components destroy instant shape and transform forward. So let me say this one of its great than you seem. I looks let's do the following coat. So game object and it's create now a cube impressed after focus and looks at the script X script component. And let's go that ass destroy Cube. So what I'm going to do now here is once I click on the Cube, I want the Cube to disappear. So using that, the middle destroyed coat So that's open up this one. Okay, let's go to our heads to buy three and then Cuba, then press to focus. So we have. This is destroying Cube component here and let's in here. What do you want to happen? Is that simply destroy the game? Objects will destroy. That's a Capital D and the group's It's all the spell. So I'm gonna fix that later on and destroy game object. So take note off this one. So this script at that this script is attached to the Cube, so the game object here. The game object here refers to the cube, so let me see if this one so no test. If I play automatically, the cube will be destroyed. So you would see the cube disappear now. Another thing. ISS instead. Off letting it destroy immediately. What do you want is once I click So if input not get bought on down What bottle? Fire one So opening close bracket. So Fire one refers to our left pick. How did how did I know that your first hour left click If you go to edit project settings and input Fire one by default is our left control remount. Zero hour left Lee So what? What happens here is that Let me close this one. So what happens here is if I left click it then the game object would disappear If I left click now on the Cube the game object will disappear Now notice here that like cube is not seen in the game window. So how can I fix that? I could simply move my camera but that would take a while. But what I usually do is they select the main camera game, object and then align with view it basically now alliance remain camera to your current for you here, So let's try to play this one. So North is now. If I click on the Cube, the cube will disappear. I'm not. Anything that you can do is you can make the object disappear, for example, after 30.5 seconds. So this was now after a click the Cube. Now with this Troy after 3.5 seconds. So let's put that into play, all right, so let's just wait for the blue bottom or for this strain blue. And once I click So trick 123.5 it would now disappear. So that's how you deal with the this toy coat, and we'll see in the next life lesson for the instant shape code. 25. Instantiate: Now that you know, how did the story call? It's work. Let's now use the instantly coat Instance. It basically is to make something appear or for it to remain for you to remember the court to make an instance off. Oh, sorry for yet What? So let's treat known other objects when it needed this one. Let's say, for example, I am, uh, capsule. Now, if you want to make something appear so let's me go back here. If you want to make something appear, you need to First degree need to have three parameters. So the first object ISS, what is the object that you want to appear? And then where with object, where will that object appear? And in the third programme, Akhter s the orientation or the rotation off that object then it appears so. These were the three parameters that you need to know when recreating that when we're doing the instant street coat. And basically so if this is parameter one, this is for having three to and this is for having 33 The coat is simply like this instant shape. Make an object appear so that's instance shade the object that you want to appear comma. Where would that appeared? Parameters do. And how are the irritation of that object? So that is the cold, for instance, shape. So let's step. Let's put that into practice. So first, what do you want? Now s toe Addis cramp on the main main camera. So what I want to happen is once I click on the main camera, this capsule with appear So let me first the this one. So I have a black scene. Let's create Let's create a new script on remain camera. So that component new script. Let's call this s instant shaped. Then again So it's a good practice to put this in the folders descript snow into the folders. So let me do this now Here, put it here you it's hanging, but it's okay. They didn't put it there. Write scripts and look on its open up the instant shade script. So this will open up visual studio And the thing is the first thing that we have to be fine s what is the object that you want to appear? So the object that they want to appear is my cylinder. So give Object Street now a cylinder. And then, since it's not get on the stage, What do you want first s for this one to be in our project folder. It won't appear in my steaks yet. So under my project folder under assets, all they have to do now is to drag this cylinder here to make it a prefab or part of the library. So we call this now a prefect. So that's the this one. Now, Now I'm Ari code. What do you want to do now is to first define parameter one. So if you look at my main camera, the script is here the instant she ate script. However, if I public game objects, this is with a capital G because it's a variable public getting object. It's called his object to appear so this object to appear could be any name and not this. Once I defined this as public. If I save that one No, that's not the script on land main camera, so let's just wait for it. So if you find the courts correctly, you would see now the instant shapes creep here the object appear variable, which is this one object will appear has now this one because we made it public. Now the object to appear is our sitting there. So I'm going to simply like it here. They know parameters two and three is aware with the object appear or the orientation off where with appear with that, What we can do now is to create an empty game object. So game object empty. And this was now defined the possession interpretation of our object. So I'm gonna put that here and same thing for parameters to entry. All I have to do now is the same public transform. Why trends? For? Because we're dealing now with the possession and irritation which is not transform Variable. Let's call this as object, foreign object, position and orientation. This could be any name you like. Now we'll see if this one if you look at my main camera. So this would appear here, so just wait for it. If it that the codes correctly this is this should now appear object position and orientation and the hopes and I'm gonna simply drag the game object here. What's game object? Since I get there, you go. So with that, So the game object with appear here And with that, all you have to do now is to type in the coats. So the code is instant, straight parameter, one parameter to win three. So I'm simply gonna cap with this one. So if there's an if condition, if input don't get bought and down and get with our left leg Fire one opening close bracket . What do you want? Instant shape parameter one. What is our parameter one? The object that you want to appear. So this is private There. One copy This one. Pleased it parameters to in three s the position. So this is the position, or where will it appear as well as the orientation? So I'm going to simply copy this one. That position again can't be this one in this time dot irritation. So don't forget your semi calling. Okay? Let me know. Save the code. No, these now, once I click my cylinder with appear somewhere here where me empty game object s So click. There you go. Savory example. If I moved my game off Jack over here and see what happens. Right? Click. So they were afraid to turn blue for the play button to turn blue gave a click the game object now, or the cylinder is now here. It's the same thing now with the irritations. Every example. I want the cylinder to appear here, a list irritated somehow. Like this kid you take by pressing this one. Arbet pressing. All right, so let's see now what happens to our cylinder if I click? Click and that's my cylinder is now irritated. So there you go. So that's how you deal with the orientation with instant shaped coat. And the next lesson we're gonna use difference for forward coat. We'll see you in the next lesson. 26. Transform Forward: Now that you know how to instance Shater to make something appear we're gonna use now our thens form forward. What this does is basically it moves an object forward. So let's try that one now. So let me firstly eat this one and it's great. Now another object that say Let's make this is fear. No and it's make the new arrowpoint on dizzy access. Listen, play forward now What you would know before we could transform this forward, Remove this object forward. We could now use our rigid body component because when you do our truth in game, this would now allied with our enemies. This would no act as our bullet. So let's add the origin body component. Oops, sorry. Rigid body not rigid body duty, but the region body component uncheck use gravity. Now what we're going to do now is we're gonna add a code on our sphere. It's a new script and let's go this ass Move! Object forward! This script is named this move object forward. You could name it. Is any any name you like? But what do you want to happen now? Is to move this or add a force. Do this object so that it moves forward. So how do we deal with this one? First we have to get now this rigid body component. We have to script this one. In order to do that, we're going to create a variable. Let's call it, for example, public region body. And then that would be rigid body ing. And let's call this ass sphere rigid. Don't forget to send me calling. And then what is rigid body so spirited now, which is? My rigid body is equal to what rigid bodies are Variable is able to get component So take note. Distance warms, fear mesh filter measure under spherical and the rigid body are all components So what they want to get now r s their engine by the component So spirited. Now you first this component here with that let's see if you have any errors. Oh, so let me play this Well, I'm just checking if there are no errors on my coat because sometimes this which the region's body and luxury for two small be or it's a capital B. So it's a small good. Okay, so if it's a capital B there with errors, if it small be. There are no errors. Now that you have this one, What we can do now is we could think of with the properties of our aged body. So, for example, spirit Egypt and then I could use the use gravity, and we could make it false. Same things for your rigid Don't. For example, mass changes to 300. We're now holding the components on the rigid party here. But this time, what I want to happen is if, if pressed, May left Parton to get bought and down Fire one. What do you want to happen? It was fear. Ejected. I'm gonna add the force that look, transform it or move it forward. And how How hard is that forest? Let's make it 300 to this. The value of the force. Okay, so that's my affair. Seem this one. So what happens if I click this one? It took my now move forward. So let's try that one. So what's a click groups? So there's an area here. Objects. Alright. Didn't did this group. Oh, okay. So let me come in. This one. This was the script from a while ago. But since I deleted the game object. It's looking for it, so I'm just gonna calm it. This one. Common comment Comment Common comment. So it's trying this one now, so don't worry about that one. Since I didn't to the game object. It's still looking for it. But now know this. If I click, it would now move forward. So why is it moving this way here? Because of the position of my camera. So main camera game object again, a land review. Listen, they'll move my camera, So notice if I play. I'm not sure about that. Do you think? Here. But if I play, this would now move forward. All right, now with this now in that, say, for example, if I wanted to move backward, I'm just using negative negative transform forward. So let's clean it again. So click on this one once a click, if they now move backward because it's negative. Same thing if you want to move it, they're right. You just making things for him, right? And then if you wanted to move to the left, just make it negative things for right. Same thing if you want to move it up once for up or negative transform. All right, so those are the three values that you want to use the up, down and forward with a negative if you want it unders on the river's values. All right, so that's it for the day. And with all of the scripts and destroy instant straight and transform forward, Let's go back to our hook or to our main seem to continue in the next lesson where we're gonna put this codes into use. 27. Coding the Shooting for Hulk Part 1: So in this video, what we're going to do now is we're going to use to destroy instant shaped entrance for forward script to make hog shoot. So let's first create the bullet. Three The object sphere. She could download the footage from the acid store, but make sure you have the other escalator and a rigid body component. So this is now my bullet. I'm gonna add the material to this one to right, Click eight material. Let's call this ass bullet Take shirt and I'm gonna make this green And they simply dug this, but it that sure here now that you have your bullet, make sure bullet now has a collider and a rigid body. So my bullet testicle later and I'm gonna add now a rigid body and I'm going to uncheck use gravity. Let's add notice. Form forward script to this fear. So let's rename. This one has full f prefab. So it's a component. New script. Let's call it as move bullet for a week. Let's edit that script So public rigid body it's called as bullet region on the start. Bullet rigid is equal to get component And who's gonna get component rigid body. With that in mind, what we're going to do now is to use our at force code and Albertans form forward coat to move the bullet forwards. Let's make a run at 50. Right? So let's save that one. Now that you have this one, what you need to do now is to drag this bullet pre fam over here onto your projects folder . So let's just drag here. So put it prefab. Let me drag it again. So there you go. Now that's there. We could not believe the bullet pre fact from our scene. What we're going to do next is the simply instant shaped the bullet Wall Street Click on Hawk. So before we do that, what we need to do now s two on over the whole controls. We have to comment. The is shooting trigger coat. Why? Because what we need to see is where our direction, the direction off our bullet. Right. So let me Firstly, this one. I like that a while ago and I was checking the coats. So what we're going to do now is the simply instant shape. Now, the bullet once we click on the whole controls, so from the Hawk Idol clicker, your whole control script and then ended script. So over here, that's first defined. Now our game object for our bullets of public game Object through the capital old. Let's call this. Ask my Put it. Save this one. Let's see now. So let's just see the goat Hold Any matron is not exist. Let's check. So we have an air over here. Work, animator. Well, come But C o I deleted the hook. Any major. Sorry. So let's get that one public any make your and then whole anime. Okay. Do you have that in your code? But I just added this one public game object My bullet. If I save this one, let's see if they are still airs in my coat. So it's a good so very ago. So my if you would see here my bullet is now here. Right? Then we have the whole any major here. So what I'm going to do now is to simply drank the my bullet here. My bullet prefab here on this field here. So I'm gonna simply drag that one there next. It's also position where our bullet will be coming from for public transform Bullet Origen Now the bullet Origen now will be coming from the bullet testing So let me save this one If you would see here we click Unhook maybe clicking Hawk and the Bullet Origen now would be my pistol So little search for the pistol here and simply drag the pistol over there, Drag it over there So let's save that code And then let's add now, Once I fired, I'm gonna make work, should to shoot a bullet. So over here, let's use our instant shape code instant shaped. And then let's call this one my bullet over here the bullet origin doc position and then our third parameter iss our rotation. So let's check if that works. So noticed that on my top window let's see where and how the bullet is appearing. So let's just make this one. So let's see where the bullet will be coming from. So click can see the bullet flick like first the bullet. Okay, I think we're good. So? So the bullet is right over there. If you could see right? Not sure if you could see that one, but it's permitting. Okay, Very good seat. Not sure if I could see. Okay. Lets see. Okay. See that one just quite fast. It's going to make that slow. So for you, the check the move. Bullet forward. Let's make a to 5200. Let's see where the bullet will be coming from. So this is why I commented the animation or the shooting animation? Because I want to see where the bullet will be coming from. So click. See that one. Go on top of you. They think we're Yeah, you can see it. Lucky the bullet. Now it's just enlarged the bullet. Prefab. Just get it. Let's just kill it that way. I can't see it. All right, The bullet. This is there. But it's OK. If you would see you let me scare that. They think it's let's make it boring. Three. You might have to change the direction, but I just I'm just gonna see where the bullet is coming from. See that one? Yep. The bullet iss moving back, moving apart. So all they have to do now is the simply make it negative. So let's check that one again. Okay, See that the bullet now is moving downwards. All right, so the thing here is if you would see what we're going to do, the work, what we're going to do to do in the next lesson is we're going to destroy the bullet. Because if you would see, it's just here and the next problem that we're going to solve the next video is if I know un Corman, this animation look at what would happen now to our bullet. So they just play this one. So know this now my bullet See, the bullet now does not follow the directions off the bullet admits first before doing the animation. So we're going to debunk that in the next video, so I'll see you in the next video. 28. Coding the Shooting for Hulk Part 2: if you would look at our code if I un comment now, This is trigger shooting. Let me play this one you would see Now here. What would you see here? Is the bullet appearing? However, it appears before the shooting animation. So let me click. See this one? The bullet now is appearing at the same time with this shooting animation in order to fix that one. What we need to do now is toe ad a delay in our coat. She already to add delay, never coat. What we need to do now is to create a timer. So to create the timer just below this void update coat we need to create a timer. And let's go this time were a shoot bullet, an open, close racket. And we're going to transfer this instant shaped coat over here and let's now at the time or so yield return you and let's wait for seconds. Let's make it so the delay would be about 1/4 and 1/4 of a second to this point 35 seconds . And we're simply going to call this code once we click on there. Once we left click. So over here it's decoded Start car routine. So start QWERTY now basically calls this cold Start coveting. And what? Call that you want to get to start parroting shoot bullet. So let's see if that works. So know this now in my top window if I click So let's just wait for this blue button to appear in this blue Baltin. So if I click now, you would see now the bullet appearing once hold is now in that position. Okay, See that one? Okay, now that's working. Fine. The next thing that we have to do now s if you would see our bullet now is not disappearing . So what's going to happen now is after a certain number. For seconds, our put it with disappear and at the same time, if it collides with a tree or with the tearing or with any object, it would also disappear. So with that, let's go now with our let's go to our bullet prefab. Unless added the coat, it's a bullet prefab, then ended script. What do you want to happen here on the state function is to destroy the bullet after, let's say half a second, so destroy have in game object 0.5 seconds. All right, so this one would now destroy the bullet after half a second. So this script is attached to our bullet prefab. So meaning the game object? Your first hour with prefab. I'm got I'm gonna add another UN collision entry code in coalition. Let's call this object hit. So what do you want to happen in this court s? If the bullet now collides with any object with any region body object, the bullet will be destroyed. Bullet will be this story. So in order to do that, just type in destroy and simply game object. Right? So once it detects are collision, it would now destroy the game object. So let's see if that works. So this look at the top screen here and even let's also look at the higher key if the bullet is being destroyed. So click a year ago. So the blown of the prefab is now being destroyed. Let's try now to shoot monetary right over here. Okay, First, make tearing. All right. Okay. Okay. Let's try to shoot over here shooting the tearing, and it's being destroyed. All right, so we'll see in the next lesson and then the next lesson. What we're going to do now is we're going to destroy Daniels. So see you in the next dozen for ever find a lesson on striking tunnels. 29. Coding the Shooting for Hulk Part 3: Now that our bullets is working fine this time, we're gonna now go tennis so that he will be destroyed. Want to sit here? But it so there was an enter in the previous game. This one should now be. Haven't I hear it is just wrong spending gate. So this time, what we're going to do now? So we're gonna add now a cube. And this cube now should never rigid body and a collider. And this would be the collider for Daniels. So this make short for this sick you. So I'm just gonna increase the size here. Let's make it a parent of sandals and make sure that this cube now or this rectangle now does not intersect the ground. Right? So let's just make it a little big so that the bullet has so so whole can shoot him a respect virago. So let's radical either in testicle either. Now it's also add a rigid body component and it's and shake cavity. So let's name first this ass danos collider. So they just play what would happen? So this Let's let's just make sure that the Cuban not for so that's good. So know this now in my shoot. A bullet over to the over the the cube or the Okay, I should have bullet. You could see. Well done. Right over here. Okay. Right. So what would happen here is what we want now ist for the cube to disappear once the bullet hits the que so over here, let's go back here. What you need to do now is if object hit, I thought Game object. What name is equal to is this Cube 10 escalator? Simply coffee. This one, The Dinos Collider back here. Then we're simply destroy. Destroy the game, objects. Object hit Thought. Name option. Okay, so let's try that if that works. So what I'm gonna do now? Yes. I'm gonna play this one. So let's see. I'm gonna move, talk a little bit closer, and let's try to shoot. It sees now that the queue disappears. What we're going to do here now is to make this palace collider apparent off values. So I'm gonna select a nose, and I'm gonna parent him under the Channels Collider. So it's either that or export of them should disappear. So this that sweet for this blue bottle, Let's get a little bit near, but shoot, See? All right, so that it's now disappears. So with that in mind, all we have to do now isn't the time to school later. You just have to uncheck the mesh render. And if you're gonna be the game now, we're gonna play the game. Tightness now should disappear, and your game should be working property. All right, So see you in the next lesson. That's gonna add some sounds to this game. 30. Adding Sounds FX and BGM: So in this lesson, we're gonna download now sounds and import them into unity. So I'm going to sound Bible, and I'm gonna download now public domain. So it's free to use this. Have an environmental sound. So I'm gonna don't look now is an MP three and for their or that's great. Now I want, for example, apartment to me. So let's try this one. Not that it's probably good. We're gonna use this one, right? So I'm gonna download this sounds. So this is royalty free to the public domain. So let's imprint this sounds now in unity. So where this or are those two sounds? Okay, so this week, for the wind to finish sludge in the thick sergeant gun. So I'm going to create the folder. And that's called this as this sounds folder. So over here, just simply gonna download this sound here. All right, So the Sounders Simple e seniors. So what we need to do now is to add a sound on our environments on our let's put it on our main camera. That's great. Now on August sores component. So let's call this as an artist source component and simply attach. Now, your clip there support your ah, gently peer and social re Oh, was a simply dagget near hold on. So let's may wink there and then want to check playing awake what this happens s and to start a very game, this sound now place. And of course, since this is a backward music, we simply click on loop. So let's try that one. If this sounds would be the sounds were work. So we just wait for this way. All right? This sounds right now working. It's also lessen the volumes quite loud here. Yeah, So I'm just going to play this one just to check on the volume. Can't you just sweet for it? I think that's better. Now, what do you want to happen now, iss? Once they freshman left shift, I want now hall to roar. Case I have this sound here. So this time we're gonna use now our coding. So picking hook and let's add now a south toe component, click on order source In this time, click on this one and look for the roar sounds, But this time unchecked playing awake and uncheck loop. So what do they happen now? Is we go that our whole controls and on my left shift. Once I press left ship, I want the sound to turn on. All right, so I want to trigger the sound. So let's go now Here. Let's calling out this some component so public or just source. And let's call this ass like roar and what this whole crew or so hardcore now will do for this audit starts component by typing the scope. So a whole drawer is he going to get component? And let's go this ass. Let's call the let's call the order sores component so that now that the average of the order sores component which has the roar audio clip, all I have to go toe is on my left shift controls. What I'm going to do now is to play in itself. So I'm just simply copy this one look drawer, but play and all they wanted, not play. So let's try that one. So let's play this one, okay? So just wait for it. It takes a while to know once you have a lot of assets now, this time I'm gonna press my left shift. You would see Now look, Rory. Hey, jump left ship is now. Hurry. So that's it for this lesson. And the next lesson. What we're going to do now is we're going to add made Mendel, and we're going to publish our game, So see you in the next lesson. 31. Publishing Your Game: So in this lesson, we're gonna add a main Manu to our game. So we have to go now to great. We have to create a new scene. So file, you seem Let's see if this one s main menu So on the scene's folder, let's call this ass main many. Now, with that, what we need to do now is to create a canvas. So came object you. I canvas the canvas is where we would put all our images. So over here I know have my images, Smith me just like I. So these are all PNG images and I took a screenshot off the game a while ago, which will be used for my background. So under canvas, what you need to do now is to go to game object. You I and then raw image. And then on this raw image, we're going to simply important our BNG images into unity and put that under the picture picture field here, letting the importing first here. So let's create the new folder for that images, main menu images, and we're going to simply select those images and put that in our main hman images. Right? So that's select no Amertil image here, and we simply now put our screenshot there, so just simply drag and drop that in there. So what you can do now is to simply scale this background to the size off your canvas that's altering name this one do background. No, what I want you to see here as if I skill this one off a move. My windows. No, that's not the bottom window. It does not scale. All right, so what we can do now to fix that one? They simply go toe background and then was right to the canvas and simply change this one. Do scared with Screen Sky's the canvas scaler to this scale with green screen size. So if you would see if I scale now, my screen this now skills as well. So this is the same thing for the other bulletins of game object. You I raw image and this one. Let's have now the whole image. Split it here, scale it by pressing hard. Or you could just use this spot in here. Let's go. This is Hawk and then game object. You I get make sure it's the same process. Thanks short. Let's use the versus. So this Rop and images, because I want the background to be transparent. Then game object. You. I wrote image. This time they should be Fallows. So drag it here, then with it there. Just scale this one. Then, of course, let's have our click to start. Bought it. So you I rural image. Just put it here and drag or click the start button here. So what we're going to do now here is where we're going to other code. What's I click quizzically? Conflicted Start. This was now open our level. What seemed So let's go now to find and build settings And let's remove this scene and you want to build the main menu seen in the level one scene. So in order to do that doesn't go through scenes and drug level one, and you're mean me new. But since we want the main menu to load first we put that on top, so we simply click and drag would drag that one and put that on top so there may be no we'll load now. First was clear a game and then and I reflect the start button. So this is channels let me just rename them that I noticed. And then this one is our start Bottom. Let's other component in our start coat New scream and let's go this ass gold since script , let's edit this crap. Oops. So let me just delete the coat. So this what do you have now and just typing first using unity engine Not seen management and then all the updates off If input don't get both and down fire one opening close racket what they want to happen. So seeing manager not load scene And then simply type in the name of your scene to the name of the sea that I want to load You could see tears on file bill settings is basically level one, and that's with a capital l. So that's level What? So with that, let's see the coat and let's try this one. So no tastes When I play this one I want to be, I want I don't want it to become to be surprised of the error here. If I click the start, you would see now level one, some white images. That's okay. Okay, that's part of it. Because we're stand. Unity is now building it. Okay, We're still working, Onion. However, if we build it into a game that would not you would not see the white. So in order to build this one, you simply go to file build, said things and then shoes where you want to build it. In our case, I want to build it in B C. Max limit and click and build. And let's say this, what s whole versus tennis game? So let's click and save. So once in Silicon safe, this would now love the game. Our Sorry, this was Now build the game and this will take a while. I'm gonna pass this video and stop once the building is finished. All right, so the building is finished. Now, don't forget received a folder, So let me know. Open this one up and see how the game goes. So this now, a standalone file. Where was that? And I'm gonna just use high and click on play. So what's likely can play? You would see now this one here conflict the start. This is now your gate, right? That's now can shoot way. You could now tell your partner. All right, so that's it. and I hope you enjoy for Let's think for Dublin and thank you so much. And I hope you enjoy this course. So let me just skip this one. Discretion don't after the beat and let's just equipment.