UE4 - Tutorial - Niagara Mesh Particles

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello guys and gals welcome to a new tutorial in today's video we're going to be diving into the new Niagara effect system and we're going to be making a cool effect that will take our characters location create a particle system around it and then blow up over time it's a pretty cool effect and it's actually not too difficult to put together and so let's hop straight in we are using version at 4.20 point 2 and if you had to edit and go to plugins head to FX and then turn on both Niagara and Niagara extras now by default these are turned off so you will have to turn these on manually and when you do the engine will restart and it is usual for the engine to stop loading at about 45% this is just because it's loading the new plugins and it's sometimes it takes a little bit of a while depends on your system it could take just a few seconds it could take a couple of minutes but it is still loading so don't close it down to let it load and it will it will catch up so one of the first things that we're going to discuss is the fact that the systems at the moment anyway are different to a particle system if we were to open up a particle system here you can see we have an emitter and this is actually a system if we drop this into the world it does its thing and we can add another emitter and another emitter in another emitter if we wanted to now when we right-click and go to our new FX menu we can select an niagara emitter and we'll call this in mid or and we can't drag this into the world the reason we can't drag this into the world is because it's got no system so the actual particle system has emitters built into the system whereas with Niagara at the moment anyway we have to do it manually so head to effects go to system and we'll call this in system I typically give that a slightly different name I'm gonna put one on the end just in case there isn't one on the unjust in cases because I've been messing around with other systems and I tend to name them all the same thing and delete them and I don't want to accidentally select the wrong one and then you guys won't be able to follow along so if we open this up nothing's gonna be in here if we open up the emitter you can see we have this nice little spray going on one thing that you're going to notice straight away if you hop into this window and drag around is that you have a totally different control scheme to anywhere else in the engine don't know why they've done this it's it's ugly and hideous click this little drop-down menu turn off orbit mode and you get your old control system back I don't know why they've added a new control system in here it's it's it's so disorientating you go around doing everything the same way in here and then you come into one of these things and you're like oh I can't control the thing yours is also gonna have a background so head to window preview scene settings and by default show environments turned on this for me it's way too noisy I can't see this properly so I turn this off so it's more like the old particle system right so our emitter is going to hold our default values and the system is going to allow us to change those values based on what we need so here we're gonna change around at defaults because we already know that we're gonna be sticking these to the edge of a mesh and then blowing them out we're not going to need a velocity so we'll delete velocity we're also not going to need any acceleration force because we're going to have these animated in different ways so we'll delete that spawn rate they're all going to spawn at once attached to our character so we can delete spawn rate because that spawns them over time but then underneath emitter update under this orange so it's all color coded for us now so we're under orange emitter update press the little plus and search for the burst which is what you'd use in the old cascade system but now it's got a slightly different name it's exactly the same thing just head to spawn count change this up and you can see there's just spawned a bunch all here now we're just going to drop down a mr. properties under emitter spawn in the orange no we're not in fact we're going to get to emitter life cycle in the orange ignore me and we're going to say I'm actually count to one because we only want this to happen once once we spawned it a zero is an infinite an infinite loop it will just keep going over and over again so let's see what else will we change here under set variables we're going to go to our sprite size and we're just going to change these between 1 & 2 so we get much smaller dots 2.5 s to 8 is quite large they you'll lose a lot of the detail when they spawn on your character's body so we're going to go for 1 to 2 we'll compile and apply this we'll head over into the system real quick google this just drop it back in there or head over to the system real quick and I'll show you how to bring this in so closest curves what we have here is time line and we have select emitter in the time line but we have no emitter so we will add a track emitter and then we'll pick our emitter you can see it's brought it in along with all of the defaults that we've created so if you see here we've got value 1 to 2 on size and we've got our burst and everything's exactly how we have it in the emitter we're going to want to change a couple more things in the emitter because we're going to need a way to spawn these on our character so to do so we need to get a reference to our mesh hello dog the dogs just attacked me I don't so to do so we're going to need a variable now we can do this through four parameters this is gonna be a particle variable if we open this up you can see we've got a bunch here but none of these are what we actually want so particles little plus um our character is always going to be using a skeletal mesh salsa like skeletal mesh call this part the closed duct skeletal mesh then ctrl a ctrl C we're just going to copy the name cuz we're gonna need that in a short while now if we were to click and drag this you can see here is has set variables a highlight screen this because we can drop this in and it will auto populate a new little menu force you see here default mesh is set to none we're gonna select our mannequin or whatever you're using for your skeletal mesh here and there you go now we have a reference to a mesh however our particle system doesn't know how to use this so what we need to do is right click head to FX again and this time we're going to give this a module script we're gonna call this doing spawn module now call it whatever you want and just make sure it's something you can find we're gonna open this up you're gonna have an error that's fine it's just because it hasn't been compiled yet but what we're gonna do first is in the module usage click this little drop down all we want is a module and a spawn script so we're going to get rid of everything that isn't spawn script or module now we'll compile these things what we're gonna do is head to category and we're going to give this an actual category I'm gonna call this Dean Oh Dean's category now the reason we're giving this a category name is so that we can find this inside of our emitter so if you go back to the emitter we know that this is a spawn because we've just told this here in this module usage to be a spawn script so in our emitter under particle spawn if we press the little plus you can see now we have Dean's category or whatever we've named yours drop this down and you can see here we've got a different modules now this is one from testing earlier you can see here I've got Dean spawn module that's something we've just created so we'll select that now nothing's happening with this right now at all so what we need to do is we need to create a reference to our article variable that's what I'm looking for so we're gonna click particle make new and then skeletal mesh and we're just gonna paste in the name of our variable from earlier this is just so that we know what we're actually working with if we drag out from here now because this is actually a scatter or mesh variable type it's going to default everything to scan our mesh and what we can do is we can get a try coordinate so let's see random try cord and what this is going to do is going to get the coordinate of a random try from on our meshes surface and what we need to do from that is if we type WS for world space we can get try position mod space look cord into cord and then we get a position this is going to determine where to spawn a particle over here we can press a little plus here and we can put article or ition plug in position and there we have it if we compile this now over in our meter did you do where we got it and in spawn module should be working although it's being a little bit of a pain over here we have in spawn module make sure that we've got everything that we need over here we do do we not compile this we didn't compile it what a dope so unless we've compiled it you can see here now it's actually making a little shape of our mesh her a mess shape so what we need to do now is we just need to add that little animation in there so underneath our particle update press Plus and now we're gonna use a force but we're gonna use a cull force noise this is gonna generate a nice little swirl for us now by default it's gonna have this little error and this is because everything inside this Niagara system has to be ordered in a certain way so that things happen in a specific order if you just click fix issue OOP it will rearrange that for you without any problem now if we pop this up to 1,000 strength and give this if we apply it and compile it and head into our system we should see it start flicking around there we go sees I'll be on the nasty we are in orbit areas is over there so you can see he starts as a guy and then it bursts him okay now the higher the frequency the more directions it's gonna fly in so if we put the freaking sweet up to ten and apply this and then head over to our system you can see just kind of bursts in all sorts of directions you kind of lose a little bit of the the nice swirl eNOS so they lower the number the more swirly you're gonna get I like point two okay you see they look at this and I swirl and flick here ready for it here it comes we swell inflator it's really nice looks kind of cool tasty now we don't want that to blow up straight away we want there to be a little bit of a delay so let's see hmm where we want we need our our life did you do a lifetime of our particle now we want these all to last the same amount of time I'm going to put these two a five seconds so now it's all going to take a little bit longer to do its thing but they're going to last for five seconds each now this is under set variables particle start life time you can just search it'll highlight and then you'll be able to find it a lot easier what we're going to do is we're just going to give this a bit of a color where's that color gone there is stop golf all right so what we're gonna do here is we're just gonna double click or we'll right click add key to all curves and we can place these over at the beginning although just lost them now you know what we're gonna do is click these little dots here with a little swirly thing and that's going to let us open up this nice little curve editor so what we can do here is you can see we've got the alpha they're slowly disappearing over time and you can see that that's actually happening here but what we can do is we can change our color if we double click and drag these around let's make these nice and bright like so or actually well then the other way around I want a more blue to match what we had at the beginning see here we've got this nice blue and it fades out over time excuse me well press ok close that curve down and drop this down now we're going to want to do the same thing with our curl noise now by default we don't have a curve available to us so I'm going to click this little drop down and we're just going to search for curve and you can see we get flip from curve and then we can actually have this nice little over the time curve will bring up our curve emitter now I'm just gonna hide all the colors so we only have our strength curve and what we're gonna do is we're gonna say 1 we want the full 1000 so you can see it does its thing there and we'll add a new key to the strength and we'll just say a point mmm a point - we want the value to be 0 so it's gonna have a small delay and then it's going to fly around compile and apply and that should be working over here in our system as well yay and it is and if we were to close this down we drop our system in you can see it works in our world as well so how do we get our character to be able to spawn these well if we open this up we already have it all set here but we're going to remake it again for you just so you can see it I'm gonna say on keyboard e always the default that I use will just delete it from down here you don't need to make any sort of reference to the actual emitter what we're gonna do is we're gonna say spawn system you can see it will already select a Niagara for us we're going to spawn system attached our system template we're just going to drag or actually as I tracked it in yet so we'll take our system here or you can search for any level drop down I've got so many there that are just old broken references we'll grab our mesh drag this down pop it in the attach to component now the location of rotation what we want to do is from mesh get world transform right click split the pin location rotation into rotation compiled make sure that's not a touch deal it's not cool now first play if we run around and we press E it will spawn them exactly where our characters at which is really cool now because this is spawning them based on a try coordinates you notice here that on his chest piece and his fingers are particularly more dense this is because the mesh there is a denser mesh so that it's getting more particles in those areas so this is going to work better on a mesh that has a very a very even wireframe but if the topology is good then you should be fine for him we make is here they're just exploding now this isn't using as many particles as we were using in the original little lamb little demo at the beginning what we can do is we can open up the system we can say tell you what I actually want ten thousand particles to spawn and compile and save press play there's a there we go much more of them and they swell around so there you go guys the first little bit that we've done in Niagara is quite a cool little effect and you can see actually really really satisfying once you get it going hopefully some of you guys will have found that useful and you'll find it useful in your project and no doubt some of you are going to be able to to edit this to suit you in any way let's see how laggy we can get the engine going in fact I found that I only really liked the engine too bad once I've got a million or more articles on the screen which is really tasty foosh but there we go there we go [Music] hopefully some of you guys will find that useful yeah see you guys next time bye-bye
Info
Channel: Dean Ashford
Views: 126,730
Rating: 4.9549518 out of 5
Keywords: Games, Video Games, Gaming, Gamer, Lets Play, PC, Console, play, playing, player, play through, play guide, guide, game guide, dean ashford, dean, ashford, Unreal, Engine, Unreal Engine 4, UE4, Tutorial, Particle, FX, VFX, Student, Teacher, niagara
Id: RWl3ySXTY2c
Channel Id: undefined
Length: 16min 40sec (1000 seconds)
Published: Thu Aug 23 2018
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.