Create Massive World Landscape Auto Material - Unreal Engine 5 Complete Tutorial

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
foreign open worlds is a very hard task but in this video I'm going to teach you how to create a landscape Auto material just like this one from scratch if you stay with me for the next almost three hours I'll feed your brain with enough knowledge to create the landscape Auto material of your dreams this material will handle everything automatically placing the textures based on landscape height spawning pathologies and other 3D objects based on the textures and the area that you've set up this material will speed up your workflow by a lot once you've mastered you can create different landscape variations like deserts Rocky Mountains Islands forests and much more just plug your material in your landscape material slot and everything will start working of course everything in this material is tweakable and you can almost do anything with it you can tweak the water you can break the snow and each layer of this material is completely tweakable and adjustable if you are too busy to watch the whole video I have created a membership program in my YouTube channel where I'll upload all my Unreal Engine 5 files shaders and things that I've created all the members will have access to download them and use them in any of their projects the membership will cost 299 USD which is what like a cup of coffee so if you're willing to give up one cup of coffee click the join button and get your hands on everything that I'll be creating the join button is placed on my main YouTube page and before we start creating the Shader I want to let you know that I've created few unreal ng5 courses and if you find any of the topic interesting to you you can go into the description below and check them out and finally if you want one month of skillshare Premium subscription you can find the link in the description alright so the first step is we need to create a lot of different functions in order for us to use the material function in our Auto material so I've just created a folder Auto material function and I'm going to right click go to material and I'm going to click here material function I'm going to name it with MF for material function and the first one will be my opacity all right so this is my opacity mask for my apologies and the distance that I need to fade in and Fade Out so as you can see here I have apologies over here but here at the distance I don't see them and this is what our opacity mask will do so I'm gonna double click on it and let's start create our opacity mask the first thing that we need to do is we need to use a static switch so I'm gonna search for switch parameter static switch parameter this one and I'm gonna name it use solid opacity so this will Define if we're going to use solid opacity or not and what we need to do for True is I'm gonna put a parameter so I'm holding one on my keyboard and clicking left click over here and I'm gonna put the value to 1. and I'm going to connect it to True over here I'm aligning everything over here in order for me the graph to stay clean all right my solid opacity will have a group name of distance calling all right and the next thing that we need to connect to the force is function input function input this one which is a vector 3 but here from the input type I'm going to select and choose color I'm going to name this opacity all right and I'm going to use the preview as default over here all right the priority will stay zero and I'm going to connect it to false so we've created the static switch between solid opacity and not solid opacity and the next thing is we need to multiply and we need to multiply with per instance fade amount I'm going to connect this to a and I'm going to search for Bach per instance fade amount this one in the constant and what per instance fair amount will do if you hold Ctrl and out here you will have a description of it so it is a full value associated with amount of Fate applied to an instant status such as Folgers this is what we are going to use for phonages in order to fade out I'm going to connect it to B over here and I'm going to use alert so L on my keyboard lerp over here and connect it to my lerp my multiply to my alert the next thing is we need to create the camera fade range and the camera fade offset so I'm gonna right click here and search for scour parameter and the first one will be my camera fade range camera 8 range and I'm gonna put for default value 5000 over here and for the group name I'm gonna select my distance calling I'm gonna duplicate this one I'm gonna put 0 for it and this will be my camera fade offset all right and what we need to use here in order to get this camera fade is we need to use a camera depth fade block so I'm gonna search for camera beat depth all right and the first one will go to the fade lens and the second one will go to my fade offset cool I'm gonna align this a little bit and the next thing is I need to reverse sit with one minus because the default range I didn't set it up all right 5000 over here for my fade range because the default fade range is a little bit uh buggy at least in my opinion and it starts with negative values so in order to reverse it I'm going to choose one minus all right and I'm going to connect the result over here to 1 minus what I need to do over here in order to get it is another multiply and connect this one to a connect this one to B okay and we need to use a ditter temporal AA so I'm gonna right click editor temporal a and I'm going to connect to my Alpha threshold over here and in my verb section I'm gonna connect it to B and the alpha will get from the camera depth fate all right over here and I'm gonna clean it up like that and the final thing that we need to do over here is we need to use a depth page switch so I'm going to duplicate this switch in order for us to turn it on and off I'm gonna connect it to true and the next thing that we need to connect to foes will be the multiplier over here all right and I want to clean it up a little bit over here so it will be more readable and I'm gonna connect to the output results and my output result will have the name of opacity all right and switch over here we need to name it uh use depth fate page and it should be distance calling also so now we are ready with our opacity mask I'm just gonna move those blocks a little bit over here in order for me to be a little bit more clean and this is super important because this material will be complex and you should always clean up your blocks in order to read them perfectly so I'm Gonna Save and we're gonna continue on with the next block the next one that we are going to create is depth fate and this will be for my distance blend fade offset and distance blend fade length so I'm going to right click go to material material function MF depth page all right I'm gonna double click on it I'm gonna expand it and let's start the first thing that we need to have is camera depth fate and this block is already created in Unreal Engine so I'm gonna search for it camera depth fate and we need to connect fade land fade offset or vertex Shader that's it and we need to connect it to the component mask so I'm going to right click and search for component mask and in this mask you can enable and disable channels from rgba which is red green blue and Alpha and in this particular case I'm gonna enable only the red Channel I'm gonna connect it to the mask and my mask will go to my output and I'm going to name my output depth bait mask and this will be the mask for my Dev paid and we need two scour parameters let's cover parameter and the first one will be distance blend paid lens all right you have a value of 4 96 and I'm gonna group it under uv's group this will be my group UVs all right and I'm gonna duplicate this parameter and I'm going to change the name to distance blend fade offset and this offset will have 512 or the default value and it will hold again the group UV and the final thing that we need is a static boom so I'm gonna search for static boom I'm going to connect it to my for vertex Shader connect those two over here and the default value will be true all right I'm arranging everything to look good let me cue this and this is pretty much my depth fate function all right I'm Gonna Save it and the one thing that you need to check here is exposed Library click save and you need to do that for MF opacity I'm going to click expose to library too I'm Gonna Save it and I'm gonna close it the next material function that we need to create is our pivot mask so I'm going to right click I'm gonna go to material material function MF pivot mask all right and this will be a pretty easy one first I'm gonna expose the library over here click it and then my output result will be my Pivot mask build mask the first block that I'm going to use is World position World position over here and I'm gonna use the absolute World position including material Shader offsets the second thing that I'm gonna need is object pivot point so I'm going to search for object build point this one object pivot point and we have the object Pivot Point location and mesh particle Pivot Point location we are going to use this for uh Pivot Point location of the meshes I'm going to right click here and I'm going to search for distance distance all the way down and it will be under utility over here the distance and I'm going to connect my absolute Warrior position to a and my object period point to B over here I'm going to align those two and I'm gonna divide everything here I'm going to connect this to a and I'm going to divide it to a parameter by 64. I'm gonna add one parameter holding one on my keyboard and I'm gonna put 64. I'm gonna connect it to B move it a little bit like that and connect to my output pivot mask and our pivot mask is ready I'm gonna save it and we've created one more material function the next function that we need to create is our pixel depth editor so I'm gonna right click material material function MF pixel depth editor all right and let's start creating our pixel Dev editor all right the first thing that I need to add is our detail temporal a so I'm going to search for it editor temporal AAA all right and I'm gonna use a multiply node connected to a over here let me just align them and the second thing is I will need a scour parameter and this parameter will take the name of pixel Dev ditter click so pixel depth editor all right and it will have a value of 5 for the defaults and the depth editor will help us blend between textures so I'm gonna name this group to World blend World blend all right and I'm going to connect this to B the next thing that we need to do is I'm going to move this a little bit like that and I'm gonna move my multiply over here and we need to use alert node so I'm going to use alert note and I'm going to connect this multiply to B so our editor temporal a will go to B and we're going to create a camera depth fate camera depth fate and I'm going to duplicate this pixel Dev dither connected to my fade lens over here and I'm gonna name it pixeldeb Dieter near fade so I'm gonna add near page all right this will be for my near fading I'm going to shift a in order to arrange those two and I'm gonna put for my default value 256 over here all right pretty cool and this will go to my Alpha Channel let me just arrange these two arrange those two and right now we are missing something in our Loop which is in a and I'm gonna add a value of zero connected to a so this will be my default value for my lurp in a and I'm gonna use a switch parameter so I'm going to search for switch parameter which is this one static switch parameter all right uh I'm gonna put a name for it use pixel Dev editor use pixel depth editor so by using this parameter we can turn it off or turn it on I'm gonna connect this to false so this will be when it's false and I'm gonna connect my lurp to true so when it's true it's going to use the lurp when it's false it's going to use the zero and by default I'm gonna enable it to be true and I'm gonna connect it to my output result which will be my pixel depth editor all right and I'm just gonna clean up this mess a little bit I highly suggest you do the same let me move this one over here something like this I'm gonna align those two or maybe not I'm gonna keep them like that and I'm gonna move this one over here yeah it's a little bit messy over here but at least it is uh readable just like that all right it's it looks good so I have my pixel depth later and I need to expose this to library over here and finally I need to group this to the world blend over here and we're pretty much done with our pixel adapter I'm gonna save it and I'm just gonna align this one just like that all right so look a little bit better I'm Gonna Save it again and let's continue on with the next function and the next material function that we're going to create is our slope mask the mask that will create the slopes over here so I'm going to right click material go to material function MF swap mask I'm gonna maximize and let's start creating the function the first thing that we need to do is expose it to the library over here and I'm going to rename this one to slope mask oh here all right and the first block that we need to add is our pixel normal so I'm gonna right click pixel normal WS this is the coordinates that we need to input and I'm gonna right click and search for slope mask this is already created in unreal for us and we're gonna hook up our pixel normals to my tangent normals V3 over here I'm gonna align it and I'm going to need to create a scour parameter so I'm going to right click function input this one and I'm gonna name this slope power all right this will be a scour function all right over here and I'm going to connect it to my four wolf power so this will control the power of the fall off and my cheap contrast will be one so I'm holding one on my keyboard clicking over here putting one as a value and connect it over here for my cheap contrast all right the next thing that we need to do is we need to add one more slope mask so I'm gonna duplicate this one in order to control a little bit more of the fall off power I'm going to multiply over here connect my input over here and use for B6 and connect it to the fall of bar over here to the fold of power we're gonna align those two I'm gonna duplicate this value one more time and this time I'm gonna use two for my value I'm going to connect to my cheap contrast and both of the slope masks I'm gonna add them to my Adblock so I'm going to add this one to a and I'm going to add this one to B all right and I'm going to clamp the first one so I'm going to search for clamp and the first one will be will be clamped the second one won't be clamped so let me just align everything here and the first one will be connected over here my minimum will be zero and my maximum will be one and the second slope mask I need it to create for my normal Maps so I'm going to duplicate this output over here I'm going to connect it over here and I'm gonna use it for my normal Maps let me just align those two let me align this again and I'm going to give this name slope normal mask so this will work on my normal maps and the next thing that I need to do is here is set priority zero so this will be my first parameter and this will be my second as I've put one so I'm Gonna Save right now and our material functions for the slope mask is ready for the next material function as we want to have some water on our terrain we're gonna create a water mask so I'm going to right click go to material material function and map water mask all right and the first thing that we are going to do is expose it to the library I'm going to select this and call it water mask all right and this is a little bit more complicated but stay with me I'm gonna search for World position this one and I need to mask from here B channel so I'm going to right click and I'm gonna search for component mask and I'm gonna mask only the B Channel I'm gonna connect it over here Q to align them the next thing is we need the water Max World position and we need to add both both the mask B Channel and the water Max World position so I'm gonna search for scour parameter and I'm gonna rename this to water Max world or Vision all right and I'm Gonna Leave the default value of zero and for the group I'm gonna name it one underscore water all right everything here will be zero and this will be my group one underscore water and right now from here I'm gonna use one minus in order to reverse this I'm gonna queue and as I said we're gonna add this to a and this to be all right the next thing that we need to have is Water World position power and I'm gonna duplicate this one and discover parameter and I'm gonna rename this to Water World oxygen power this will be the parameter for our water world position power and here for the default value I'm gonna put zero point three zeros one all right and I'm gonna duplicate the ad block over here connect the word position power to a and leave the B to 1 all right so we can play with it and both of them we're gonna be multiplying them so I'm gonna multiply to a and to B and I'm gonna reverse it one more time so I'm gonna duplicate this reverse it and I'm gonna clamp it run all right I'm gonna clamp over here so we're gonna have our Min and Max to one this is the first step of creating the max World position and the Water World position power then we need to create the water slope power and the water edge contrast so I'm gonna duplicate this one and I'm gonna name it water slope power this will indicate our slope water power and for the default value I'm gonna put one five three six and it's gonna hold again this group and the next thing that we need to add is I'm going to duplicate this one and it will be water edge contrast Water Edge contrast so this will be the contrast of our edges and what I need to have is a slope mask slope mask so we can Define the slopes of this water and I'm gonna connect the water slope power to my fall off power over here and the water edge contrast I'm gonna multiply I'm going to connect to a let me just cue this up and cue this one and I'm going to connect my multiply to cheap contrast and the next thing that I need to have is a functional input which will be a scour so right click function input and this one I'm gonna name it mask and I'm gonna choose a scour parameter and connect it to B over here all right so right now we have our slopes over here we have everything here under until the clamp and now we're gonna multiply both I'm gonna hook up the clamp over here and I'm gonna hook up the slope mask result over there all right and the final thing that we need to have is snow vertex mask which will indicate the snow because we won't have snow also so I'm gonna multiply again this water over here mask and I'm gonna create I'm gonna duplicate this masks color put it over here and reverse it so I'm gonna duplicate this one minus connect this one here and connect this one to my B Channel snow vertex mask okay and everything is Multiplied over here and I'm just gonna power it up with four with exposure a little bit so I'm gonna search for Power I'm gonna connect it to my base and I'm gonna put exposure 4 and connect it to my output water mask so right now we have created the mask for our water so right now I'm just gonna save it and continue on with the next function the next material function that we are going to create is our roughness which will be applied to our terrain and we can use it inverted or reversed so I'm gonna right click material material function so I'm gonna name it MF or roughness and the first thing is exposed to library all right and I'm going to rename the output to roughness all right and the first thing is we need a function input function input and I'm going to name it roughness and it will be a scour one scour and now we have a switch parameter to true and false to invert it and reverse it so what I'm going to do is I'm going to search for one minus and I'm going to connect once here and I'm gonna search for static switch parameter this one and I'm gonna name it use inverted roughness all right by default it will be true and I'm gonna connect the true over here and the false will go over here and this is how we can invert it or not invert it and I'm gonna multiply it over here and multiply node and I'm going to create two parameters which will Define my roughness multiplier and my roughness power so I'm gonna right click and I'm gonna search for scour parameter and the first one will be roughness rough nice multiply multiplier all right and the roughness multiplier will work with the lightning so I'm gonna put the default value of one and I'm gonna group it under lightning lighting all right and I'm going to connect it to my Bo here and I'm gonna create a power function power I'm going to connect my multiply to the base and I'm gonna duplicate this parameter over here and I'm gonna put here 0.5 and I'm gonna name it power roughness roughness power all right and this also will use the group lighting and I'm gonna connect it to my exposure over here all right and finally I'm gonna connect the power to my roughness output and this is how we are going to control the roughness onto our terrain we're gonna have the power we're gonna have the multiplier we're gonna have the input roughness cover and the inverted switch parameter now I'm gonna hit save and let's continue on with the next function so the next two material function that we are going to create they will be all about snow so the first one will be the snow and the second one will be the snow mask so I'm gonna right click over here material material function MF or material function snow and the first thing that you need to do expose the library over here I'm gonna name my output result to the base color so this will be my base cover of the snow and then I'm gonna create two Vector 3 function inputs and one scour I'm gonna search for function input and the first one will be my base color right I'm gonna duplicate this one and the second one will be my snow base cover no base color all right and finally the third one will be my snow pixel mask and it will be a scour one so I'm gonna choose scour and I'm gonna name it snow pixel plus over here and what you need to do right now is set the priority so this will be zero this will be one and this will be two so they will pop out in my master material uh this will be my first this will be my second and this will be my third and now what we need to do is we need to create a little logic and I'm gonna use for snail so I'm going to right click press now press now over here and for the exponent in I'm going to use 5 and for the base reflection I'm going to use 0. I'm going to select everything shift a to align them and now I'm gonna start multiplying adding and lurping I'm going to multiply first I'm going to connect my first nail to B to the multiply node and I'm gonna connect my snow base cover over here to the multiply node over there and the next thing is I'm gonna add holding a on my keyboard I'm going to add the base color over here to a and the multiplication of the base cover and press now we'll go here all right I'm gonna move them like that I'm gonna arrange everything to look good and the next thing that we need to do is we need to use alert so I'm going to use alert and I'm going to connect the edits to to my b and I'm gonna use my image based color to my a over here move it like that and what we left here is my snow pixel mask and I'm gonna connect it to my Alpha over here because this will be my mask I'm gonna double click in order for me to clean it up move it like that all right and finally what we need to do is we need to use a switch parameter to turn it off and on if we want to use no or not so I'm going to search for switch parameter static switch parameter this one and I'm gonna name it use node simple as that and by default I'm gonna turn it on like that and I'm gonna connect my blurb to true so when it's true it's going to use my base note and my pixel mask and when it's false it's going to use just my base cover so I'm going to connect the fossil here and I'm gonna clean it up like that so you can see pretty much good connections over here and finally I'm going to connect it to my output base cover over here let me just move it up and connect it and finally we need to add this parameter to a group so I'm going to name it zero underscore snow and I'm Gonna Save everything so this will be my snow all right let's continue on with the next function in the snow mask so let's create the snow mask I'm going to right click material material function MF no mask all right and this will be a little bit more complicated with a lot of connections but anyway let's start I'm gonna click here expose to library and let's start with the first block we're gonna need the absolute World position so I'm gonna search for World position and I'm going to use the absolute Warrior position I'm going to mask it to be so I'm going to right click component mask and I'm gonna mask it to be which is my blue Channel over here I'm gonna align it and I'm gonna create a scour parameter which will be my snow World position where I can Define the position of the snow right click scour meter and I'm gonna name it snow World position all right and the default value will be minus uh 1500 all right and this will go under my group of zero underscore zero underscore snow all right this will be the group for my snow and after that that I mask here and I used this uh scour parameter I'm gonna reverse it so 1 minus and I'm going to connect this over here Q in order to align it and I'm gonna add those two I'm gonna add them all right the next step is we need the world position power of the snow so I'm going to duplicate this one and I'm gonna name it snow World position power so we can Define the power of the word position and for the default value 0.0001 this will be my default value again it will be under the group of snow and I'm gonna create a mask for it so I'm gonna need a function input over here and I'm gonna name it mask all right and this will be a scar parameter scour all right and I'm just gonna add those two shift a to align them hold a on my keyboard to create the alt block connect it to a connected to B all right and then we're gonna multiply those two multiply here and here I'm gonna move it to look pretty and finally I'm gonna clamp everything so I'm gonna right click clamp over here I'm going to connect the clamp and I'm gonna use 0 1 for my clamp all right so we've created the first step of this all right I'm gonna move it because this one will be big the second thing that we need to create is vertex normal vs so I'm going to search for vertex vertex normal vs and the next thing that we need to do is our pixel normal vs pixel normal yes all right I'm gonna align them to and we need to mask again the B channel so I'm gonna use component mask and I'm gonna mask just the B Channel over here and I'm gonna duplicate this one and connect those two over here I'm going to use Q to align them I'm going to move them a little bit down and what we need are is snow mask multiplier and snow mask power all right so I'm going to use the multiplier to here M multiply and again multiply nodes and I'm going to connect to a and here I'm going to connect again to a and I need to create another parameter which will be my snow moves mask multiplier so I'm just gonna duplicate this one the snow World position all right and I'm gonna rename it to snow mask multiplier okay and I'm gonna put for the default value 1.4 I'm gonna connect my multiplier to B channel of each multiply node over here all right and the next one will be my mask power so I'm gonna need a power block I'm going to right click power all right and we're going to connect it to the base over here and connect it here over to the base again all right and what we need is another scour parameter this one and I'm gonna name it snow mask power and this will be the power of my mask and for the default value I'm going to put 10 again the group will be 0 underscore snow and I'm gonna connect it to the exposure here at the B I'm gonna move everything a little bit like that so it can look better and finally what we need to do is we need to add a slope mask to each of the vertex normals and the pixel normals so I'm gonna add two blocks over here which will be my ad blocks let me just arrange them like that and connect it to a over here and I need to create a snow slope Tower which will use the slope mask I'm going to move this a little bit down right click slope mask and this slope mask will use a slope power so I'm going to duplicate this parameter name it snow flow power and I'm gonna connect the first one to the fall off power and it will be three and the second one will be just a value so I'm holding one on my keyboards and connecting to my cheap contrast and this will use a value of 2. of course my slow power will be under the group of zero underscore snow and as I told you before we need to add this to the add node of each of the pixel normal input and vertex normal so I'm gonna add the slow power here at B and I'm gonna add it over here at B and like this one like the absolute we need to clamp it so I'm gonna duplicate two more clamps over here I'm gonna move them like that and I'm gonna Clump it this is just because we need to get the range correct and the range is from zero to one all right I'm arranging everything to look pretty clean and finally what we need to do is we need to connect and multiply those clamps and clamp again so I'm gonna add multiply note over here with I'm on my keyboard I'm going to connect the first clamp to a I'm going to connect my second clamp to B over here I'm gonna duplicate and do the same for the second one my second clap will go here at a and this one will go at B and as I said we need to clamp again and get different output results so I'm going to duplicate two times this clamp connect over here I'm gonna align it like that Q I'm gonna align this like that queue and I have a little bit ugly connections over here so I'm gonna make them look like that to be more clean and the first result will hold my snow vertex mask so vertex mask and the second one will be my snow pixel mask so I'm gonna connect this one to this one so this will be my vertex mask and I'm going to duplicate this output connect over here and this will be my snow pixel mask so we are creating the snow masks in the pixel and the vertex mask and finally what we need to do is we need to set up the priority so this will be zero and this one will be one and we are pretty much done with the snow masks I'm just gonna save it and here you can see how we are masking a little bit on that sphere the black will not have snow and this will have snow and if you start tweaking those parameters you're gonna have a different results but we're gonna tweak them in our Master material so just save this and let's continue on with the next material function let's continue on and create one that will be combining our normal with a simple function so I'm gonna right click material material function MF combine normals or normal simple all right and this will be a pretty easy one we're gonna have a normal a a normal B and we're gonna combine them so I'm going to right click and I'm gonna search for function input then the first one will be normal a all right I'm gonna duplicate and my second one will be the normal B and I'm going to set the priority so this will be zero and this will be one in my master material that should be showing like this and I'm going to split the component to RG and B and we're gonna append them so I'm going to right click split component under miss this one I'm gonna split our normal channels we're gonna duplicate and I'm gonna split the second one all right we're gonna move them a little bit down and I'm gonna use add parameters multiply and append so I'm gonna use them like that I'm going to use one add to my our Channel over here let me connect it and I'm gonna use a second ad over here for my green channels so I'm just combining my R channel of the first one to the r channel of the second one pretty easy pretty straightforward my green will go here my green will go here and I'm gonna need one more for my blue Channel I'm gonna move this like that blue Channel over here and blue Channel over there let me just move it down like that I'm gonna crisscross them a little bit let's try shift a all right so we have our ad and now we need to append we're gonna append the r and the G and RG will be appendic with the blue Channel I'm gonna right click and search for append Vector this one append vector and I'm gonna append my R in my G all right of the two textures and those will be appending with my blue Channel over here all right and what we need to do is expose the library and connect to my final result over here and this is pretty much our combined normal the simple method I'm Gonna Save it and let's create one more combined normal function I'm gonna close this one and I'm gonna create a combine normal which will not be simple so I'm gonna right click and I'm gonna search material material function MF combine normal and let's create the graph the first thing is I need a constant tree Vector so constant three Vector this one and I need to get the blue Channel working so I'm gonna put one on my blue Channel and I'm gonna Loop it with a base normal Vector tree so I'm gonna search for function input and this will be Vector 3 and I'm gonna name it base normal this will be the base of my normal and for the set priority I'll leave it to zero the next one will be a scour parameter which will Define my base normal intensity so I'm going to duplicate this one and this will be my base normal intensity and this will be a scour parameter and I'm gonna click use preview over here and for the set priority and put two all right I'm putting two and here for the preview I'll add a value of one so I'm holding one on my keyboard and I'm adding a value of one just to have some preview over here I'm going to duplicate this one I'm gonna duplicate the value again and connect the fellow and the second one will be my at normal intensity so this will be my ads normal intensity the intensity that I want to add to my normal and right now the next step is to blurb them I'm going to use derp and I'm gonna connect this one to my a and my input base normal to my b and my input based normal intensity to the alpha here right this will be my first Loop okay and I'm gonna duplicate this one let me just move it like that and I'm gonna create a second LARP which will have for my Alpha at normal intensity all right and I'm gonna connect this one to my a and I'm going to connect this one to my Alpha let me just align them and for my B I need a different abnormal Vector 3 so I'm going to duplicate this input base normal duplicate it and I'm gonna connect it to my B over here and I'm gonna name it alt normal and for the priority I'm gonna set one and since this is a duplicate of my base normal the priority will be two but I'm gonna change this to three and just like before in our normal simple we will need to split the components and add them multiply them and append them all right so let's do this here for the output I'm going to name it to normal so this will be my normal so let's start splitting the components and adding them right click click the components connect it over here we're going to duplicate it connect this over here and let's start add and append them just like before I'm gonna add my R here to my a and my R here to maybe so we have added the red Channel I'm gonna add my green Channel over here to the second one so green channel here green Channel over there and finally I'm gonna append those two right click append which will be a pen Vector I'm going to connect it over here like that I'm going to connect it here over there to B and now what I need to do for my blue channel is I want to multiply and append them so I'm going to multiply over here and I'm going to connect my blue over here to a and my blue over here to be just like that and now I'm going to append those two append the first one the RG and append the second one which is my blue Channel let me just clean this up a little bit like that oops I accidentally hit here add so what I need to have is a pants not that so I'm going to connect it and I'm going to connect it and finally we need to combine this over here to my output normal alright so we are pretty much done with our combine normal and I'm Gonna Save up here our graph looks good and let's continue on with the next function so the next function will be our water and our water will be a little bit complex so let's just start and not waste any time right click material material function MF water and the first thing that we're gonna start with is our base color of the water so I'm gonna go over here so the first thing is a vector tree so I'm gonna search for function input Vector 3 and this will be my base color of the water and the next is we need a constant for Vector parameter so I'm going to search for constant for Vector this one and this can give us the default values of RG and B and we can select the different color and the one thing that I'm going to do is I'm going to convert it to parameter so I'm going to right click and convert to parameter over here I'm gonna name it water cover so this will be the color of our water so here from the group I'm just gonna put one underscore water so this will be our one water and here for the cover you can define something that you want for your water all right this will Define my watercolor all right and what we need to do here is we need to learn them so I'm gonna hit L on my keyboard and I'm gonna connect my input base color to a and my water cover rgnb to B all right the next is we need to switch parameter to turn it off or on the water of course let me just move it like that and I'm gonna search for switch parameter static switch parameter and I'm gonna name it use water this will be the parameter in order for us to turn it on or off the water so I'm gonna connect to true if you want to have this cover for water and I'm going to connect it to false if we don't want it all right the default value will be true and I'm gonna duplicate this one and I'm gonna name it base color base color this will be the base color of my water I'm going to connect those here and for my switch parameter I'm gonna select the water group but we are missing our Alpha and we need to create a water mask so I'm gonna duplicate this one and I'm gonna name it water mask and I'm gonna put the priority of my water mask before over here and I'm Gonna Change it to a scour parameter all right and what we need to do is we need to clamp it to connect it to my Alpha so I'm gonna search for clamp I'm gonna connect it over here and I'm gonna clamp it to 0.9 and this is because I want it not to be going all the way up to one all right so this is my first thing my base cover we're gonna create a lot more the second thing that we want to create is the metallic so what I'm going to create is another switch parameter but this time I'm gonna duplicate this one and I'm gonna name it metallic all right I'm gonna connect the parameter over here and what I'm going to have is a multiply and I'm going to multiply the mask connect the mask connect it to my true and if the metallicness is false this is true by default I'm gonna use zero so I'm holding one on my keyboards connected to my phone not over here so if it's false we're gonna have zero metalness if we want we can have multiplication with the mask scope here and I'm gonna put for B 0.54 here 0.5 and finally our use water should be in group 1 underscore water so now we have our metallic and our base cover and the next thing that we need to have is our specular so I'm going to duplicate this and I'm gonna name it specular spec Ur all right and we need to have input for our specular and again we need a switch parameter to turn it off and on so I'm going to duplicate this one again and I want to clamp the specular the specular range is from 0 to 1 so I'm gonna clamp it over here from zero to one from the start all right let me just connect it to my output specular I need to align them here on my keyboard and right now let's create the logic I'm gonna need the first now which will represent my specular and I'm gonna select my exponents in will be 133 and for the base reflection will be 0.5 let me just move this a little bit like that and try to clean it up a little bit because it was really easy starts to get messy all right so my first nail will be 1.3 and the base reflection will be 0.5 I'm going to multiply this and I'm gonna use the mask over here it's connected to B and it is getting a little bit messy so I'm gonna do it like that maybe a little bit down all right and we need uh input for our specular so I'm gonna duplicate this Vector too and I'm gonna make its cover go here select color select for the priority one because I want it to be higher in the hierarchy and let's connect to another ad so I'm gonna move this a little bit back and so I'm going to create an add note over here add over here be over here and I'm gonna connect the force over here so when it when we don't use the speaker it will be this scour parameter and what I need to do is rename it specular so it will use the speaker over here but if we turn it on it will use also the mask so I'm going to connect it to True over here and me you everything and right now we've connected our specular keep in mind to have this in a group one underscore water and now we have our cover we have our metallic and our specular align them and the next thing is roughness so let me create the roughness shift a roughness roughness all right and what I'm missing is the priority of I forgot the priority so this is zero this is one this is two and this is three all right let's go and create the roughness it will be pretty much the same as the previous one use water over here connect it to my output roughness let me align them I'm just moving them a little bit down and we need an input scour I'm gonna name it roughness I'm gonna change the priority to over here and what I'm going to do is I'm going to use a multiply node connect my a over here and I'm going to connect my multiply to true and if I want my roughness to be false I'm going to connect it directly to my rottens so I'm going to move it like that and this I'm going to clean it like maybe like that okay but now we are missing B and what we have in B we need to have power in order to boost our roughness and we need to reverse this mask so I'm gonna drag and drop here one minus to reverse it and we're gonna use a power node power okay and connect my power node to B and put for exposure 4. now we've created our roughness alright and it is getting pretty complex right now all right I'm gonna clean up a little bit here let me just clean up and now we are going to get deeper with the normal map all right so for the normal map I'm gonna use the world coordinates which will be a vector two so I'm going to duplicate this color parameter and I'm gonna use Vector two because uh it is a flat we're using textures so that is why it is Vector two we have only X and Y or u and v in this case this will be my my portal coordinates all right and I'm gonna set the priority for the next thing that we need is water UV size so we are working with the UVS as I told you we are working in two-dimensional space so I'm going to use scour parameter and I'm gonna name it water UV size all right and for the size of the UVS I'm gonna set 12 for my default and I'm gonna add the group in water so we can control it and what we need to do is we need to divide our work coordinates to our water UV size so I'm gonna use a divide note D on my keyboard connect a connect B now the next thing is we need to use spanners and textures so the first thing is I'm gonna multiply over here connect here right click panel this is for my coordinates and I'm gonna connect it to my coordinates you have time and speed this will move the water on the surface so I'm gonna put 0.01 for my y value and for my multiply I'm gonna put three and I'm going to duplicate one more panel so I'm gonna move also here to X and Y so I'm going to move here on x let's say 0.01 and the next step is we need a texture object all right so I'm gonna right click texture object and this will be the normal map of my water so what I have here is I'm gonna select the sample type to normal and I have in my project a normal map texture which is a water normal map which is this one just a normal map of water and I'm gonna drag and drop it over here to my texture so right now I have my normal map texture object and what I have here is I need to create two texture samples and connect it to to my panel so I can move them I'm going to right click texture sample this will be my first one so I'm going to connect the Ubisoft here so they can move I'm gonna duplicate I'm gonna connect here again the UVS and for the texture I'm just gonna use this texture and remember the function that we've created the combine normal sample right now we're gonna use it so I'm gonna minimize here go to my functions and search for combine normal simple this one and now the functions will start working I'm going to drag and drop here and we're combining those two textures we've created this function in order for us to have the ability to combine so I'm going to combine this to be and this to a and the next thing is we need to multiply this with World normal intensity so I'm gonna write like over here multiply all right and I'm gonna need to have again a vector 4 so I'm gonna go all the way here duplicate this vector 4. move it all the way down because we need normal intensity I'm gonna move it like that over here and I'm gonna name it water normal CT all right and for the color I'm going to use 0.05 0.0511 so this will give the blue color of the normal map and I'm going to connect it to be over here and now the multiply node will need to be lurping with our mask all right so I'm gonna blurb here and I'm gonna connect this to B over here all right and for the alpha we need another logic coming from the mask so I'm gonna zoom out I'm going to zoom to the input mask and what we need to have is another multiplication so I'm gonna select multiply not over here I'm going to multiply this mask over here let me just move it like that maybe move it like that and I'm gonna bring this up like this so it can be a little bit more clean and I'm gonna multiply by 1.2 and I'm going to give it a little bit of power a little bit of exposure of two and I'm gonna clamp everything in the range of 0 and 1 because I don't want to go beyond this range in this thing we'll go into my Alpha over here right move it like that clean it up and for my a I need to create another function input which will hold my normal so let me just duplicate this world coordinates duplicate them move them like that and this will be Vector two and I'm gonna name it normal all right this is Vector 2 and this one the word coordinates should also be Vector through I just forget this that this should be Vector two I just didn't change it and this should hold short priority three and let me connect it to a here let me just move it like that so it can be a little bit cleaner it's still a little bit messy you can use reroutes but right now I'm not using three routes and the final thing is we need to create a parameter just like this one a switch one where we can switch on and off so if it's true it is on and if it's false we can get it from here me just fix that pretty quickly so if it's true we're gonna use all the logic if it's false we're going to use just the input normal okay and what we have here is we need the output result which output result will be my normal the normal is a little bit complex but it will give you a great results and it gives me a little error over here which is fold three and fourth volt 2. and this is because I set up my input normal to be Vector 2 and it should be Vector 3. just like that and we fix that error so a little mistake I made over here it should be Vector 3 because we have rgnb all right and here we have Vector 2 because we are just moving the coordinates of the UVS of the texture all right so this is the difference and the final thing that we want to create is a little reflection of our water so what we can do here is from my multiply I can mask the RG uh component mask which will be RNG all right and from here let me just move this like that all right and from here we can multiply with water reflection intensity and make a little bit of reflection so I can multiply over here m on my keyboard connected over here and we need parameter like this a scour one under the group water and I'm gonna name it water refraction in 10 GT all right this will be my water refraction intensity I'm gonna put it to 0.3 and I'm going to connect it to be over here and of course what we need to do next is another multiplication with the mask node so I'm gonna duplicate this connect it to my a over here and create this use water so if it's true we're gonna use it and if it's false I'm gonna put a value of 0. over here okay and this will be my water refraction I'm going to duplicate this output I'm gonna connect it over here and name it water refraction UV all right and this will use the priority five this will use the priority power and this is priority three what we need to connect in the B is we need to connect our mask but it should be clean so I'm gonna select this one let me just zoom in this one and I want it to connect to B and right now this is looking pretty ugly so I'm gonna fix it I'm gonna reroute it over here and I'm gonna reroute again I like to have pretty clean connections this is just my style of work I strongly suggest you do the same all right and right now we have our use of water our water refractions we have our normals and I'm just gonna align my outputs over here this one over here this one over here and I'm gonna shift a all right so I can have a clean output alignment so this is pretty much my water material I'm Gonna Save right now and we have our water material ready let's move on with the next function the next material function that we're gonna create is our subsurface so I'm going to right click material material function MF sub surface all right and the first thing exposed to library my output will be my subsurface color all right let me just put interval so here subsurface cover and let's start creating it the first thing is function input and it should be Vector 3 vector 3. right and I'm gonna name it base color base color and the second thing is we need a vector four so constant Vector 4 over here I'm gonna right click and convert it to parameter and the parameter will be subsurface color so surface cover just like that subsurface cover and for the cover I'm gonna use one one one over here and I'm gonna put it in lightning well I think all right lighting this will be my lighting and I'm gonna multiply those two notes let's continue and I need a Vertex cover over here so I'm going to right click vertex power moves like that and I'm gonna multiply those two with my vertex cover okay and let me just add a subsurface color texture so I need a texture parameter 2D so parameter 2D the texture sample parameter 2D and I'm going to name it texture subsurface color texture super space Power and for my texture I'm going to minimize here let me just maximize it and in textures I've created just a texture called obedo which will be my color so I'm gonna maximize over here select this one drag and drop over here all right I'm gonna maximize it for my sample Source I'm gonna select warp over here so I want to warp it and for my group I'm gonna choose textures all right this will be my textures now I want this texture to have a little bit more exposure or a little less so I'm gonna use power and then I'm gonna desaturate it so I'm going to use power and I'm gonna put for the my power points 25 I'm gonna align them all right and I'm gonna desaturate they saturate the saturation so I make them grayscale and I'm going to use another multiply node connect to B and connect this multiply to this one and now I need a switch which will use separate subsurface texture or use subsurface color all right I'm gonna create a switch parameter which will be static switch parameter and the first one will be use separate sub surface texture all right and by default this will be false and if it's true I'm going to connect this one and if it's false I'm going to connect this one and this one will be connected to another parameter which will use the name use subsurface color use subsurface color all right I'm gonna connect it to True over here if I want to use subsurface color and I'm gonna hold one on my keyboard and 0 will be my false okay by default this will be also false in the first one will be under my textures and the second one the subsurface cover will be under my lighting alright so this is pretty much the subsurface and I'm Gonna Save it over here and let me see if I can clean up something everything looks pretty good maybe this one could align with this one but it looks pretty decent all right so let's continue on by creating the rest material functions the next function that we need to create is our landscape UVS we need to control that so I'm going to right click material function MF landscape UPS UVS all right and let's start creating our landscape UVS the first thing that we need to do is we need the world position World position and we need to mask the red and the green Channel component mask and it by default is red and green and I need to create a scour parameter which will be my landscape World UV size landscape World UV size this will be the size of my UVS so by default I'm gonna put 384 and the group will be ubis just like that all right then I need to divide the mask by this landscape UV size I'm gonna hold the on my keyboard and I'm gonna divide it like that okay so after that we need a switch parameter which parameter and I'm gonna name it use World position UVS use for position UVs and by default it will be true and connect a to True okay and now we need to create the false parameter so what we need to do is we need to have landscape coordinate so I'm gonna right click here and search for landscape landscape layer coordinates this one and I'm gonna use Auto and none you can use different mapping over here X Y but that's not something that I'm gonna talk about and I'm gonna connect it to false if it's false and we need to create a few outputs the first output will be my landscape coordinates let's coordinates all right and this will be straight connected to my landscape coordinates just like that over here so we can get them straight the next will be landscape UVS I'm going to duplicate this one let me just move it the landscape UVS because here we have got the landscape UVS and I'm gonna connect it over here I'm gonna move this a little bit down after that we need to get the world coordinates so I'm gonna duplicate this and name it World coordinates and I'm gonna connect the dividing over here when we divide we can get the world coordinates and finally we need to get the world coordinates row without the division over here and we need to get it from the mask over here so I'm gonna duplicate this and this will be my world coordinates row all right and we're gonna get it from the mask connect door here everything that we are doing over here will make sense once we've created the master material so bear with me until the end and you're gonna have a perfect world master material and now what we need to do is set priority zero one this will be my 2 and this will be my three all right and for my use World position UVS I'm gonna put it in the UV group and in the end we're gonna take expose this to the library I'm Gonna Save it and our landscape UVS are done let's continue on with the next material function alright guys so the next function material function that we want to create is how the layers will blend so I'm going to right click go to materials material function MF layer blends air Blends and this will Define how our layers will blend so the first thing is to expose the library and let's start we're going to create function input and this function input will be a vector 3 and the first input will be Rock base Color Rock base cover so this will be the base color of my rocks I'm going to duplicate this function and the next will be my Stones base color Stones base color and I'm going to set the priority to one I'm Gonna Keep duplicating this I'm going to create the mask for the stones so Stones mask and Stone's mask will hold the priority Port I'm gonna duplicate this one and and I'm going to create the grass base color grass base color and the priority will be too the next thing that we want to create is the grass mask so I'm going to duplicate this one and this will be our grass mask and the priority will be number five and we want to create two more so I'm gonna duplicate the mask and this will be our dirt base power base power all right and it will hold the priority number three and finally I'm gonna create a mask for the dirt I'm going to duplicate this dirt mask and it will hold the priority number six so let's create a little logical on all those blocks that we've created I'm gonna learn the first three so I'm gonna use l and I'm going to connect the Rogue base color to my a I'm gonna connect the stones base color to my b and my Stones mask will go to my Alpha all right then I'm going to duplicate this lerp and all those things the rock the stones and The Mask will go into a over here and into B I'm gonna plug my grass and my grass mask will go to the alpha so here B grass and the alpha will go here and finally we have the dirt which will lie underneath so I'm gonna duplicate this I'm gonna connect this lerp to a I'm gonna come connect the dirt base cover oops to B and the alpha all the way to the alpha Channel so for the result I'm just gonna duplicate I'm gonna move this result and I'm gonna name this base color and this will hold a priority of zero and I'm just going to connect the lower pole here all right so those are the base covers over here but we need to create the normal maps for it so I'm gonna duplicate this one I'm gonna use again Vector 3 and this one will be rock near normal so those will be the near normals the set priority will be eight then I'm gonna duplicate this one I'm gonna name it Stones near normal and I'm gonna set the priority to 10. the next is the normal for grass so this will be grass near normal and the priority will 12. and now let's learn those two so I'm gonna hold L on my keyboard and I'm gonna lurp the Rocks nearest normal to a and I'm gonna connect the stones near normal over here to be all right I'm gonna create another alert over here and I'm gonna connect my first slurp and I'm gonna connect my cross near normal all the way to B later on in the alphas we're going to connect the masks let's move on and create the far normal so I'm going to duplicate this one move it like that and this will be Rock Park normal and we have the set priority of nine we're gonna duplicate this one and this will be my stones for normal a little repetitive content but it's necessary the priority will be 11 and I'm gonna duplicate this slurp and I'm gonna connect those two over here A and B all right and next we want to create the grass fire normal and the dirt near normal so I'm going to duplicate this and name it grass bar normal will be Vector 3 and we'll hold the priority 13 and then I'm gonna duplicate once more and I'm gonna name it dirt near normal all right it will hold priority 14. right now I want to learn again the grass uh normal so I'm going to duplicate this I'm going to connect this layer over here to a and I'm going to connect the grass normal over here to be I'm going to move this to look a little bit clean now we need to create the snow near normal I'm going to duplicate and I'm gonna name this snow near normal we'll hold priority 16 and I will need to duplicate two more times for the dirt far normal and the snort far normal so I'm gonna duplicate this one this will be my dirt bar normal and it will be priority 15 and last one will be my snow or normal and it will hold priority 17. all right so we've created all the vectors that we need we've load up sum and now we have to create the masks for them so I'm gonna duplicate this four time to three four time and I'm gonna start with the first one and the first one will be my Stones normal mask and the priority will be 18. the second one will be grass normal mask priority 19. 19. let's do the third one will be dirt normal mask all right priority 20. and the final one will be snow over X Mask with priority of 21. and we're gonna use those masks in our blurbs and in order not to create spaghetti I'm gonna reroute them so how to reroute them just drag and drop here and search for read route and choose add named reroute the correlation note all right and for the name I'm gonna choose Stones normal mask underscore air or reroute I'm going to use R for reroutes I'm gonna do the same for all of them reroute this will be grass normal mask are the next one will be reroute this one will be I'm sorry this one will be dirt normal mask r and let's do the final one reroute this one will be snow over text mask r I'm just gonna align them shift a shift a I'm gonna cue all of them and I'm gonna use those reroutes to connect them to the lurp nodes over here so let's go back to the first warp notes and here we have Rock and Stones so we have to attach the Stone's normal mask so how to do that right click expand the name rewards and search for the stones and we have the reroute and we connect those here here we need to access the grass I'm gonna add the grass this is those reroutes are working in order not to grab this and connect it over there it is just creating an instance and it is rerouting the path and it will look a lot more cleaner let's create the reroutes for here we need Stone's normal mask and grass again so stones the next door here and here we need the grass and connect it over here let's continue on and create the next lure so I'm going to duplicate this one and I'm going to connect here a and I'm gonna connect the dirt near normal to be over here and we're gonna need the dirt mask dirt normal mask and connect it here all right the next Loop will be about the snow near normal so I'm going to duplicate this one connect it over here and connect the snow near normal to B and of course we need from the reroute the snow vertex over here pretty easy and with the reroutes everything looks very very clean all right let's move on to the dirt for normal so I'm gonna duplicate this lerp and I'm gonna need to connect this from the input of the grass which is this one this Loop I'm gonna input over here and I'm gonna move those a little bit further and we're gonna connect the dirt for our normal to B and for the alpha we need to connect the dirt normal let me connect it to the alpha and we have last one which is the snowfar normal and the snow far normal I'm going to duplicate this one connect it to a connect the snow to B move it a little bit like that and we will need the snow vertex mask over here all right so we've created the loop and now we just need to create a static switch parameter to turn on and off the snow all right right click and I'm gonna search for switch parameter which is the static switch parameter and the first one will be use snow and it should be with the group zero underscore snow and how to connect it I'm gonna connect the warp to True over here and I'm gonna connect the dirt normal mask to false all right by default I'm gonna set it up to be true I'm gonna duplicate this use no one more time and I'm gonna do the same for the other alert so I'm gonna connect a over here and for the false I'm going to connect the dirt normal mask just like that and leave that fold value as true also the seconds now will use the group zero underscore snow and finally we want to learn one more time so I'm gonna lurp and I'm gonna connect over here the first note to a and I'm going to create a constant 3 vector corresponds three vector and I'm gonna make it blue in order to use the color of normal maps and I'm gonna connect it to B and for the alpha I'm going to create a new scholar parameter function input and I'm gonna name it depth pay which will be the fade of my depth and for the priority I'm going to put four and I'm going to connect it all the way to the alpha over here and finally we're gonna have the outputs so I'm gonna move this output over here and this will be for my normal near normal normal near I'm gonna connect over here and I'm gonna put the priority to one because this one the output base cover is zero all right and I'm gonna duplicate one more time as I want to connect the other switch parameter and this will be for my normal bar so we have the output for the near and the far and we're going to connect it over here and this priority should be too all right so we are pretty much done with the layer blend and the final thing if you forgot expose the library to turn it on all right so we are done with this one I'm Gonna Save and let's continue on with the next function and let's create our next function which will be the default layer so I'm going to right click material material function MF default there let's open it and the first thing exposed to library again just click nowhere not on the Block and you're gonna have it and we're going to start with text coordinate texture coordinate so this is how we're gonna get the UVS for far and near I'm going to right click and I'm gonna create function input and this will be vector 2. the first one will be named UV near and it is Vector 2 because we are working in two Dimension which is u and v and I'm gonna duplicate this one and I'm gonna name it UV bar so for the first priority I'm gonna set three and this one will be five and I'm gonna click use the preview values I'm going to connect the text coordinates to the preview over here connect them and the next step is to create a scour parameter so I'm going to right click function input and this one will be a scour parameter and this will be my UV near multiplier UV near multiplier and it will have the priority of four again I'm gonna use the preview values over here and I'm going to multiply the UV near to my UV near multiplier again M and I'm going to connect the UV near to a and this to be okay the next thing is I need to switch for it to switch it between true and false so I'm gonna right click and choose a static switch switch this one function static switch and when it's true it will multiply and when it's false it's not going to multiply so I'm going to connect it over here and the value will go to a new node which will be a static bull so I'm going to duplicate this vector and I'm going to choose the static Boot and I'm gonna name it advanced instructions UVs all right and here I will add a static boom static boom I'm gonna connect to the preview and now the static boot will go all the way up to my values over here so here we need to create the same for the far so I'm going to duplicate this one and this will be my UV bar multi wire this will hold the priority of 6 and I forgot to set up Priority for this one which will be 11 and now we're gonna do the same so I'm gonna copy this multiplication node I'm gonna connect my uv4 to a and the multiplier to be over here and I'm gonna duplicate this switch and it will be true over here and if it's false I'm going to use the UV far over here I'm gonna reroute it like that so it can be a little bit more clean I don't like how this looks it is not so clean over here so I'm gonna try to reroute it like that and maybe like that looks a little bit better yeah definitely let me just move this a little bit down those attentions to details are pretty much important later on if you need to make changes let's say a month later and you can see your connections and now I need to connect my Advanced instructions UVS to the fellow here and I'm going to clean this up too the next is we need to add our water refractions so I'm going to duplicate this one and I'm gonna name it water reproduction UV this will be for the UVS of the water refraction and the priority will be 7 for this one and again it will be Vector two so I'm gonna add it to this switch over here let me just add it like that and next we want a texture object and a texture base color so I'm going to right click texture object and for my texture object I've created a basic texture which will represent color let me just move like that texture this will be Albedo this is just a placeholder and from here I'm gonna drag and drop and function input and it will be textured 2D and I'm gonna name it texture base color after that I need to create a dipped fade mask so function input and I'm gonna name it depth create mask it will hold the priority of 2 and I'm going to set the use preview value as default and I'm going to multiply this depth of fade mask I'm on my keyboard and I'm going to connect it to a and I'm going to put a value of 0.75 to the multiplication after we've created the texture base cover the texture object and the depth mask what we need to do is we need to add a texture sample so I'm going to right click texture example over here and I'm going to start connecting my texture sample I'm going to move this a little bit like that first I'm gonna get the UVS from here I'm gonna connect them over here and the texture I will get it from here so I'm going to connect the texture and I'm going to change the sample source to wrap and I'm going to duplicate this texture sample one more time let's move it all the way back and I'm gonna use the second for my UVS over here and I'm going to connect the texture over here too all right and I'm going to create two more texture sample for the normal Maps this will be for the normal map and I'm gonna connect the UVs from the first one all the way down and I'm gonna duplicate one more time and I'm gonna connect the UVS from the second one over here at the UVS and those two texture samples should be normals normal and this should be normal and let's create our normal map I'm going to duplicate this texture object and the input texture base cover I'm gonna just duplicate them and I'm gonna put normal over here I'm just gonna use this water normal map as a placeholder and here for the texture 2D I'm going to rename it to texture normal and I'm gonna set up the priority to number one and I'm going to connect the texture over here to the texture slots texture all right I'm gonna rearrange a little bit and the next thing is I'm going to alert the depth fade mask with our texture samples which will be the cover once so I'm gonna use on my keyboard to learn them and I'm gonna connect my depth fade mask to my Alpha over here let me just clean it up a little bit okay and I'm gonna connect the RGB to B and the other one detects your sample to a and after we warp them I'm going to create a color correction and choose a constant Vector tree this one I'm going to move it a little bit back which will create the color correction and I'm gonna duplicate this vector 2. but I'm Gonna Change it to Vector 3 as it's going to be RGB I'm going to add it to preview and I'm gonna give it the priority to eight and of course I'm gonna change the name to color correction after that I'm gonna multiply our loop with the color correction so multiply a and our verb over here and I'll create a switch and this switch will tell us if you want to use color correction or no so if it's true we're gonna use color correction if it's not true we're gonna work directly and we are not going to use color correction I'm gonna use a little bit like that to correct it and this will go to my output which will be my last color we still didn't create the normal map so we're gonna do it and I'm gonna connect it over here now let's finish up our normal map so we have our two texture samples with the normal map and what we need here to do is we need to multiply with the normal intensity so I'm gonna go over here duplicate this texture today change it to scour let's name this normal intensity all right and I'm gonna check the preview I'm gonna put the sole priority of 9 and I'm gonna append depends and I'm going to choose append vector and I'm gonna append it Two Times by itself just like that and after that I'm gonna duplicate and append it one more time with a little value of one so I'm holding one on my keyboard and adding this value to B one and now I want to have a static bull which will be just like the advanced one that we've created just like this one I'm gonna move it over here and this will be static Bull and this will be Advanced instructions without the UV solve here and I'm gonna set the priority to that now let's connect everything so here from our texture samples I'm gonna create two multiplication nodes all right and the first one I'm gonna connect to a over here all right and the second one I'm gonna connect my RGB to my second a and for the B I'm gonna connect the append to the second B and to this B and of course I'm gonna clean this up like always like that clean this up like that all right and after we multiply two times we want to create switches for our normals so I'm gonna search for static switch I'm gonna create two times static switches so when we multiply and it is true and if we don't want to multiply it's going to go to false and the same goes for here when we multiply it is going to True when it's not multiplying it's going to false I'm going to clean up this one and I'm gonna clean up this one too and the values we will get the values from this Advanced instruction so I'm gonna connect the various over here I'm gonna move it like that and I'm gonna connect the values over there you can use this knot to create multiple connections just like that and I'm gonna try and clean up the notes over here move them a little bit like that and finally we want to create two more outputs the normal near a normal fire so I'm gonna duplicate two times this will be my normal here I'm gonna copy this one normal bar and I'm gonna connect them and set the priority so I'm gonna connect them over here I'm going to connect this over here this will have Priority One this will have priority two and the one thing that we are missing is here at this switch we don't have a value so I need to get a value here so I'm gonna connect this uh input Advanced instructions and I'm gonna reroute them again I'm gonna fix the the connections like that alright so we're pretty much done with the default layer I'm just gonna save it and close and let's continue on alright everyone so now we reach the fun part when we're gonna create the master material finally we already have all the functions so let's just dive into it it will be very complex but stay with me so I'm going to right click go to materials material and I'm gonna name it landscape Auto material array we're gonna start creating this so the first thing that I want to create is the control of the UVs so what I want is I'm going to go into my function and I'm gonna search for my landscape UVS I'm gonna drag and drop here and it is very good that we've created all those functions so we can work with it all right I'm gonna maximize and the first thing is I'm gonna search for a scour parameter all right and this color parameter will be my snow procedure mask size so snow mask size all right and for the default value I'm gonna put 32 and the group will be zero underscore snow and then I'm gonna divide my landscape coordinates with my snow procedural mask size I'm gonna use a division and I'm gonna connect my default value over here to B all right and I'm gonna connect my landscape coordinates all the way to a over here let me just move it like that and let me just clean it up a little bit just like that the next step is from the world coordinates I'm gonna put two reroutes so I'm gonna right click here reroute and I'm gonna name the first one landscape UVs slash world or dnates all right this will be my first reroute I'm gonna create one more reroute reroute and the second one will be UV mirror all right those will be the two that I've created let me just move it up and now what you need to do is I need to reroute this divide all right so I'm gonna drag and drop here reroute and I'm gonna name it snow you bees over here I'm going to use those three routes in order for me not to create a spaghetti over here all right the next step is to create one more scour parameter I'm gonna duplicate this one move it over here and I'm gonna name it a landscape size sites and the landscape size will be 2017 for start and for the group I'm going to create a new one landscape variation all right so I'm gonna divide this I'm gonna add a divide block and I'm going to connect it to B over here and I'm going to connect my landscape coordinates to a so I'm getting my landscape coordinates and connecting them to a I'm going to move this a little bit back in order not to crisscross and the next step is to duplicate this one more time and create one more node with the parameter name of variation World UV size World UV sites and for the default value I'm gonna put 32. now this time I will divide one more time so I'm choosing a divide node I'm connecting it to B but this time I'm going to use the world coordinates over here and I'm just gonna clean up this move them a little bit further just like that all right now when I have my landscape size and my variation World UV size I'm going to create a static switch parameter static switch which parameter this one and I'm gonna name it use worry variation bit landscape all right and I'm gonna connect the True Value over here the landscape size and if I Want A variation in the landscape size this will be false by default I'm Gonna Leave it to false then I'm gonna reroute the red route all right and I'm gonna name it use variation with landscape all right this will be my reroute for this one and let's create one more scour parameter I'm gonna delete this description and this one will have a name of landscape World UV size which will be determining the far size and it's going to be eight one nine two all right and the groups will be UVS UVS okay and again I'm gonna divide connected over here move them a little bit down just like that and this time I'm going to connect the world coordinates which will be the row coordinates and I need to clean up this a little bit not to get messy something like this looks a little bit better let me move those a little bit down so that the text doesn't overlap with the UV near a route all right so this looks pretty good and now we need to reroute this divide so I'm gonna drag and drop here reroute and I'm gonna name it UV bar all right this will be my far UVS I'm gonna align them just like that now we need two more scour parameters the one will be for the snow Edge Mass UV size and the other will be for the water edge mask UV size so I'm gonna duplicate this landscape size I'm going to move it over here delete everything from the description and the first one will be snow Edge mask UV size all right it will hold a default value of 2 5 6 and I'm gonna group it under zero snow okay now what I need to do is again I need a divide block over here and I'm gonna connect this to B and my a will use the landscape coordinates here all right it looks pretty clean still not messy and now we need to reroute this because we're going to use this a little later in our other blocks so we route and name this snow Edge mask UV size all right we're gonna align this and finally let me just move this a little bit up because I want to create one more node and finally we need to create the water edge mask UV size so I'm going to duplicate this one I'm gonna name this water edge mask UV size all right this will be the mask for my UVS of the water it will have a default value of 15 and I'm gonna create a new group which will be one underscore water all right and again we need to divide I'm going to duplicate this connect it to B move this a little bit down and I'm gonna choose the landscape coordinates connect them over here and fix the connection not look bad fix all the connections that you're creating because later on it will be pretty messy to fix something if you did crisscross everything all right this is the only crisscross that I make and this one but they're visible and finally we need to reroute this reroute and this one will be my water edge mask UV size water edge mask UV size all right and we are pretty much done with the UVS so I'm gonna select everything click C on my keyboard and name it you piece all right so this will be my UV block and I'm gonna create the different blocks here in order to create the final connections to my material and I'm gonna use a lot of reroutes the next one that we are going to create is we're going to need the depth fade mask so I'm going to minimize here and I'm gonna search for my depth fade mask this one depth fade I'm gonna drag and drop it over here zoom in and from the dev fade mask I'm going to reroute reroute and I'm gonna name it depth paid mask underscore r or reroute I'm gonna move it like this and I'm gonna comment depth paid mask all right so this block will hold my depth fade mask I'm gonna move it over here and we're done with the dev fade mask now let's start creating the layers the first layer that we're going to create is our rock layer so I'm gonna choose my default layer that we've created this one the default layer I'm going to drag and drop it over here and I'm going to maximize this and we will need to create our first rock layer using our default layer all right we're gonna create connections for everything over here so the first one is we need a texture this one under parameters and I'm gonna put the name texture Rock base color texture Rock base color all right and for the texture I'm just gonna use my Albedo over here just for a placeholder and I'm gonna group this and put Pi underscore Rock so this will be my group of the rocks and I'm gonna duplicate this one in order to create the texture normal so this will be my texture Rock normal all right it will still hold the rock group but here I'm going to choose the normal for normal map now the rear routes here that we've created we're gonna start to use them I'm going to connect this one here I'm going to connect this one to the texture normal the first one is the fade mask right click name three routes depth fade mask connect it over here so the different the difference is I've connected over here and I didn't do it like that imagine if you start connecting everything like that it will be complete nightmare at the end so I strongly suggest you follow my advice of the reroutes the next is you veneer so I'm gonna search for you veneer you veneer connect it after that we gonna use the uvinier multiplier which will be a scour parameter it's cover parameter and this will be Rock UV near move wire I'm gonna move it like that and connect it over here this multiplier will go with the group of rocks over here and I'm gonna set up the default value of one all right moving further is UV far right click memory routes ue4 connected over here move it like that let me just shift a to arrange everything and move this a little bit down and after we've created the UV far we need to create one more scour parameter for the rock uv4 multiplier I'm gonna duplicate this one and I'm gonna just change the near to bar all right I'm gonna connect it over here to UV far multiplier and everything is set up row group and the default value is one the next thing is water refraction UVS we still didn't create one in the reroute over here we don't have the water refraction later on we're gonna connect it or the cover correction we need a vector 4 parameter so I'm gonna right click and I'm gonna search for constants or vector this one and I'm gonna connect it to color correction I'm Gonna Leave a space for my water refraction UVS I'm gonna move it like that and here in the constant I'm going to put values of one for everything so it can be white all right and after that I'm gonna right click convert to parameter and just put a name for this rock color correction so we can correct the color of rocks through this parameter and I'm gonna put a group of rock and everything is set up for my rock color correction shift a we have normal intensity Advanced instruction and advanced instruction UVS for the normal intensity I'm going to use another scour parameter so I'm going to duplicate this one move it over here and I'm gonna name it Croc normal intensity all right it will be one and the layer the group will be Rock I'm gonna plug it over here and for advanced instruction and advanced instructions UVS I'm gonna create a static bull parameter static boom and not function we need a parameter and I'm gonna name this use Rock Advanced all right and this will hold the group of five so I'm arranging everything in the group name five I'm gonna connect it over here by default it will be false and I'm gonna duplicate this one I'm gonna use the same thing and I'm just gonna add UVS at the end and connect it over here to my Advanced instruction UVs I'm gonna move it like that and we're missing the one slot which is the water refraction shift a and I'm gonna select everything comment this and put the name rock layer I'm just gonna Zoom because I don't see what I'm typing so I'm gonna put Rock there after we create it and name the rock layer what you need to do is expand and cover this block and I'm just gonna reroute the base color the normal near and normal far so I'm gonna drag and drop reroute and I'm gonna name this rock layer underscore base power underscore error or rewrote I'm gonna do the same for those three routes and I'm gonna name this rock layer underscore normal near r and I'm gonna reroute mod one more time here routes and I'm gonna name this rock layer underscore normal bar r so we reroute this and we can use this later on I'll just remember that I've missing water reflection UVS and come back later to fix it I'm just gonna arrange this rock layer over here above it and I'm gonna start creating one more default layer the next layer will be our Stone layer so I'm gonna select everything I'm gonna duplicate it move it down here because some of the things are already created I'm gonna delete those three I'm just gonna change this to texture stones base color all right and I'm just going to change the group to four and I'm gonna name it Stones so this will be my stones in my scene I'm gonna do the same here for the texture Rock texture Stones normal and I'm gonna Choose Or for the stones I'm gonna move down here and here I'm going to use the dev fade mask again I'm going to use the UV near and here from rocks I'm just gonna change these two stones you'll be near multiplier all right the default value will be one and the group will be four the next step is the UV far which is connected here rocks I'm Gonna Change it to stones tones all right the group will go here four Stones the next is the color correction again I'm just gonna change rock to stones and I'm going to change the group to or it is a little bit repetitive guys we're gonna move to rock normal intensity Stones normal intensity and group will be poor and the final things are the static bull parameters so use tones Advanced use don'ts Advanced and change the group to four all right and finally what we need to do is to reroute this default layer which will represent our stones in the scene and I'm going to reroute like the previous one reroute this will call the name Stones layer base power r right I'm just gonna duplicate this one connect it over here Stones layer normal near r and I'm gonna duplicate this one normal bar R alright everything looks good and let's move on by creating the next layer I'm going to select this one I'm gonna copy and paste it move it over here I'm gonna comment and this will be my grass layer all right and again we're gonna do the same we're gonna select this texture press base color and the group will be 3 underscore grass all right I'm gonna do the same for this one stones will be grass this will go to Grass the fade mask is okay UV near is okay Stones UV near multiplier which will be grass UV near multiplier this will go to my grass uv's part is okay stones will go to grass this will go to the layer of grass this will go the same grass power correction it will be grass moving further storms normal intensity whereas normal intensity change the group and I'm gonna change this one to grass and this one to grass and I'm gonna go back to the names press and this one will be grass all right I'm just gonna delete those because I want a different color blue route and this will be grass layer underscore base color R I'm gonna duplicate two times normal normal bar so this one will be my normal normal near r and this one will be normal or r gonna shift a I'm gonna move this a little bit up and right now we have our Rock and this is not our rock layer this is Stones layer yeah and our grass layer we need to create two more layers I'm gonna copy and paste this one move it like that I'm gonna comment and this one will be my dirt there and let's do the same for this it will be do underscore dirt and this will be holding the name of dirt move to the normal map the same dirt here it will be dirt that fade mask is okay you veneer is okay grass will go to dirt and the layer will be dirt grass will go to dirt and there will be dirt grass will be dirt in the color correction this will be dirt or the normal intensity I'm gonna change this to dirt and this one will be dirt again and let's change the last parameters dirt use grass which is use dirt and this will be dirt all right and finally we need to reroute again I'm gonna delete those three and I'm gonna reroute first the base cover reroute and this will be dirt layer underscore base cover r two more times duplication connected connected clean this up like that this will be my third layer normal near r and this will be my dirt layer normal or R all right and the final layer that we need to create is our snow layer so I'm gonna select the dirt layer here I'm gonna Ctrl C Ctrl V move it all the way down and I'm going to select this and rename it to snow layer all right and I'm gonna repeat the procedure from the previous one that will be snow so this is texture snow base color and this will go under zero snow all right I'm gonna do the same for those two snow and here I've missed the sample which is should be normal so I will go here and fix it pretty quickly for each one of them normal this will be normal again normal let's fix this one normal and let's pick this one and everything is fixed all right let's continue on so we have the textures now normal the fade mask you veneer this dirt should be snow let me check if I put here uh the snow layer no here is the snow there snow layer all right the fix with the normal snow the fade mask here this one should go to the snow again dirt UV bar this should be snow UV bar again the group should be snow moving further with the color correction no color correction snow let's try with this one no normal intensity snow and this one should be snow this one should be snow and I'm gonna change the dirt too slow pretty easy but repetitive snow I ate a letter and SUV and of course if you want more layers like uh anything that pop outs in your mind you can add as much as you want over here so you can add let's say a trunk layer some other layers of course add more I'm gonna delete those and I'm gonna reroute reroute and this time will be snow layer base cover r slow layer base color underscore r two more times this will be the normal near so snow layer normal near r the next one will be snow layer normal r r all right shift a and we've created one more layer which is our snow layer the next step is we need to create a opacity mask so I'm gonna go here and search for length Escape visibility mask over here this one and I'm going to reroute this reroute and I'm gonna name it opacity mask length Escape Visa bill B mask R so it will be let me just expand it opacity mask landscape visibility mask R I'm gonna cue those and I'm gonna comment opacity mask this will be my opacity mask I'm gonna move it like that in the next block that we're going to create is our remove foliage so we're going to have a layer on our landscape where we can paint in order to remove Foliage for example if you want to create a road we can just delete some folges that was how to spawn on our Auto material so I'm going to use this opacity mask that I just created so let me just find it all right and I'm going to right click and search for landscape and I'm gonna find this landscape layer sample all right and I'm gonna name the sample remove foliage all right so I'm gonna have a layer where I can remove the foliages from anywhere on my landscape and I'm gonna do a 1 minus over here you in order to align them then I'm gonna multiply with my mask with opacity mask that we've created I'm gonna right click and search for clamp over here and I'm gonna clamp it from zero to one because I don't want to go beyond that and I'm going to reroute reroute all right and I'm gonna name it remove foliage clamp r all right pretty good this one will be removed all the edge all right and I'm gonna place it over here so we've created one more the next thing that we need to create is masks so I'm gonna right click and search for texture object I'm going to select it to be masks I'm going to minimize and here in my textures I have a noise mask I'm going to connect it over here and I'm gonna start creating some logic from here so the first thing is I need to get my water edge mask UVS the size and I'm gonna search for texture sample all right and in the texture sample I'm gonna connect here on the UVS and I'm gonna connect the texture to this texture okay I'm gonna duplicate this one more time so the first thing is for my water edge UVs the second thing will be for my snow Edge mask UV size so let me find um what is it snow Edge mask you besides this one connect to my UVs and I'm going to connect my texture object over here to the texture and of course I'm gonna clean it up the connection over here and my third texture sample will be connected to my snow UVS so I'm gonna fight my snow UVS I'm gonna connect them over here and from this connection I'm just gonna do over here in the texture and I'm gonna connect it like that and now for the sample Source I'm gonna select rub for everything or up let's do here wrap again and the rest will stay as it is the next thing that I need to do over here in The Mask section is let me just align this because I need to look them pretty all right align those three we need to clamp the first one so I'm gonna clamp and I'm gonna clamp just the blue Channel and I'm gonna clamp it from Min 0.1 this will be my minimum and my maximum will stay at one and the second mask texture sample I'm gonna multiply it by 0 0.001 so I'm gonna have two zeros one and I'm gonna connect the green channel here and I'm just gonna align those things Q in order to align them shift a to align them and here I'm going to use the blue Channel again so from this blue Channel I'm going to reroute and I'm going to name this masks small UVS texture B Channel R all right and I'm gonna reroute those two reroute and this one will be masks Edge mask UV size no key wire r I'm gonna align it and I'm gonna create one more reroute this one will be masks underscore Edge mask UV size lamp R alright so we are done here with the masks and I'm gonna select everything comment masks so now as we've created the general masks we need to break it down to the snow mask dirt mask Stones mask and grass mask so I'm gonna start with the snow mask so I'm gonna right click over here and search for my masks which will be my masks Edge mask UV size multiplier this one so from this one I'm gonna go and search for my snow mask over here in the functions let me search where is my snow mask this one I'm gonna drag and drop it over here and I'm gonna connect it to mask over here I'm gonna queue so I have my mask Edge mask UV size multiplier R and then from the snow mask I'll just need to reroute the snow vertex mask and pixel mask so I'm gonna reroute it's pretty simple it's no mask this will be my group snow vertex mask r and I'm gonna duplicate this one connect over here and I'm gonna name it snow mask it's not pixel mask R alright and this will be for my snow mask snow Ness all right this is our snow mask let's continue on with the dirt mask the dirt mask will use a slope mask so I'm gonna go and find where is my slope mask this one I'm gonna drag and drop this function I'm gonna maximize and we need a scour parameter over here and I'm gonna name this dirt swap power this will Define the power of my dirt and I'm gonna put here dirt and for a default value I'm gonna put one to eight all right I'm gonna connect to my slope power over here Q and again we need to reroute reroute will be dirt mask walk mask r and I'm gonna duplicate this one keep the dirt mask and this will be slope normal mask R and I'm gonna connect it over here shift a here I'm gonna use q and I'm gonna comment this one dirt mask the next one is our Stone mask and I'm just gonna duplicate those two move them a little bit down and this one will be my Stones swap power the power of the stones and for the group I'm gonna choose stones and for the default value I'm going to use two and I'm gonna use again a slope mask over here to define the slope of the stones and here I'm gonna Define the neural route and it will be Stones mask swap mask r I'm gonna duplicate this I'm gonna connect it and I'm gonna rename this to swap normal mask R all right shift a and we have created our Stone masks Stones mask all right and the last mask that we need to create is our grass mask I'm gonna duplicate again those two and this one will be my grass whoa power it will hold a group of three and it will start from something like eight and again I'm gonna reroute here reroute and here will be grass mask on slope mask r I'm gonna duplicate this one and this will be my grass mask slope normal mask R alright let me just move it like this and I'm gonna comment press That's sounds good and I have created my snow mask dirt mask Stones mask and my grass mask the next mask that we want to create is our water mask so I'm gonna minimize over here and search for my water mask here water mask I'm gonna drag and drop it over here I'm gonna maximize and I'm gonna use the reroutes I'm gonna search for my snow vertex mask r so snow vertex mask R this one and the next one will be Edge mask UV size which will be the clamp I'm going to search for Edge I'm just gonna here type in the search Edge lamp this will be The Edge mask UV size clamp and I'm gonna connect it to this one to the mask s and the first one the snow vertex mask R will go to the snow vertex mask over here and I'm gonna just reroute and I'm going to name it water mask mask r I'm gonna cue those two and I'm gonna move this one over here and this will be my water mask all right let's move this a little bit down over here so let's arrange them here are our masks over here and the next thing that we want to create is our layer blend and this will be a huge one so I'm gonna find my layer Blends I'm gonna drag and drop it over here and we're gonna start using all the reroutes over here and start connecting to my layer blend the first ones are the rock bass cover Stone base cover so I'm gonna search for rock base color connect it over here to my rock base cover Stones base cover connects to my Stones base cover this will be pretty easy but it will have a lot of components then we have the grass base cover brass base power we have the dirt dirt base power all right then we have the stone mask which is a slope mask stones this one the slope mask not the normal one I'm gonna connect it over here so I'm connecting the stone mask slope mask r then we have the depth fate that weight which is the dev fade mask are this one connected to my Dev page the next one is our grass mask again we need the grass mask slope mask without the normal grass slope not the normal one just the slope mask connect it here then we need the dirt dirt slope again the basic one without the normal I'm just gonna move this a little bit down I'm gonna shift a those and move them a little bit like that to arrange them all right so we've made half of it the next is the rock layer which is the near normal so I'm gonna search for rock near normal and I'm gonna connect though here so this is my rock near normal near normal which is the rock layer then we have the rock far normal so Rock Bar normal connect it over here after that we have the stones near normal stones in here normal we have the stones star those who are normal and let's start connecting them Stones near Stones far move it like that I'm gonna shift a again move them a little bit down then we have the grass near normal grass fire normal grass in here again Brass Bar let's connect the crust near let's connect the grass far the next is the dirt near normal dirt near normal then we have the dirt part normal and let's connect the dirt near over here let's connect the dirt bar over there we have the snow near snow near normal then we have the snow or normal so it's known near over here then snowfall over there after that we have the Stone's normal mask I'm gonna put this but this time we need the slope normal mask of the stone here Stone mask slope normal mask not the original one then I'm gonna connect it over here to the Stone's normal mask move it like that shift a the next one is the grass normal mask so I'm gonna search for slope normal which will be my grass all right and I'm gonna connect it over here so I'm choosing the grass mask slope normal and connecting it to Grass normal mask over here and then the next one is the dirt normal mask so dirt lope normal one not the slope mask but the slope normal I'm gonna put it over here I'm gonna zoom out and connect though here and the final one will be my snow vertex mask snow vertex mask snow to vertex mask I'm gonna place it over here at the bottom all right we are almost finished with this one guys and we've created our layer Blends pretty complex a lot of bangs over here and that's why I'm using reroutes and the final thing that we need to do is we need to reroute the layer blend so reroute and I'm gonna name it layer blend base color r and of course three duplications this will be my normal year normal near r and this one will be my normal bar R all right we've created everything over here in the layer blend I'm gonna comment layer lens all right now as we have the layer blend we can combine the normals that we've connected over here so I'm gonna right click and search for normal near layer blend in the next one will be my layer blend normal far so I'm just connecting my far and near and I'm gonna use the combined function that we've created so I'm going to minimize which will be combine normal simple this one the simple method and I'm going to connect my normal near to a and my normal far to B and I'm gonna reroute in the route this will be combine normal result result are I'm gonna queue those two move them like that and I'm gonna comment this combine normal and now I've combined the normals from the layer blend and I'm gonna move the combine normal over here I have a little space over here free that I'm gonna use the next one is we need to create a little variation in our landscape mask so I'm gonna search for fit landscape which is the use variation fit landscape and this will be my variations so from here I'm gonna search for texture sample which will be the texture sample parameter 2D in this one I'm gonna name it texture landscape and here I have by the photo texture which I can use and of course you can create one in Photoshop for the variation I'm gonna set up the sample source to wrap and I'm gonna select for the group landscape variation I'm going to connect the with landscape to my UV server here and I'm gonna search for my base cover of the layer blend base color layer blend and this one I'm gonna multiply together so this will go to a this will go to B I'm just controlling the UVS with this one and I'm gonna multiply one more time and this time I'm gonna multiply it by 1.5 and this will be my variation and of course we want to reroute our route so this is variation landscape variation mask multiply R you can put different names for the reroute as you wish but those are mine and I'm gonna comment this variation now we've created one more block and I'm gonna move it above the UVS over here all right as we've created the variation we want to create a switch to turn it on and turn it off so what I'm going to do is I'm going to search for the reroute that we've just created so landscape the creation mask multiply this one and I'm gonna search for the layer blend base color and all those two will go into a switch parameter switch parameter and I'm gonna put a name for the switch parameter use landscape variation okay I'm gonna connect this to true if we want to use the multiply and it will be here in pose and I'm gonna put for the default value true and of course I'm gonna reroute so that we can use this so I'm gonna name it use landscape evaluation switch R so this will be my switch I'm gonna comment use landscape variation switch landscape variation switch and I'm gonna put this above my variation so they are close to each other that I know that they're working with each other and finally I need to select the group to be under my landscape variation so you can activate it there the next block that we want to control is the roughness by using the landscape variation switch so I'm going to minimize and I'm going to go to my functions and search for my roughness where is my roughness this is my roughness this will be a pretty easy one so I'm gonna search for use landscape variation switch this one use landscape variations which are I'm going to connect it to roughness and I'm just going to reroute and the reroute will be roughness r I'm gonna kill this one moment roughness so we can easily control the roughness over here and I'm gonna move this above my landscape switch because they're a little bit connected so let's move on and create the variation for my normal map so I'm gonna go here and I'm gonna search for the combine normal result that we've combined the two normal Maps and I'm gonna search for use variation bit landscape and I'm gonna create scour parameter the name of the first color parameter will be normal intensity all right and I'm gonna put one for the default value and the group will be under my landscape variation I'm gonna move it like that I'm gonna duplicate over here and the second one will have a variation normal intent intensity and the default value will be 0.25 all right so what we need over here is we need the node combine normal not the simple one so I'm going to go to functions and I'm gonna find combine normal I'm going to drag and drop it over here we're going to move it like that and I'm gonna connect the variation normal intensity to my abnormal intensity I'm gonna fix the connection over here and the normal intensity will go to my my base normal intensity all right fixing it like that and now for my use fit landscape I will need a texture sample which is a parameter texture sample 2D parameter this one and this one I'm gonna name it texture landscape variation normal and from here under the sample type I'm gonna choose normal for the group I'm going to choose landscape variation and for the sample Source I'm going to choose wrap and here I'm gonna need to apply a texture which will be a normal map for the variation so I'm going to minimize I'm gonna go to my texture and I have this landscape normal variation which I'm going to plug over here I'm gonna maximize and I'm gonna put my use variation fit landscape to my UV server here let's queue in order to align it move it like that move this a little bit up and now I need to connect my RGB to the abnormal over here and my combined normal results to the base normal I'm gonna reroute it over here like that I'm just fixing the path and then I need a static switch parameter in order for me to turn it on on turn it off so static switch parameter which is over here static switch parameter I'm gonna name this use landscape variation I'm gonna move it all the way over here and this will be connected to false and my normal will be connected through like that and I'm just gonna fix this path just like that so it can be a little bit more clean and for the static switch parameter again landscape variation as a layer for the group and finally we need to reroute this so reroute and this will have the name variation underscore normal underscore landscape variation underscore r a little bit longer but at least this works for me shift a to arrange them and I'm gonna comment this normal variation all right I'm gonna move it over here under the blend layer now the next block is very important it will hold the procedural 3D object that we're gonna spawn on our terrain so let's start with it I'm gonna hold one of my keyboards and I'm gonna create a value of one and I'm gonna make a subtract in this subtract I'm gonna connect one over here and I'm gonna search for slope mask which will be the stones one this Stone and I'm gonna connect to B I'm going to duplicate this subtract I'm going to connect the stones over here to a I'm going to search for my grass slope mask this one without the normals I'm gonna connect it to B and I'm gonna duplicate and connect the grass over here I'm gonna shift a in order to arrange them and I'm gonna search for my dirt dirt swole dirt slope mask are this one I'm gonna connect it to B so this is the first step next what we need to create is our mask for the water so I'm gonna search for water mask this one and I'm gonna make one minus to reverse it just like that Q I'm gonna move it like that and I'm gonna create four multiply notes all right four multiplications I'm gonna shift a move them like that and I'm gonna start connecting I'm gonna connect my reversed water mask to a in each one over here to all my four and first I'm gonna search for my dirt slope mask which is this one I'm just gonna duplicate though here and connect it to B all right the next one the subtract will go to B over here the second subtraction will go to the second multiply node and I'm just gonna fix this path over here so it can look a little bit more clean and the first one will go to B in my first multiplication with the water mask layer just like that I'm gonna select those I'm gonna comment them mask water and I'm gonna move on with the next one which is the mask snow so for the mask snow I'm gonna search for my snow pixel mask all right and I'm gonna create a little logical here first I'm going to multiply it I'm gonna queue over here and I'm gonna multiply it by four and after that I'm gonna search for one minus I'm gonna connect it over here I'm gonna kill over here and I'm gonna duplicate one more one minus over there connect it like that fix this route I'm gonna create a new multiplication node over here but I want the multiply to work with my snow uv's mask so I'm gonna search for snow UVS and I'm going to choose this mask I'm going to connect it to b u and now I'm going to move this a little bit back my snow mask with the snow pixel mask will go here to a and again I want to create four multiplication node one two three four let me just arrange them so the first one minus will go to my first multiplication my second multiplication and my third multiplication the second one minus will go to my multiplication over here let me just I want to arrange everything to look a little bit clean because it will look a little messy and for the bees I'm gonna get my mass quarter and connect the multiplication node over there so the first one will go into the first being I'm gonna fix this one the second one will go to my second B and I'm gonna fix this one of course you can reroute them but here is not looking so messy the third one will go into my third B and the fourth one will go to my 4B all right and this one will be masked snow so we've created The Masks now and now we want to power everything by four so I'm gonna right click and create a power node and I'm gonna create separate or power nodes one two three four each power node will have four for its exponent four four four and I'm gonna connect the multiply over here to my power here to my power and here to my power and the next thing is we need to create a mask visibility with the remove foliage so I'm gonna select the remove foliage so that we are able to remove the foliage in the end and I'm gonna create four more multiplication notes just like that and every Power will go into B so B B B and B and this will go into a a and this will go into a and this will go here into a all right and I'm gonna move this a little bit up and this will be my mask visibility all right I'm naming it like that because uh here is how we're gonna remove the foliages and finally we need to create switch parameters for each one so I'm gonna search for switch static switch parameter I'm gonna put it like that and the first one will be my rocks so I'm gonna choose rock over here and by default value it will be true and I'm gonna name it use Rock procedurals all right and I'm gonna connect this through I'm gonna move it like that and then I'm gonna duplicate this one and the second one will be use Stones procedures and of course it will be installs this will be connected to true the second one I'm gonna duplicate one connect my multiply to true and this will be my grass procedurals all right so I'm gonna change from stones to grass and the next one I'm gonna connect it over here and this one will be my dirt procedures and I'm gonna select the dirt top here and we need one more for the snow so I'm gonna name this use snow use no and I'm gonna select here the snow and the one thing that I forgot is I'm missing the snow multiplier so this is because I didn't connect this one so I'm gonna create one more power I'm gonna connect this to base over here let me move it like that let me move it like that and I'm gonna create one more multiply node connect it over here to true and connect my power to my B and connect this one to a over here and let me just move it just like that so it can be arranged pretty good and here is my use no procedurals holding the snow getting the multiply from here and having the power over here from the snow UVS all right and finally we need something for the force which will be zero when it's false it's zero and I'm gonna connect this parameter over here to my Force over here and over here a little bit messy but it looks not so bad and I want to reroute here the subtract of the procedurals so I'm gonna drag and drop here and I'm gonna reroute and I'm gonna name it procedurals subtract R all right so I'm gonna use this a little bit later we create the next node and finally we need to create a landscape grass output so I'm gonna right click landscape grass output this one all right and in this output I want to add few indexes so I'm gonna add until four and I'm gonna name the first one will be my rock my rock the second one uh will be my stones the third one will be my grass this one will be my dirt and the fourth one uh will be my snow and here in the grass type we're gonna plug procedurals I'm gonna show you how you can create them and let me just look the rock over here the stone over here the grass over there here is the dirt and here is the snow and let's say this is uh really lashes pipe so we've add here 3D meshes that we want to spawn on our Terrain and finally I'm gonna comment all this block with the name of procedurals and we are ready with our procedurals this was a complex one I'm gonna move it over here and let's create the next block which is our specular so I'm gonna choose the procedural subtract that we've created subtract all right and I'm gonna one minus over here connected to 1 minus Q in order to align it then we're gonna use the landscape variation switch use landscape variation switch this one and I'm gonna reverse it also with one minus I'm going to multiply this switch over here by 0.5 and here in our procedural subtract I'm gonna create a scour parameter I'm gonna give it a name grass specular specular this will be the speaker for my grass so I'm gonna put 0.1 and it will be under my grass group over here then I'm gonna search for clamp and I'm gonna clamp this one and this one will go into Min and the maximum will be one the next is we need the snow pixel mask so I'm gonna search for snow pixel no pixel mask this one and I'm gonna add them together the clamp over here and the mask in a and when we add them I'm going to clamp them one more time so I'm gonna Clump them like that and it will be between 0 and 1. and this to the multiply note and the clamp node I'm gonna multiply them together over here and over here in order to create the specularity and finally I'm going to reroute and this will be specular multiply R all right and I'm gonna comment those back your and this is my specular block and the next block that we want to create is the water itself so I'm gonna minimize and I'm gonna search where is my water MF water over here and here we need to plug the base color specularity roughness normal World coordinates water mask Etc so let's start by using the landscape variation switch landscape switch landscape variation switch use landscape variations which are this one and this one will go into my base color then specular multiply that we've created go going here next is roughness roughness going into my roughness after that we want the normal landscape variation normal landscape variation this one I'm gonna connect to my normal then we need the world coordinate landscape World coordinates connect over here and finally we need the water mask which is this one and connect it over here all right the first batch is done then what we need to do is we need to start rerouting reroute this is a water base Tower r and of course I'm gonna duplicate one two three four five times one two three four five times let me just arrange them one under another and this will be my water metallic r the next one is water specular r let's start connecting them all right then it's water roughness roughness r then we have the water normal r and finally we have the water refraction UV so this is be my this will be my water reproduction uvr and connect them all let's connect them all all right pretty good it starts shaping we have a few more notes and we're gonna be done and this is water we've created the water right now so we can create the snow I'm gonna minimize and I'm gonna search for my snow this is my snow this will be pretty easy the first one we need is water base cover so I'm gonna connect here in the snow then we need the snow layer base color and we need the snow mask uh underscores no pixel the pixel mask all right I'm gonna connect the snow base cover over here and the pixel mask over there and finally of course I'm gonna reroute the snow reroute and this will be my snow base power R so this will be the base cover of the snow click on the common snow and finally before we create the material connections I want to create a little block which will be for debugging so the first thing is we need the stone mask which is the slope mask over here then we need the grass mask the slope mask over here and we need the dirt mask again the slope mask and you can enable this to debug and check how all the things are working so I'm gonna subtract and I'm gonna subtract here a and here B I'm gonna duplicate this one and subtract again with the dirt mask this will go into my a this will go into my b like that and I'm gonna search for append Vector append Vector so I'm appending the two subtracts over here getting them together then I'm gonna append one more time and I'm gonna paint with the dirt mask over here I'm gonna move this a little bit down all right then I'm gonna need to get the water mask water mask which is the mask r and I need to get the snow mask it's snow mask and this will be my pixel mask all right shift a and from this event I'll subtract subtract a pet will go here in the subtract and my water mask will go over here and I'm gonna subtract one more time with the snow pixel mask all right and I'm gonna create a static switch parameter static switch parameter over here and I'm gonna name this parameter The book must snow water so we can debug the snow and water and I'm gonna name it the book over here for the group and the default value will be true for the force I'm gonna choose the pen before the snow and the water over here and if it's true I'm gonna select the subtract over here I'm gonna duplicate this parameter once more because I want to debug the snow and water without the masks so this will be my debug for snow and water without the mask it will be false by default and I'm gonna connect this debug over here to false and I'm gonna create one more snow mask and I'm gonna use the snow pixel and I'm gonna use the water mask which is the water mask R over here all right and I'm gonna append a vector once again to a pen to B and this will go into my True Value all right and finally we need another switch that will turn it on and turn it off so I'm gonna duplicate and I'm gonna name it the book The True Value will go over here and for the false value I'm gonna get the snow base cover it's no base color this one and this will go into my Force and I'm gonna reroute this reroute we route and this one will be my debug R for the rear routes so this is how our the bug block looks like I'm gonna comment the book and I'm gonna move it all the way over here and we've created a lot of blocks over here and we've come to the final one and the final one is to connect everything to my landscape Auto material so for the base color I'm gonna connect my the book so I can turn it on and turn it off the book for my base cover for the metallic I will connect the water metallic water metallic R over here to the metallic Channel to my speaker I'm gonna connect again the water water specular because the water is the lowest point and then for the roughness water roughness all right connect the water roughness over here I'm gonna shift a the next thing is that we need an opacity mask so I'm gonna click on my auto material over here and in the blend mode I'm gonna choose mask and once I choose masked the opacity mask is turned on so I'm gonna search for my opacity mask landscape visibility mask all right I'm gonna connect it here and finally we need to connect the water normal over here to the normal and our automatic Master material is finished so I'm gonna just comment this and name it auto material vinyl connections now this is our landscape Auto material and what I want to do is I want to create an instance of it I'm going to right click and create material instance and I'm gonna name it Mi for material instance landscape Auto material all right we'll have all the parameters that we've created over here and few things that I need to fix over here I thought my material was ready but now in the dirt section here I've left the group I need to place here dirt and here dirt and over here we have water refraction that we didn't connect so I'm gonna connect it right now water refraction this one I'm gonna connect it over here I'm gonna search for Walker water for reproduction and I'm gonna connect it here to the snow over here we're going to move all the way up and connect my water refraction over here and my grass I believe yeah here one more I'm gonna connect it over here in my stones and over here that we left it this is in my rocks I'm Gonna Save right now and we fix that problem I'm gonna go all the way down select my landscape and into the landscape material I'm gonna drag and drop this one the instance and now we have our water we have some shades over here and we have our uh placeholder textures we're gonna double click on my material I'm gonna expand a little bit the window and here you can have the snow you must have the snow all the parameters over here we have the water the dirt the grass the Stones The Rock the the book the landscape variation the lightning and the UVS if you're missing some of the check boxes over here you gotta go into your landscape material and in your landscape material you're gonna check which one you're missing for example if I'm missing the used landscape variation I just need to check if the group is is Right landscape variation so if you are missing any of those parameters over here you need to go back to your landscape Auto material and just check the switch or the scour parameter and add it to the group so I'm gonna scroll slowly here so you can pause the video and check if you're missing any of this because it was a complex Auto material and of course you can make some mistakes alright all the way up okay so now I'm gonna start by enabling the textures over here so I'm gonna enable the texture for my snow and let me go all the way back to the mountain over here so when I plug my snow I've already downloaded a few textures from Mega scans Library so I'm gonna expand I'm gonna go to my surfaces and I'm gonna search for my snow and I'm gonna start plugging my snow texture this will be my base cover and this will be my normal map and as you can see over here we already have a little bit of snow I'm gonna hit save so I've added my snow texture now let's move on and I'm gonna check the use water because I want to use water on my layers over here let me just go over here so we have a little bit of water the next is the dirt I'm gonna enable the dirt and I'm gonna go to my dirt texture plug it over here plug this normal map and we'll start to getting some dirt around the water over here as you can see all right pretty good the next is the grass I'm gonna enable the grass I'm gonna go to White my wild Mossy grass drag and drop the textures over here and now I have a little bit of grass over here later on I'm gonna color correct them and fix everything let's move on to the stones and I'm gonna go to my Moshi Rocky and I'm gonna enable it over here and finally we have the Rocks which are the slopes and I'm gonna go to my row cliff and enable this all right so right now we have some textures blending but it still not looks too good all right I'm gonna enable the snow World position and let me show you what this will do this will add snow to your ground enable it and if I start tweaking it my snow will be all the way up to the melting or I want my snow to be somewhere at the bottom all right so I'm gonna tweak it like that so it's only in the mountains over here the next one that you can tweak is the snow mask power I'm gonna enable it and if I turn it on my slopes will have also snow and if I turn it off those Cliffs will have less now so I want something like this let's try this no slope power here the slopes are getting a little bit snowy just a little bit maybe something like this it looks uh better I'm gonna cover correct later on all the things and you can pretty much tweak all the parameters in the snow and get your final result the next thing that we're gonna set up is the water so let's go to the water over here all right to this bottle and I'm gonna select a new water cover so I'm gonna enable it and I already had a hex cover for it so I'm gonna add it over here and this is my color of my water then I'm gonna select the water edge contrast and I'm gonna put it to 2.4 over here so right now I'm just creating this believable water so if I start tweaking The Edge contrast I'm gonna expand it and it's gonna look a little bit ugly but you can take it off and you're great creating this wetness let me try 1.8 all right you have this wetness over here you have this uh moving of the Water by using the procedures all right that looks already good then you can tweak for example the normal intensity you can boost up the ripples over here you can tweak them down you can reverse it you can make something like an ocean or you can ease it down like pretty steel water you can play with it get a lot of nice results over here it is very tweakable all right so I'm gonna turn it off and just leave it like that and with water slow power you can add a lot of water to your terrain or just take it off so let's try and boost it all the way down and you can see that we are flooding our Terrain let me just float it like that so we have a lot of water patches over here all over the place or you can get it out and just leave the very few bottles over here all right let me just zoom out let me just show you flooding everything and you can create an ocean with it by tweaking the and the parameters of the water normal intensity or you can just take it completely off and this could be places where water was there but it's gone dry places all right so I'm going to turn it off the same thing is for the dirt the grass the stone The Rock and the landscape variation lighting and newbies I'm just gonna start playing with them and get some results and after that I'm gonna show you how you can link up your procedures and spoil them on your terrain so the procedures itself to create is very easy I've created this folder which is called procedurals and you need to right click here go to foliage and create a landscape grass type when you create this landscape grass type this is just the type and you can plug whatever you want in this landscape grass type so let's open the grass when I open the grass here I have a lot of indexes and in this index I just plug my mesh of the grass so if I click over here it will redirects me to this mesh so you just need to plug this mesh over here from the grass density you say how dense the grass will be over here when you tweak this value and here you have a lot of different values for the curling for the scaling Etc this scale X will Define how the grass will be spawned onto your terrain so I want here my grasses to be spawned randomly from 0.5 to 1 and after you create this procedural foliage over here you need to create different procedural graphs for each of the layers that you are creating and then you open your landscape out to material and scroll all the way down to my procedures over here here is the grass and you need just to select your foliage over here and plug it over here so here I have my rocks layer I just plug it over here you can spawn geometry on your snow grass Etc so here you can basically put whatever you want not only grass I put a lot of different flowers and grass in order to mix it up and have this nice little cool effect so this is how I've created my procedurals and before I end up this video I want to let you know that I've created few Unreal Engine 5 courses and if you find any of the topic interesting to you you can go into the description below and check them out and finally if you want one month of skillshare Premium subscription you can find the link in the description thank you guys for watching and happy game development I'm out
Info
Channel: CG Dealers
Views: 119,529
Rating: undefined out of 5
Keywords:
Id: rw8qDmFGsRo
Channel Id: undefined
Length: 174min 23sec (10463 seconds)
Published: Sun Feb 19 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.