Unreal Engine 5.2 Absolute Beginners Tutorial - Starter Course 2023

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
welcome to this exciting Unreal Engine 5.2 tutorial for complete beginners if you always wanted to dive into the world of game development but have never used Unreal Engine before then you come to the right place in this step-by-step tutorial we will start from scratch and guide you through the process of downloading and installing Unreal Engine 5. then we will explore the user interface teach you how to navigate around the engine and show you how to place and manipulate objects in the scene but not not all we will also introduce you to basic modeling techniques applying materials to your objects and using the powerful blueprint system to create a door that opens and closes lastly we will add a cut rate to your scene so whether you are an inspiring game developer a Hobbies or simply curious about Unreal Engine 5 . this tutorial is the perfect starting point learn to create an action game in a real engine 5. start the first lesson for free at unfgames.com welcome to Unreal Engine a tool that will help you to develop the game you want by giving you a framework for graphics coding and a lot of cool things that will make your development much easier the first thing you need to do is to use click on download and as soon as you do that you will go to the page where they tell you what kind of system requirements you need you just need to scroll down and go to the download launcher and as soon as you do that you will download the Epic Launcher the next thing you need to do is to create an account you can just click on sign in and here you will have some choices you can sign in with epic with Facebook Google whatever you want or you can just sign up for a new account and you can choose which method you want for your account creation this is the epic games launcher and if you play some games you will be familiar with the store and the library but we're focusing here on the Unreal Engine tab in the news you will see all the news related to Unreal Engine weekly spotlights bright spotlights new things that are coming out new games new projects all the news are here then if you go to samples you will see projects that you can download and try them for free so this is a great way if you want to learn something very specific like for example Automotive or animation or maybe you can try the Lyra if you want to make a complex game you can just download them for free and try it on your own the next one is a Marketplace this is really important because you can actually get thousands of assets paid of course but if you go here for free and then go for free for the month you will be able to download five free assets for the month and the next month you will have have another free assets so make sure you don't miss them out the top I want to show you is the library here you will have the engine versions in our case we're going to use that 5.2.0 you can add new version by clicking the plus icon and just choose any version you want I'm going to click here and if you want to access any previous project you can use click in any of those projects and it will open the Unreal Engine editor next default is projects you have previously downloaded before either the marketplace or the samples and you can use add the files to your project or create a new project let's start by launching the 5.20 just click here and you will be good to go so this is the Unreal Engine project browser here you will see different presets for example you have games and you can choose which one you want the first person game third person top down or vehicle you have film you have architecture automotive and simulation as you can see Unreal Engine is used in a lot of different Industries other than video games but for our case we will focus on games so we will use click on games and instead of starting from a template we're gonna choose the blank project here you will see the location of where your Unreal Engine project will be saved and here you will see the name of the project I will call it my first UE project you will also have the quality like maximum or scalable I will leave it at maximum the target platform is the desktop and I don't need the starter content for now I will show you how to edit later and just click create as soon as you open the engine you will have a window similar to this one the first thing that will drop your attention is this big screen which is the world so this is the viewport it's a representation of how your game will look like before you play it in the right side it's all the actors that are in the viewport we will take a look at those later for now I will show you how to navigate inside unreal so if with my mouse I can hold the right Mouse click and I can choose rotate around while holding the right Mouse click you can press W to move forward s to go back A and D just like any game you have play in PC the next thing is the middle Mouse click you can just pan around like this in two directions the next one is the left Mouse click if you move it you will see that you move like in a spaceship just move around with the left Mouse click you will move in two directions like moving forward and backward my favorite method of navigating is using the right Mouse click and use the wa USB you will see that I have a speed of which I can navigate you can change the speed here with this number you can go here for example I can go back to 64. and you will see that I moved much faster or you can change the speed on the Fly by holding the right Mouse click and the scroll wheel you can just go down with the scroll wheel just like this just press the scroll wheel and you will be able to move faster or slower so now that you have this let's add an object here on the top left corner you will see a green plus icon if you click here you will see that you have a bunch of options that you can add you have the basic actors and you have shapes let's drag a cube here you will see that our environment is very big and if I want to go here to the Cube It's a little bit hard so what I can do is press f and just by doing that I am focused now in the object that I just press F and I can just rotate around by holding the alt and left Mouse click or the right Mouse click and holding out at the same time I can use zooming and out let me move this here what I just did was move the object using the Gizmo in 3D it's very common to move objects by using the move tools the rotate tools and the scale tools this can be found here if I go here you can move around you can click here you can rotate or you can go here and you can scale either in One Direction or two directions if you want but clicking here is not very common what I usually do is to press w e r by pressing W I can just move around I can press e to rotate I can press R to scale to make it bigger or smaller I can press W again and you will see that you have an icon here that it says port and local if you see the word icon it means I'm using the word coordinates which you can find here in the top left bottom left corner sorry here you will see the Gizmo it's the same as this one but if I go to local you will be using the local coordinates I'm moving this here I can rotate around a movie to the local coordinates depending on the rotation of this object now there is something that is happening while I'm doing this if you notice in my right there are some numbers that are changing these are the properties panel the property panel is basically all the information that you have for your object in your game all the objects in the world have a transform property which is a location the rotation at the scale of the object as I move here you will see that the properties are changing so it means I can also change here by holding the left Mouse click and can just move around or I can type a number like for example 500. and if I lose the sight of my object I can just press F again to see where it is I can use both ways the next thing you want to do is to check or uncheck the grid by default is 10 but for example you can put this one to 500. and you will see that my grade became much bigger now I can just move around my object like this and it will snap to 500 units or 500 centimeters let's go back to 10. or I can just uncheck this and now I will move freely where I can have less precise move for my for my object the same can be done for the rotation by default is 10 you can change the number to anything you want or you can uncheck this and you will have the snapping disable and you can rotate to any degree you want and the same for the scale if you remove this go to r or the scale you will see that I can scale my objects like this awesome so this is pretty much the basics of the viewport the last thing I will show you is how to play your game you see this green plus play icon you can just play here and you will play where your camera is at as soon as you do that you can just play your game just like this so now that we know the basics let's start by creating a new level let's create a new level now we can go to file new level and here I can just choose a empty level click create do not save this and now you will see this black screen this means that we have a new word but nothing is there so the first thing you want to do is to add some lights in Unreal Engine 5.2 there are better ways to add lights instead of going here and go to lights and drag one by one for example I can drag my directional light here I can go there and maybe add my sky atmosphere and little by little I'm adding some sky into my environment I can just delete those you can go here to the outliner and press delete but in Unreal Engine 5.2 there is a better way to do it it's by using the environment light mixer you can just click here and then go to create skylight atmospheric light sky atmosphere biometric cloud and create height file and just by doing that you will have all the things that your Sky atmosphere should have there are a couple of things I want to change here if I go to my skylight I should make sure I put Real Time Capture and now I'm good to go I'm just gonna create a floor now that we have our lights let's save our levels so we can access to it later we can use press Ctrl s or go to file and then go to Safe current level and then you will see this window here this is the content browser let's right click here into content and create a new folder call my first project and here I will put the name the level zero one that's the name of my My Level please just click save and now my level is safe let's add the floor so we can have our player walk around we can use click dark green plus icon and you can go to shapes and go to curve and you could put something like this but in Unreal Engine 5.2 instead of doing something like this which is totally valid you can delete this you have different selection modes here the first one is a selection and then you can go to the modeling tab which is automatically here in 5.2 so you can go here to modeling and you will see a new window I won't go through all of this I just want you to know that you can create a box here and with the default settings I can just click here and I will have my box let's click accept and the next thing I want to do is to model something so I will go to the poly model go to poly edit go here and then move around like this you can just click here click on this face move it around just like this then go to other face click here move around until you have like a little floor so let's just move this like here that should be enough Alex click accept and now we have a little floral for our game if you want to go to the previous mode you can just go to selection and now you can just click play and you have your floor here before we continue to add more things let's open the content browser if you go to window go to content browser and choose one of them you will see a list of folders that your project has this is extremely important because this is how you will organize your project you can also go to your level and press Ctrl space to open the content browser here which is what I will do for the rest of the project most of the time what I want to do is to add a character to my game and in order to do that I can go to at and then add feature or content tag I can just choose a third person character click add to project and as soon as I do that you will see that I have new folders I have my third person folder I have my level prototyping folder and basically all the assets that I need to have my third person game going on if I play nothing will happen because I haven't tell the engine that I want to use that third person game mode so I can just press Escape and I can go to word settings and here in the game mode override I can just click here and then go to third person game mode so now when I hit play you will see that I have my character here but there is a little problem while I can move my character around just by playing any other kind of game I can just press Escape I can press play from here and my character will fall and I will continue to fall until eternity and that is because I haven't tell unreal where I should start my game in order to do that I can just click Plus go to basic and then go to player start then you will see an arrow here that's the arrow where the player will look at I can just rotate this like this and now when I hit play no matter where I am even if I'm here I can just hit play my character will always start from here unless I fall down of course so now that we have a character let's just try to create a simple level we can play on in a real engine 5.2 there are better ways to create levels if you go here to the selection mode you can change it to the modeling Tab and now you can go to cube grid as soon as you click on this you will see a greeting the world and you will see a yellow block that I can just hold the left Mouse click and paint and if I press pull I will pull the polygons up and if I press push I will push them down so I can just press pull here and if I want to create new geometry I can use for example create a little Bridge like this I can just press pull and if you don't want to click here you can also use the E key or the q key so if I press E I can just do something like this and then I can just grab this press e if I want or Q if I want to remove them another mode you have is the corner mode so I can just press this for example and I can go to Corner mode and you will see a corner in the streams that I can use I can click on those and just press e to pull them down or push them down like pull them like this click done and then I can just click on this and press e and now I can just select the sites press e again select this press e and just like that I can also create some columns here like pressing e like this if I want it or like a little gate for my levels just by pressing e it will connect automatically everything and the good thing everything has UBS we will take a look at those later and now you can just go here and adjust the level to your liking if you want you can use go here and press e and now you can select all of those and go to the corner mode select these two points and press Q and now you have like a little ramp for your game if you want it let's click accept and as soon as you do that you will have a model that you can play with so let's go back to the selection mode and you can also use a shift one if you if you want like I go can go through shift one shift five to go through my modeling mode on my selection mode I can click save and play and now you will have a little label you can play with you can move around and you will have a character here and here you can decide if you want to make things bigger or smaller or you want to change the layout and with the cube grid is extremely easy to do that let's add more content to our project the easiest way is to control space to open our content drawer click on ADD and then go to feature our content pack inside of here you can go to content and there is already a starter content I highly recommend you to start with this because it has a lot of examples you can take a look at so you can go to add to project and as soon as you do that you will have a lot of Assets in your project so let's take a look at what assets we have inside the starter content you have different folders like architecture where you have the static meshes we will take a look at those later audio blueprints HDR Maps materials props and particles now what I want to do here is to use some of this architecture to lay down the basis of my house here the way you work with unreal is with 3D models so with the starter content pack that we got we already have an architecture folder that we can use so what I can do is to drag this here now make sure you have the snapping options here so that when I rotate I snap to 10 degrees and everything will snap to the grid so I can use go here and with I'll click I can just duplicate this one you can have two doors if you want or you can control space and what you can do is to change this for another window if I click on here and click on the object you will see here that I have an arrow as soon as I click on this you will change it to another static mesh if I double click on this you will see the static mesh window what is the static mesh is use a 3D model you can either create it inside unreal or any other 3D modeling application like blender 3D Studio Max or Maya the static mesh can have Collision and can happen material let's close this let's try to decorate our environment let's try to alt click to duplicate another time and if we want some other walls we can for example put this one here but you see this one is taller so I don't really want to use this one you already have the sizes here I can either drag this wall and put it here and let's see the snaps it does so I can just go here and I'll click to duplicate this and put it in position alt click and if you want you can also put this to a hundred and this will snap easier I can rotate this and then go back to 10 there you go and now you have a little wall you can use okay or you can just go back here and you can just leave it like that now if we play our game you will see that we have a house here I can go here and I have a little house now this is too small so what I will do is to move this thing here and by holding alt I will duplicate this meshes I will do it one more time just so that I have more space to work with inside the room and now what I can do is to move this thing here and there you go now we have a wall what I can do here is actually change this so I can go to modeling I can go to my Cube grid actually before we do that make sure you click here okay I already click it but make sure you click it so that you can modify the existing static mesh and now we can press e and you will create a floor click accept and there you go so now we have a little house without the roof so what I can do now is to create a roof using the modeling tools so let's add a roof to our house we can just go to the modeling mode and create a box here click here click anywhere in your map and click accept now I will move the box into a position where I want my roof to be so I will just do something like this and then I will go to the poly edit you can just click on one face and make sure you have the face selection here otherwise you won't be able to click it and just move it like just like this do the same for this one you can just select this face and now you can put the thickness of your roof in my case I want to move it a little bit down just like that not too much so now what I will do is to insert the edge Loop so I will put it more or less here click done and now I will select this Edge and travel here to select the other Edge by holding shift and I can select both of them and now I can just go up like this just like that so you see that there is a gap here we can fix this we can go to this face and just move it down just like that how we can do the same here with the same face and move it down there you go now we have a little roof for our building next click accept and what you want to do now is to close this Gap so let's do that now so the next thing I want to do is to add a wall so what I will do is to select this meshes here select all of them and make sure I have my snapping to 100 and I can just duplicate this and I can duplicate again just in case I don't need this once here I can delete those I can do the same here I can select all of this and duplicate it there you go and now if I want I can just change one of this for example I can put a window I can press Ctrl space to open the content drawer and put the window here or it could be like I want it here I can just press this icon I will have the window here I can do the same here if I want it there you go now we have some some windows here the next thing I need to do I need to duplicate this so what I will do is to press Alt and go down again and I will go to the box too which is my roof and hide it and what I will do is go to modeling duplicate to create a new mesh accept and now this will be a new mesh how do I know that if I go here you will see that I have my roof here and another roof here now what I can do is to go to the poly edit shift click here and I can just move it up just like that just so that I can have my Boolean next I will hide this with h and I will select all of this all the parts of the root just like that and also the second floor and I will put merge here and as a new object and delete the inputs click accept and now this will be a whole new mesh come by so what I can do now is go back to my box here and I can click here and click here and then I can go to mesh Boolean and I can put the difference either B minus a or a minus B which is what you want so now that you have this you don't need the inputs so click accept and now you're temporarily roof is gone you can go back to your box too and now you have a little house with a roof let's play our game to see how it feels like we play here we can enter the house I know it's a little bit dark so if we want we can try to add some lights so let's try to do that now before we add the lights I want to put some materials in this what is a material it's very easy I will show you if I open the content drawer with control space you will see here in the starter content I have some materials I can use so if I want to preview how it looks like I can use drag and drop this one and place it here let's say I just want to use this spring in all my walls you you will see here in the right that in the details panel you have a material that is using this asset you can just go here place it and it will change the material so what I can do is select all of those just like that basically all the walls here I can also use the outliner if I want it there you go that should be all of them and now I can just go to materials and I can just use this Arrow and now all my assets are using the same material now there is a little bit of an issue here and what you're seeing here it's called C diff when one object is actually in the same position as the other so what we can do is to check all of them and move them a little bit and just like that your problem is gone and this part is also fixed so now what I want to do is to add some materials into the roof maybe I can use like some wood like this one or maybe something like this this one should work but as you can see it's very big so we're going to add some UVs or going here to the modeling tab and then we will go down until we find the UVS and we will put the project projecting UVS will basically project the model into that 2D plane so what we can do is to actually put a box projection so we can also get this part and if you want to see how your UVS look like you can go to the checkerboard and you will see the size of them what you're looking for is basically you want this to be a square so what you can do is to move it around for example the in the X Direction you want them to be a little bit wider this part you can leave it like that let's go back here to the original material so we can take a look at our how our wood will look like and then what we can do is to change the scale so now our texture is too big so we can for example put five by five and that should make things better let's try 10 by 10. that's a little bit too much let's go 555 anyway we're not gonna look at it that much so let's accept and if I want it let's go back to our selection mode to have more space in the screen ultra space here and I can just put another brick if I want it I could do that or I can put for example this one or maybe this one is fine it's just that it's too big so I will go back to my modeling tools again and this time I'm going for layout and inside of layout I will change the repack mode to transform and I will just change the scale to two to make them smaller maybe three something like that could work and just like that I can just accept and now I have my root and the walls of my house with the material you can do the same for this floor for example I can put this ground here if I want it or I can put this cobblestone you get the idea so let's try to put something a little bit different here for example some wood that we can have inside so what I will do next is to separate this mesh into a new one so I don't have the same material everywhere oh let's separate the mesh that is here from the rest and it's very easy you can just go to the modeling Tab and then go to Triangle selection then I can use paint here all the polygons that I want to separate but that's a lot of work let's click clear here and instead of using the brush I will use all within the angle let's just try with an angle of 10 and see what you get so if you click here you will see that all the polygons are selected I can do the same for this just by clicking I don't need to hold shift or anything just clicking here and here make sure you got everything and now what you can do is to basically separate so if you separate you will create a new mesh let's accept and now this mesh is different from this one so what we can do now is let's go back to our selection Ctrl space to open the content drawer and now we can put something like for example this couple stones or maybe if you want maybe this one for this one anything you want let's just go for the Cobblestone for now so just like that now we have different materials applied into different sections of our mesh I could try to do the same for this one but I noticed that I don't want I don't want it so I will go to the cube grid and I will just press you to delete these parts and I will do the same here and do the same here there you go click accept and now you got a problem where a material is not being used so what you can do is to go here to the attributes go to material editor and you will see that you have two materials go here and delete this one click accept and now only one material will be applied to your mesh and just like that you can separate different meshes if you want to combine those you already know how to but for now this is good enough for us if we play our game use have like a little ground where you can walk and then you go to the inside and you have a little house so what we will do now is just to add some props add some lights and show you more features you can use in unreal I think props to your environment can really make a big difference let's see how we can add some of them if we press Ctrl space to go to your content drawer you can go to props and here you will have the starter content props let's add some frames to this so let's look for the door frame and try to put it in position just like that move it a little bit and it should look fine we can also add a door if you want so let's use add a door here and you will see that the pivot point it's actually on the right place or you can just remove the snapping to not be too precise and there you go because the pivot point it's in the corner if I press e to rotate my door will just open like this so let's just keep it open for now let's do the same for the windows we can find some window frames and put it here let's just move them just like this and put them in position there you go it should be good enough let's do the same here alt and click will copy the window that looks like it's a little bit up so I can just move it down a little bit and also move it down a little bit there you go I can do the same for this one I can just go here and duplicate by holding Alt and just like that I have another window and let's do the next one I will show you a really cool trick if you hold out and move you will duplicate but if you hold shift you will move the camera with you so I can use put it here it looks like everything is working let's try to put some props inside so what I'm gonna show you is you can use for example a chair here rotate a little bit you can put a table here you can put another chair if you want and alt click and put another chair so what if I want to create different actions of this like for example I want to use the same asset here I can go here select all of them and without and click I can just copy and this can work but it can take a long time if you have a really big environment so what I will show you is how to create instances let's select all of those right click and go to level create Pack level actor you can just leave the default settings like this the Pivot Point can be in the center minimum C axis which it means it will be kind of like in the table let's just click ok and now let's create a new folder called instances just put a name and I will call it Mass type and I can also save the blueprint here and there you go we will take a look at blueprints later but what you have now if you take a look at this is now you have a different actor so what you can do is to put this chair here you can move it around you can duplicate this one and put it here and do the same here now what if you want to make some changes you can go here go to level edit and everything will turn gray except for the actor you're editing so now you can put some other things for example you can put this statue here and let's say you don't want three chairs you only want two you can delete one of them and then you can just right click level commit and just like that all your items will be updated awesome so now let's keep adding more stuff for example some brain pillars we can use here if you don't see let's go back to alt three this will change the viewport mode so by default is lead you can go to unlit mode or wireframe or detail lining let's just go to on lead mode because our environment is really dark for now if I want I can just make this one bigger just like this and I can just duplicate this part and do the same here I don't see it from the outside so it doesn't matter what else I can do I can put I can put some lamps so for example I want to put some lamps here and then later I will bother with the light so I can just put some lamps by holding an L shape I can just duplicate them okay let's see what else we can do for example we can put this corner here if we want it for example here I don't know if that makes sense but uh it's a weird Corner anyway what else you can do there's not much so let's add a couple of more props so for example this one you can put the Shelf rotate and you can put some stuff like for example this little statue here you can change the size by pressing r ated and you can do the same here and this one you can leave it empty if you want and just like that you can have a lot of props so now if we play our game let's run into our house you will see it's it feels much better you have a little bit of the space is filled with props and it it just feels nicer so what we're gonna do now is to work on the lights because our environment is quite dark and it's hard for you to see when you are inside the house go to add lights to our environment is super easy let's go inside first and you can just go to the plus icon go to lights and you have different lights directional light is like the sun we already have it there the Skylight we already have it but the point light and the spotlight are really useful and direct like to simulate some lights coming from the window so it's very easy to use we can just go to plus lights and grab the point light and you will see that automatically I remember my environment is lit now I can change the intensity for example like three and I can also change the light color to something like or warm warmer and then I can change the radius of this there you go you see you have different settings you can play with you can also change the temperature and put it cooler or hotter I can just leave it like this and if you don't like the pawn light I will just put it here and let's try another light let's go here to plus light and put a spotlight a spotlight may be something you want so I will rotate this and now I will put my Spotlight here and this is more accurate to the type of light you're having so if I go here I can just change the radius and change the intensity to three and then change the light color there you go now depends on what you want to do you want to have different lights in my case I feel like this Spotlight works fine if you want to lead your environment you can also press L and click and you will be able to put a spotlight in the place so I could choose alt and click and ALT and click and put all my lights but there is a better way to do it and that is by creating blueprints which are like prefabs that you can only change once and all the instances will be updated so let's do that now to create a blueprint is very easy let's go to our content drawer and inside my first project folder I will right click and here you will see a bunch of options to create different assets a blueprint class is very common so that's why it's here you can just click on it and you will have different types of blueprint actors an actor is a base class but you also have the character if you want to put a character in your game a pound a player controller and all that stuff if you want to learn more about blueprints we have a complete tutorial on blueprints for free you can watch so let's go to actor first an actor is basically any class that I can put inside my level and I will call it BP underscore my light let's open it and you will see this window here this window is the blue ring editor and it's very similar to what you have here because you have a viewport and you can preview your assets in the left you have all the components here and in the right you have the properties you have the class defaults the class settings so let's go to add a component what we and what do add it's a static mesh component so if I click on this one and then go to add static mesh and then click static mesh here I will create a static mesh but I need to select this one here and while selecting it I can just click the you selected asset from content browser and there you go now we have a light the next thing we want to add it's a spotlight now let's add the spotlight and now we will rotate this and going up just like that you can change the intensity something like 1000 Maybe you can change the attenuation radius but it will be much easier if we check it in the blueprint so now let's just delete this and let's grab our blueprint and you will see that I already have my lamp with the light so what I can do is to change the light color for example to something warmer compile and see how it looks like now this radius is too big so I can change the radius to something like maybe 300 or 250 and the intensity I can reduce it to half compile let's just reduce the radius to 200 and maybe a little bit warmer there you go so now you will see that you have your light here you can also move it a little bit to the write an app if you want to have a better result now I can just delete all of those and I can just change update this one if I want to put more I can just add another light just like that let's add some more in the left there you go a little bit more here and another one here awesome now unreal has an option for Global illumination and real Engine 5 especially it's very nice with this indirect lining so if I put something like 50 for example the light will bounce in all the roof so that's an extreme example but if you want you can put something like two or tree and everything will bounce like for example like the light it's like coming up and then it touches the roof and the roof with this normal angle will bounce the light and the next time the light touches something it will be dimmer and dimmer until you lose the light intensity the indirect lining is exactly that you will increase how much intensity this bounce lining have let's try our game to see how it looks like now my starting point I don't like it to be that far so maybe we can change it and now we have some lights here which is pretty cool let's see what else we can add to our game what I want to do now is to make the player to press a button and then open the door so let's close the door first let me rotate this and put it on zero degrees or you can just press zero here and you will have it on the default settings so let's use the level blueprint what is a level blueprint it's any kind of scripting that you want to use in your level how can you open it you can go here and open level blueprint and just like that you are using the level group it what you want to do first is get a reference of our door here so I can just go here right click and then create a reference the next thing you want to do is to basically change the rotation so let's try it out the way to do this is you can do the set actor relative location Third rotation and you can see that it already selects the door that I have so I don't really need to click on it the reason is I already click on this one in the level and let's just put -70. now I want a way to activate it so I will put e f and just to try it out let's see what happens let's play the game let's just run and press f and the door opens well it opens really harsh so we're gonna smooth this out by using a timeline so let's go to the level and let's go to timeline and create a timeline let's call it rotation or this type you don't really need to put an end here double click on this and you will see this do not panic it's very easy to use the first thing is we need to track a value so let's track here let's drag a float which is any kind of number that use decimal values so we will call it rotation Alpha you will see that I have a curve editor here so I can use right click add a key and right click here and add a key the first key I'm gonna select and I'm gonna put the time to zero and a value of zero and the next one is going to be a time of one and a value of 1. if you press F you will focus on the selection the next thing I want to do is to change the length to one so that all my animation goes from 0 to 1. and if I want I can just select all of those and maybe just change the curve type so maybe put outer just like that I will have a smooth animation let's go back here to our level go to the event graph and when we press f we will play this and then we need the rotation album so what we need to do is alert so we can put a layer rotator and the initial value will be zero and the last value will be -70. and the alpha will be here and we will learn between these two values during this time so let's go back here and put the rotation value here always connect the same color the next thing I I'm gonna do is to connect the white node here the white cable here because the white one is the main flow of the execution of this code so what we're doing is pressing f the timeline will happen it will learn between these two values and it will assign a new rotation to our door well let's try it out let's right click and play from here now we press f and nothing happens let's see why oh we press and we didn't connect it here and as you can see if I press Ctrl C I cannot connect these two at the same time and the reason is a sequential a way of programming is step one step two step three it cannot be like the step one and two at the same time because that code doesn't know which one to play first so what we're going to do is to put the Press on play and then the update here and now let's compile and play again press f and now our door opens that's great now what I need to do it's a way to only press F when I'm close because when I'm far and I press F I can open the door from here and it's not really what I want so let's go back to our level blueprint and let's create a variable here let's click Plus and name it pan Open Door and the player open the door so in order to do that we need a trigger so we're going to the green plus icon go to volumes and look for a trigger volume let's go here and let's use put it just like this there you go you can scale this up if you want unless you say this is enough or maybe make it a little bit smaller just so that you can only open the door here there you go something like that so while selecting my trigger I can go back to my level blueprint I can right click and then add event position and and I will add an actor begin overlap if my actor is in the trigger volume I will grab this thing this Boolean and I will set this to true you can open the door let's create another event if I add the Collision on end overlap you cannot longer open the door so I can drag this variable press set and just like that I can change the Boolean the Boolean is use a variable that allows you to have a value either 0 or 1 or true or false so just like that I need to press F and I have a condition here is very easy I can press tab to select the actions for this blueprint and I can type branch I can connect this one and if it's true we're gonna play this so we're gonna interact the variable and we're gonna connect it here if the player can open the door then play the animation let's play and try it out now we are far pressing F I cannot open it I'm close press F and I can open the door and I can enter which is great before we wrap up this tutorial I want to show you a super cool feature that you will love let's find a sunlight and the sunlight in our real engine is called the directional light I will type in the outliner directional and you will choose the directional light here you can change the light shaft for collusion so I can click here and as soon as you do that you will see that you have a collision in the distance and also you have the bloom if you want to rotate the sunlight you can use the rotation values here or either click on your sunlight here which is this one and just rotate around but there is a better way to do it you can use Ctrl l and move it and as you can see now my sunlight has some kind of gluttering so what you can do now is use the window we have and try to position the light by pressing Ctrl l and just like that you can just create like a nice little sunlight that comes from the window let's save it and let's try to play your game so we go here we open the door with f and now we have a sun a god Ray coming from here and you can change the settings but this is a really cool feature I really want to show you because a lot of people love it myself I love it the first time I saw it and I feel like you will also feel the same thank you so much for watching we have go through a lot here we have go through how to download the engine how to launch it how to place objects how to move around how to model something like a little house how to use blueprints to make a door open how to use blueprints to create prefab so we can decorate things faster and also the prefabs for our objects this should give you a great idea of how to get started we have a lot of tutorials available for you if you want to dig deeper like modeling environment art blueprints pfx make sure to check them out I'm Mal and I will see you in the next one bye thank you
Info
Channel: UNF Games
Views: 132,265
Rating: undefined out of 5
Keywords: unfgames, unreal engine beginner tutorial, unreal engine 5 tutorial
Id: LeY6tAP-qss
Channel Id: undefined
Length: 65min 38sec (3938 seconds)
Published: Thu May 11 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.