Unreal Engine Tips You Might Not Discover Quickly On Your Own

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
so i'm an unreal developer and i have a game development discord where unity developers often end up sharing their unity trauma things that they don't like about unity which is how i find out about these things and lately a lot of unity developers are talking about jumping ship and learning unreal and i think that's a good idea for 90 of them but there's one major issue with learning unreal which is that it doesn't teach itself very well this is the most you know featureful engine out there but it doesn't necessarily tell you any of its features exist you need somebody to tell you so this is a quick video of a bunch of things you might not find out about unreal if nobody tells you in no particular order first important thing that people miss is the gameplay framework so this is your game mode your pawn that's p-a-w-n game state player controller ai controller camera user interfaces and huds all that sort of stuff it's set up in a particular way in unreal that is a good nice and generalized way you know this is how it worked in you know mirror's edge mass effect batman xcom all of those unreal games uh use the same basic state so it's not something that's prescriptive about what kind of game you're making what kind of perspective you're using anything like that but it gives you a lot of tools that you are going to need for whatever kind of game you're making you don't want to try and go around this and not use it you really don't if you look at the documentation some of it might look like it's specific to like a multiplayer deathmatch game or something like that here we've got something about the number of players and spectators present as well as the maximum number of players and spectators allowed so this is just in the abstract yeah there's a spectator built into unreal because unreal supports multiplayer out of the box but this is definitely the basic framework you're going to want to use whether you're making a point-and-click adventure game or a third-person shooter or a rts or an rpg or anything all right next thing the first thing i get anybody to do when they open unreal for the first time is go to window developer tools class viewer this is a window that used to be built in in since unreal one just automatically in the right hand side and it's valuable because this shows every class in your project or in the engine even with inheritance so i was talking about the gameplay framework this is useful because it lets you see inheritance i've got a pawn class here called influx ball and here if i find it i can see that its parent is porn and the parent of pawn is actor now i know that actors are a type of pawn player controller i also have one of those player controller has a base class just called controller controller has children called ai controller and player controller this is just useful to have there you can also just right click on a class and open it from here so it's just useful to have and you'll sort of passively learn about things that you might not have known were in the engine something else that's important is if you press till you'll bring down the console you have a console if you type stat fps that shows your frame rate you press stat unit that shows you how long each thread is taking gpu draw game etc there's many stats scene renders for memory audio the stats for everything um if you type toggle all screen messages that hides the lighting needs to be rebuilt thing that you probably have on your screen most of the time and there are many many many other cvars even if you add your own you can get a list of all of them including those ones by clicking help up here and then console variables that'll just an htm file that contains every siever a description of most of them and you can search it for instance if i type grass bring up any sea levels to do with grass next thing is don't underestimate blueprint blueprint is the visual scripting language it looks like this it's elaborate and good it's the equivalent of unreal script in ue3 which is to say it's not as complicated as going straight to c plus and you should be doing most of your stuff here until it becomes apparent that you shouldn't don't go straight into learning c plus to learn unreal just learn blueprint it's really good it can get a little messy but it doesn't have to next thing if you press g it toggles to game view which is simply just hiding everything that would be hidden in the game so here i've got some kill triggers if you fall out of the level you hit this trigger and die i've got other triggers i've got a bunch of debug items if i press g they'll go away and i can see how the game will look when i'm playing next thing is show flags and view modes so show flags are just you have a bunch of types of object in your scene you can show or hide them specifically for instance if i were to show mesh edges you can see the edges of my meshes supposed to hide static meshes half the scene go away you can hide particles you can hide fog view modes are here under lip and there are keyboard shortcuts for a lot of them i'm on lit right now we can go to unlit brush wireframe detail lighting lighting only player collision so this is everything that collides with the player in the scene we have buffer visualizations and you can even tweak the exposure just of the editor camera we have static mesh and skeletal mesh leds built in so if i drag this bridge mesh in i'll right click on that go to edit here we are in the static mesh editor and you can see that we have this led setting up here you can see that i'm on lod2 right now it's got 7000 tries if i go to 0 it's actually got 28 000 tries which is quite a lot um and we've reduced it to 7 to 14 000 and then to 7000 and we could go further and it'll just generate these i didn't author any of these leds i have a whole video on how to do that if you check my channel we also have automatic generation of convex collision models so if i go to simple here this is an automatically generated crappy convex collision i can make it a bit better by just generating one that's quite a lot better you can tweak it to get better results you can also use complex collision which is where you collide per poly with the mesh this is potentially expensive if it's a high poly mesh but you can collide instead per poly with a crappier lod this saves the memory that you would have used holding onto convex collision meshes there's also a view mode that lets you visualize which leds are currently in use if you go to level of detail coloration view mode localization is also kind of built in and unreal so if you were in blueprint or anywhere at all and you created a string variable that wouldn't localize but if you made a text variable or in c plus that's f text and you compile you get this little drop down here which sets whether it's localizable or not it defaults to true so any user facing text you want to be f text not string or not name to actually work with that stuff you go to window localization dashboard and all your localization tools are in there you can also localize assets so say you had a static mesh that was a sign that had some text on it maybe you would right click on it and go create localized asset and then you would import sort of a french version of the sign or something like that next thing is bulk edit via property matrix at some point you're going to want to change a bunch of files at once in some specific way you can go into the content browser find the files that you want right click asset actions bulk edit by property matrix and this just shows every editable property on all of those assets you can select just certain ones you can select all of them you can pin a property so that you can then sort by that and then you can just change those values over here so that's particularly useful when you have a bunch of textures that you want to audit for some value like whether they're streaming or not whether they're mipping or not they all need to mip because you don't want to waste texture memory but they might not all be for instance if they're power of two you will have never stream ticked on them and then you want to investigate those assets here we're all fine something i want to point out while i'm here is texture groups when you import a texture you should assign it a texture group and this is quite important or at least it will be later on but what this is going to let you do later on is use device profiles to identify which textures are which so that you can load them down on other platforms for instance on the switch here i have my world text just going down to 512 pixels what that means is there might be an 8k texture on pc but when i package the switch it's going to crunch it down to 512. then my normal maps i figure they need even less detail they're going down to 256. specular 256. character textures different from world decals we have decals on unreal uh you can do anything with them that you can do with a normal material you can move them around they can influence the different buffers differently you can have ones that apply to normal you can have ones that don't uh so you could have you know a uh a decal that's a crater and then you could layer on top of that a decal that is blood and have the normal of the surface actually look like the blood is sitting in the crater not just sort of haplessly lurking on top some more keyboard shortcuts if you press end the thing you have selected falls to the ground if you hold l and click on a surface you create a light there if you hold control l and click on a surface you create a light in the color of that surface there's mesh painting right in the editor so you can just paint a vertex color onto your mesh in this case due to some project specific setup my grass kind of looks bad here but you can ignore that and you can in your material just use those to mask by whatever you want or you can just use the vertex color directly and also paint directly to a texture with that tool the material editor is incredible and you should get into it as soon as you can even if or even especially if you're not a shader person a lot of the point of it as i see it is to expose shaders to non-programmers since this is really an art task and it's surprisingly intuitive once you basically understand what a pixel shader does you can do all kinds of things in here something that's important to know about materials is don't just make a new material for everything there's material instancing so for instance if i open this material real quick create a value that's to color i can make it a parameter this is a parameter plug that into color i'll make it green and i apply say i want a pink room now i don't just go make another material that has pink i right click this material create material instance open it and i can just adjust the color right here and i can just go ahead and apply that to whatever object i want there's also a foliage tool so you can just spray down a bunch of rocks and grass or really you can spray anything it's called the foliage tool but it's just an asset sprayer tool you can even spray actors so if you wanted you could paint down a bunch of trees that you can then chop down or just paint a bunch of npcs into your levels by default there's something called the filmic tone mapper built in and this is sort of a physically accurate tone mapper if you just import some like 2d sprites you might find that this messes up the colors on them a while ago they said they were going to remove the non-filmic tone mapper as an option but they never did it so i got to think they changed their minds if you type r tone mapper film zero in the console you'll switch to the old non-filmic tone mapper and if you type r i adaptation quality zero basically you just wanna disable the eye adaptation that goes the rest of the way obviously my scene doesn't look good like that because i built it for the scenic tone mapper if you have a light and you're after a little bit less of a physically correct falloff you want a bit more artistic control you can select that light and disable your head full off and then you can manually adjust the falloff exponent of that light which if you set it to zero is like a comic bookie sort of immediate fall off at the edge of the light on the spotlight you can adjust the inner and outer cone radius i gather on some of unity's pipelines that wasn't possible by default a point light is just a point but if you give it a radius say 32 and you can even give it a length you can create a tube light you can also do erect light it's a rectangle light you can adjust all the angles and that something else you can do with lights is light functions which is just a material that basically scales the light by the intensity of the material here i'm using it to make some fake caustics so unreal has multiple light bakers for static lighting this one used light mass there's also gpu light mass they're similar they just bake your light maps to you know a light map and they get similar results but they're not quite the same this is my light map resolution density for dynamic lighting there's also multiple different angles you can take on that from what i hear unlike in unity uh all of these systems sort of cooperate so you can do raytraced shadows and distance field shadows and just shadow maps and virtual shadow maps and all that sort of thing together if you want to on static lighting you might be wondering about light map uvs these are generated on import and they're usually completely fine obviously free to create your own light map uvs but the generated ones have always been good to me the exponential height fog actor just makes fog it can be volumetric if you want but it doesn't have to be density of the fog is controlled by height so if you actually change the height of the actor you can see where the fog settles so this means you can have low-lying fog you can have a separate higher fog and yeah you can have volumetric fog the volumetric fog even works with light functions i showed you before this is my caustics light and i've turned on volumetrics on it something that's a little bit more boring but still important is auto instancing came in 422 so uh for instance if you have these two rocks which are exactly the same these three rocks which are exactly the same they just count as one mesh draw called whereas it used to be three you don't have to do anything for this to happen it just happens so if anything changed about one of these for instance if i vertex colored one of them differently to the others that's a new draw call but any copies of that are just the same one it's possible i'm getting something wrong about this but uh long story short it means you can make a big forest and it just isn't as many draw calls as you'd think by a lot um they would took my maps down from like 20 000 draw calls in some cases to like a thousand it's pretty crazy if you select something and press h you hide that thing in the editor you can do that with a bunch of things and if you press ctrl h it brings them all back there are also more visibility settings under here show only selected show all actors something else visibility wise to be aware of is you can set something to be hidden in game and it'll show in the editor but it's hidden in the game i have it on game view so it's invisible this is useful especially things like triggers if you make anything like that yourself these are triggers they don't show up in the game that's as compared to the visibility flag which would just potentially make a thing completely invisible it wouldn't even show up in the editor it still shows up in the outliner so that's how you would get it back multiplayer is very much built in whether it's local same screen split screen networked so as an example if i right click here and play from here i'll just drop into my game and if i type debug create player in the console sorry debug create player 1 i create a split screen player and that's just another person that's in my match so i type it again i get another one [Music] and i didn't have to do any code to support that you can just do that now if i want to do networked multiplayer testing i can actually just enter a number of players here and when i press play unreal will automatically spin up multiple clients and connect them to the server [Music] there are two systems for making particle effects in unreal one of them is cascade that's been around since like unreal 2 and it's being deprecated the new one is niagara they're both better than you would get in most other engines but use niagara it's nice and new these fish were done in niagara speaking of particles there's a cool system called particle cutouts where instead of just drawing a square quad it'll actually automatically cut out around the part of the texture that actually contains anything and you save a little bit of pixel cost versus just drawing a big square quad this isn't necessarily an amazing example something you should make sure you read the documentation for is collision filtering just such that unreal collision filtering you'll get the dock here i've got this stag mite set up to block everything except the camera so when the stalagmite passes between me and my camera it doesn't pull the camera in if you know what i mean here's an example something to be aware of is that if you have multiple actors that respond to each other differently for instance if a pawn is set to block a physics body but the physics body is set to ignore pawns the engine always goes with the least collide response so that would be ignored and nothing would happen unreal has a concept of splines built in and you can use these for all kinds of things and you can trivially even use them to spline meshes so for instance if i keep adding points to this spline this bridge is just going to keep on curving and this is easy to set up you can do you know any number of things with this um this is a little bit expensive to render so before you ship with this you should merge the result into a single mesh to merge it you can just right click on it and go to merge actors this brings up the merge actors tool and you can use this for all kinds of things it's got different ways of merging so you can make a mesh out of all of these but still using the same single material or you can actually sort of harvest these whatever components might be on this actor and combine those into a single texture like an atlas texture all kinds of things up next to the play button here you've got a little arrow one of the options is simulate simulate just starts the game without putting you into it so if i for instance make a bunch of physics boulders and press simulate and those all fall to the ground i can grab one and move it just as if we were in the editor and in fact i can then if i grapple i pressed shift e by the way to select all of the same mesh and i press k that'll keep the changes from the playing editor session and when i stop that's just where the actors are now also when you're playing in the editor running around you can press f8 at any time to jump out that's called unpossessing the pawn and you can just fly around and move stuff just like you're in the editor something else to look into is data tables if you're storing a bunch of data in your code classes which includes blueprints you might want to think about whether it's better off in a data asset or a data table a data table is basically a spreadsheet that uses a struct that you made as its row so for instance here i've gone for checkpoints this game has checkpoints uh it's got the name of the checkpoint what music track to play what music track to play when that track finishes if the first one wasn't a looping track uh what special abilities should be unlocked at this point etc and i've got the music tracks themselves tabled i've even got my main menus driven from a data table you can use this for all kinds of things so for instance if you had a weapon system you might end up wanting to use a data table to specify different weapons then you end up with a situation where a designer only needs to add a new row to a spreadsheet in order to actually add a new gun to the game that looks different and behaves different i'm not really going to bother demonstrating this but somebody mentioned the other day that unity generally needs you to roll your own standing on a moving platform code unreal has built-in character classes and character movement component classes that handle that something else to be aware of is console ports on other engines you often end up getting a third party to do your ports you probably won't do that on unreal because it's very easy to put your games to another console if you're a gamer watching this don't take that to heart i'm talking to game developers okay it's much easier than you would think so for instance device profiles that i went into earlier they make it so much easier to get your project down to spec you will never need to create a copy of your project that's the switch version and then keep those versions in sync for instance i did the audio support for switch recently it's a third person game it's reasonably pretty it's not a big game but it still only took me a week that's you know that's not a lot of time for a port main thing i'm driving at here is for instance if you look at fortnite that's on android ios xbox playstation switch probably other stuff they just have one project for that and it's not just because they're immensely rich it's also because they built these tools to allow them to do that stuff with relative ease if somebody adds a feature on ios somebody doesn't have to separately add it on playstation 5. so don't immediately go looking for porting houses when you've made an unreal game and you don't really want to think about putting on on switch it is possible depending on your game that you just do it in a week that's probably not going to happen but it might you're in that realm so every time unreal developers get together we tend to exchange tips and everyone finds out some that they wish they had known for years so this is what this video is kind of trying to avoid hopefully this has been useful to some of you and if it has maybe i'll do another one sometime because there is a lot more of this i also just encourage you to go through all the drop down menus and all the right click menus because it's not great that all of these things are hidden in nested drop-downs but there are there is some really good functionality in there so good luck can you unreal engine users once you're past the initial hump of finding out where anything is you should be a lot happier here
Info
Channel: Joe Wintergreen
Views: 22,089
Rating: undefined out of 5
Keywords:
Id: VhYDqkTqZPg
Channel Id: undefined
Length: 20min 12sec (1212 seconds)
Published: Sat Jul 02 2022
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.