Difference between revisions of "JohnnyEnglish tutorial Creating a new Urt5 map"
(→Chopping your mesh) |
(→Chopping your mesh) |
||
Line 45: | Line 45: | ||
[[File:Tut06.JPG|300px]] | [[File:Tut06.JPG|300px]] | ||
+ | |||
+ | ===Please note=== | ||
+ | Having a lot of small parts in your final map may hinder the performance, the biggest performance hit are the '''load calls''', these load the elements that need to be drawn on every frame (textures, mesh, effects) and construct what you will see. This is balanced by the complexity of the things which are loaded, so you will need to balance the number of items loaded with the complexity of what is loaded. It may be better to have 5 relatively simple objects loaded than to load a single one 10 trillion triangles object. Objects that do not need to be loaded (culled) will obviously improve performace, so a long wall might be split into several smaller sections to aid that culling. |
Revision as of 11:20, 9 August 2021
If you wish to follow along with this tutorial, I have provided a Blender file and a few other items in a single zip file available HERE (NOT YET)
Starting out
Firstly, I'm going to assume you have a fully tested idea for a map, perhaps you've previously built a rough version and tested it on Urt4 and now you want to build it. For this tutorial I decided to make a map very much like dressingroom, a small 2x2 fun map, mirrored.
This tutorial will not teach you how to use Blender or any other 3d tool, but what I demonstrate should be transferrable as a technique to whatever tool you decide to use.
Blank page
Because I know how large I want the map to be I generally start with a 2d version of the map in blender, start with a plane and extrude it around to get the basic layout. I work with measurement unit's in centimetre.
Eventually, the 2d shape can be extruded to make walls, then ceilings and roofs constructed, as a single mesh or as multiple parts, whichever is easiest.
Personally, I like to test out my work in a game environment early on during development, your views may differ, you may decide to perfect your map before moving it to the next level but I prefer to know in advance of adding detail of any problems so I can change them easily with relatively blocky work. For me mapping is very much an iterative process, I know version 1 will look terrible and that version 32 will look outstanding. The workflow between your 3d editor (Blender in this case) and UE4 is such that it encourages this iteration so that updating mesh with more detailed mesh is relatively simple.
I would suggest working your map to this level of detail and no more before proceeding to the next stage (chopping up)
Chopping your mesh
I'm sure there is a more technical name for this process, I have no idea what it is, I call this part of my process chopping.
What that means is that I have a pretty 3d model in Blender but it's not really suitable to be used in UE4, here's why.
UE4 needs to know how to apply textures and lightmaps to the mesh you create. UE4 needs to identify a material slot in your mesh (or multiple materials), for this example I'm going to keep things simple and treat each part of mesh with a separate material as a single item.
So, for example. A part of mesh which will be brick will need to be separated from the parts which are the window frames, and those parts will need to be separated from the glass. You should also consider that the default lightmap size per mesh is 64x64 pixels, that is to shade a 2mx2m object.
Understanding these things will help identify how to break down your model into separate parts, it's generally guess work and after some practice you begin to appreciate how large to make your parts.
In this case I've decided I want this wall to be a single mesh part with a rough plaster or concrete render, I want it to be separate from the base part and I would like a decorative border along it's top edge, so I separate this part.
So I can see clearly, I'll generally hide that separated part.
I repeat this process until I've chopped the entire mesh into sensible parts. I can later refine these parts, but as you can see from this screenshot, each part has a different colour.
Please note
Having a lot of small parts in your final map may hinder the performance, the biggest performance hit are the load calls, these load the elements that need to be drawn on every frame (textures, mesh, effects) and construct what you will see. This is balanced by the complexity of the things which are loaded, so you will need to balance the number of items loaded with the complexity of what is loaded. It may be better to have 5 relatively simple objects loaded than to load a single one 10 trillion triangles object. Objects that do not need to be loaded (culled) will obviously improve performace, so a long wall might be split into several smaller sections to aid that culling.