Importing, editing and exporting a Brush with Blender

From Oldunreal-Wiki
Jump to navigation Jump to search

This tutorial is about how to export an original terrain brush from Unreal 227 (UnrealEd2.1 or higher), preparing the ability to edit it in Blender and reimport it in to Unreal 227.

For this tutorial I'm using the terrain from Dark Arena.


Part 1) Intro

Everyone is asking: "How the hell did Epic Games created such terrain brushes for Unreal?" The answer is quite easy, they used external programs like 3dsMax during the development.
With an external 3d program you can easily create outdoor environments like Unreal has with a super fast work flow!
The sad part is most these external 3d programs like 3dsMax and Maya are super expensive and out of range for hobby mappers.

So Blender is the tool to choose.

Part 2) Converting the brush as Static Mesh and export it as .obj

Select your brush by pressing shift on your keyboard and left click with the mouse on any surface of the brush you want to export or select your brush in any viewport.

Right click on any edge of your selected brush and go to Convert/To Static Mesh.
Note: Faces with the flag "Fake Backdrop" will be deleted on your converted mesh.

BlenderBrushImportExport1.png


Save the created Static Mesh temporary into MyLevel, choose any name you want (e.g. DarkTerrain).

BlenderBrushImportExport2.png


After converting the brush to a Static Mesh export it from the Mesh Browser as .obj.

Save the .obj in any folder you want.

BlenderBrushImportExport3.png

Part 3) Importing the .obj into Blender and prepare it for editing

Open Blender and delete the cube which is always in your empty scene. Simply select the object and press "x" to delete it

BlenderBrushImportExport4.png


Now import the .obj over File/Import/Wavefront (.obj)

BlenderBrushImportExport5.png


After you have imported the .obj you will notice that the brush is way to huge for Blenders space. This will be fixed in a few steps later but first you have to join the groups to make it one object.

To do so press shift to select multiple objects in the object list. Move your mouse back to the 3d viewport and press "ctrl + j" to join them.

Note: If a group is selected it has an orange circle around the triangle as visual feedback.


BlenderBrushImportExport6.png


Now scale the huge mesh down by factor 100!

BlenderBrushImportExport7.png

After the scaling procedure the mesh should be completely visible in your viewport.

BlenderScaleDown2.png

Part 4) Editing your terrain mesh in Blender

First change the mode from "Object Mode" to "Edit Mode" to have access to all the editing tools you need.

BlenderBrushImportExport9.png


After switching the mode the mesh should look like this:

BlenderBrushImportExport10.png


Now the fun part begins :)

  • Press "ctrl + v" to clear those cyan looking sharp edges.

BlenderBrushImportExport11.png

  • Press "w" and select "Remove Doubles" to connect all separated vertices to the mesh. NOTE: In Blender 2.8 "Remove Doubles" has been changed to "Merge By Distance"!

BlenderBrushImportExport12.png


  • Press "ctrl + f" and select "Tries to Quads". This turns most of the triangles into squares.

BlenderBrushImportExport13.png


Your mesh should now look like this:


BlenderBrushImportExport14.png


  • Make your changes on your terrain or create your own. If further explanation is required use other tutorials or resources on YouTube on how to use Blender to shape the mesh.


  • After you are done with your changes the terrain mesh needs again its boundary box to project the skybox.

Simply select all four outer vertices on the very end of your mesh.

BlenderBrushImportExport15.png

press "e + z" to extrude them along the Z-Axis

BlenderBrushImportExport16.png

Select the new edges which were created after extruding the vertices along the Z-Axis....

BlenderBrushImportExport17.png

...and create new faces with "f" ...

BlenderBrushImportExport18.png

...and close the top of the mesh.

BlenderBrushImportExport19.png

Part 5) Export from Blender and reimport into Unreal 227

Well done! Now export your mesh over File/Export/Wavefront (.obj)
It is recommended to choose a different name for your exported .obj (e.g. DarkTerrainMod).

BlenderBrushImportExport20.png


Go back into your UnrealEd 2.1 open the Mesh Browser and reimport your edited mesh.

BlenderBrushImportExport22.png


import it into the package MyLevel

BlenderBrushImportExport21.png

After you have imported your modified terrain as Static Mesh select it in the Mesh Browser

BlenderBrushImportExport23.png

Right click on any surface you want and add your Static Mesh to the click location

BlenderBrushImportExport24.png

Select your fresh imported Static Mesh and press F4 to open the actor properties.
Go to "Display" and change the DrawScale up to 100 to restore the original brush size.

BlenderBrushImportExport25.png

The last step is to convert the static mesh to brush :) simply right click on your static mesh and use Convert/To Brush

BlenderBrushImportExport26.png

Part 6) Known Issues and how to fix them

A in Blender created or modified Brush can cause a lot of BSP holes because most of the vertices are off the grid.
To fix this simply right click on your Brush and select under Polygons/Snap vertices to grid.
Note: All vertices of the selected Brush will be snapped to the actual grid size which is set in UnrealEd.

BlenderBrushImportExport27.png

After that procedure its important to move one of the vertex point a bit to reset the brush because UnrealEd does not recalculate the faces aswell.
This will cause loosing your alignments on your brush but its absolutely clean and shouldn't cause BSP holes in your level.
Tip: After your brush is completely snapped to the grid you can export it again and UV unwrap it in Blender to have perfect aligned surfaces.