UE3 Custom Static Meshes

6 Comments

In a slight change to plan I am going to move the subject of player direction to tomorrow, and today I am going to be giving another tutorial in Unreal Engine 3; Namely how to Export a 3D model from 3Ds max and import it into a Unreal Engine 3 game.

Again I am going to be using Unreal Tournament 3 as my UE3 engine game, but this process is mostly the same for all UE3 games.

3Ds Max:

I will go over some basic tips of 3D modelling in 3Ds max at a later date; In this tutorial we are simply going to export our model from the program. For this we need a model.

I have built a Box and used the UVW mapping tools to create a layout for my texture, creating this:

3D Model

Its not especially pretty, but it will let us go through the procedure and check that it all works and the mesh saves the material co-ordinates.

I now have a 3D model and a .TGA image file which i have built as a texture for the model.

Exporting:

With the box selected, go to File > Export > Export Selected (in newer versions of 3Ds MAx the ‘File’ menu is now accessed by clicking the Max logo in the top left corner of the screen).

Choose a file name, select to save the file in ASCII Scene Export(.ASE) format and save the file somewhere on your hard drive; Once you click save you will get the following dialogue box appear:

ASCII Scene export dialogue box

The ASCII Scene Export dialogue box

This step is the most likely point to make a mistake; you need to be sure you are exporting all the correct information to your new .ASE file; duplicate the settings in the image above if you are unsure.

Important Note: Make sure you have ‘Mapping co-ordinates’ ticked in Mesh options. Without this selected, your mesh will loose all its texture data and you will be unable to apply a material correctly to it once you have it in Unreal Engine 3!

Once you have the settings sorted out, click ok. Max has now exported your 3D model into a file that Unreal Engine 3 can understand. The next step is to import the model into the game.

Unreal Engine 3:

Open up the Unreal editor program for your chosen game: in my case this is Unreal Tournament 3 editor.

When we import content into Unreal Engine games, we organise it into packages. We want to keep content organised, but do not want to start mixing custom content into the packages that came with the game.

In the generic browser select File > Import. We now navigate to the folder where we exported the .ASE file from 3Ds Max.

Select the .ASE file and click import. This will bring up the import tool; Here you can choose where you are importing the mesh to, the mesh name and which group the mesh is a part of. I used the following settings:

UE3 Import Settings

Import settings I used in UE3 Game

Click OK and wait; depending on the complexity of the mesh, the game could take a moment to import it.

Once it has imported the model, you will be returned to the Generic browser; if you are not already looking at the package you imported the model into, select the appropriate package from the content browser (Remember to make sure you have ‘All Resource types’ selected) and you should see your model is now available as a static mesh.

Texture and collision:

First problem you may notice is that the model says ‘NO COLLISION MODEL’ underneath the preview. Second issue is the lack of texture currently applied to the model.

The model has no texture as the game needs to import and apply the appropriate texture to the model; when you exported the model, you save the texture ‘co-ordinates’ not the actual texture, into the .ASE file.

Go back to File > Import and this time find the .TGA texture file you created for the model. You want to save the texture into the same package as the model ideally, Give it an appropriate name and then you can leave the rest of the settings as default.

Note: If you have a normal map to import, this is done in the same way, but under ‘CompressionSettings’ select ‘TC_NormalMap’ from the drop down.

Once the Texture has been imported we need to make this into a usable material; right-click on the texture you have just imported and select ‘Create New Material’. This will make a blank material in your current package with the texture you have just imported ready to be used within it.

A new material should appear, but it will look entirely black. Double-click the material to bring up the material editor; This is an incredibly comprehensive material editor; but for now we are just going to do a simple change.

move your view around so you can see the ‘Preview_Material’ box (Grey box with a list of texture settings) and the Texture_Sample that contains the imported texture.

What you need to do is drag from the ‘Diffuse’ setting of the Preview_Material to the Black square on the left side of the ‘Texture_Sample’. All that sounds very confusing, so here is what you want to achieve:

Material Editor window

Here is what you want to achieve in the material editor

Once you have achieved this close the window; the editor will ask if you wish to apply changes – Click yes and the material will ‘save’. Make sure you save your package as well, otherwise you could loose your work still.

Now in the generic browser you should see that your material is no longer blank, but shows the texture you imported. Now we just need to apply the material to the Box model.

Double click on the box model to bring up the static mesh editor. In here you can view a static mesh and change a few of its settings.

On the right-hand side of the window you will see a list of properties of the static mesh; under LODinfo, expand [0], then Elements and finally [0] again. In the properties that you can now view, there is an option called ‘Material’. If you still have the generic browser open, you can now select a material, or press the magnifine glass in the material box to bring up the generic browser.

Select our new material; with it selected go back to the static mesh editor window and press the green arrow in the ‘Materials’ property. This will apply the current selected material in the generic browser to the static mesh.

Note: When ever you see [0] it means that there is an array of properties; depending on the model you may find a list [0][1][2][3] etc… if this is the case, you just need to apply the correct material to each element.

Now we should have our mesh textured, we need to sort out the issue of no collision model.

On the top menu, there is an option called ‘Collision’. if you click it you will see a list of Collision types. choose the first one from the list ‘6DOP Simplified collision’. this will apply a simple collision around your object. It will not be suitable for complex modes, but for simple meshes like ours, it will suffice nicely.

final result - imported custom static mesh

The final result. from 3Ds Max to Unreal Engine 3

Now close the Static mesh editor and click in the generic browser and you should see an updated preview of your mesh; textured and no longer saying ‘NO COLLISION MODEL’. You now have a usable custom static mesh in your game.

If you, or you know somebody, are a talented 3D modeller, you can now create completely custom level designs, no longer limited to the packages of static meshes that came with your game.

Conclusion:

In this article we learned how we can export a model from 3Ds max into .ASE format and then import that .ASE file into Unreal Engine 3. This will be vital if you wish to create truly original and exciting content for players; nothing is more exciting than seeing new content in a level.

The next step is to begin learning how to make the most of this, by learning basic 3D modelling skills, and making more interesting static meshes into your game.

Hope this helped you out, remember to come back to VG_LevelDesign soon for more Tutorials, Tips Tricks and Theory!


6 Responses to “UE3 Custom Static Meshes”
exercitii pentru slabit Says:

Like your page, good reading, thanks.


Fonda Says:

Superb contribution, great webpage template, stick to the good work


Aja Lidstone Says:

Aw, this was a really great post. In theory I’d like to write like this also – taking time and real effort to make a good article… but what can I say… I procrastinate alot and never seem to get something done.


mmog Says:

Your use of such emphatic words in your article shows an intense excitement in what you are trying to convey. Keep up the good work! I will most definitely insert a link to http://www.vg-leveldesign.com/ue3-custom-static-meshes/ on my site.


Hotels in Zurich Says:

I was very encouraged to find this site. The reason being that this is such an informative post. I wanted to thank you for this informative analysis of the subject. I definitely savored every little bit of it and I submitted your site to some of the biggest social networks so others can find your blog.


tiguan review Says:

Great page. I would like to write my own site about this topic, but i have to many sites in the hopper at this moment. :\ I did however link to your webblog from mine here http://www.vwsuv.net/sites-we-like/ hope it helps you get some more traffic!


Leave a Reply