WildFyr Documentation > Blender Tutorials > How to render colourful templates
How to render colourful templates
Object Space Templates
Have you ever looked at templates from GeorgieMoon or Kane and wondered how they get that nice colour? Well today I am going to show you how exactly to do it, and you only need a few items!
What you will need for this tutorial:
- An unlocked car (That is either already templated or you templated in ZMod)
- Blender
- Sollumz Blender Plugin
- CodeWalker RPF Explorer
- A basic understanding of Blender and texture baking
Getting prepared for Blender import
To start off, you want to get your unlocked .yft file. You can either export this from ZMod or use an existing unlocked car. I would suggest using the _hi.yft to ensure you are baking the template on the highest poly version of the car. For this example, I am going to use Raz3r's latest 2023 Tahoe PPV release. After you have your car, open the CodeWalker RPF explorer and import it (I recommend making a new folder and using that for your XML exporting). Right-click on your model and select "Export XML", select a location to put it and let it export (You also want to rename your XML, remove the _hi so it will import correctly).


Importing your XML into Blender
Create a new Blender workspace and go to file>import>CodeWalker XML
(If you do not see this, ensure you installed the Sollumz plugin correctly and it is activated). The first thing you will see after it imports is a giant box, don't freak out, this is simply the vehicle collisions. Open the collection in the hierarchy and click the eye icon on all the collisions, you can delete them if you want, I just prefer t hide them.



Selecting all the body panels
We need to select all the body panels to ensure our UV mapping is correct. Select all the car's mesh and switch Blender into Edit mode. Select a poly that is on a piece of the bodyshell and press Shift+G
and select "Material". This will select everything that uses the paint material and everything we need for UV mapping and baking.



This next part is optional, however I like to do it to ensure my model's base stays untouched. If you want to skip this part jump down after the screenshot. Now we can press Shift+D
to copy this selection, press Z to snap it to the zed axis and move your copied bodyshell to above the car.

We need to detach this mesh selection for the existing mesh, to make anew mesh. Press P
and click selection. Go back into object mode and select the new meshes we just made and drag them out of the car.mesh, into the main collection. Select everything and press CTRL+J
to join them all to a single mesh. Also, make sure "Backface Culling" is enabled in the Viewport shading dropdown.



Getting the UV Map
To get the proper UV map, we will need to select the combined mesh and head to the Data tab, open the UV Maps setting and select "UV Map 1". Then we can switch to UV Editing tab. In the UV Editing tab you should see your bodyshell, switch to wireframe and select the whole model, if the texture window shows you a UV map that looks like a normal template then you have done it right. Click on UV>Export UV Layout, set the size to 4096x4096 for 4K, and the fill opacity to 0, then click Export.





Preheating the oven
Now let's get a little fun, Switch over to the Shading tab and add a new node, Shift+A
search for "Image Texture" and click it. Click the new button to make a new texture for your Object Space Normal Map to be backed onto, set the size to 4096x4096 and the colour to transparent (set the alpha level to 0). Open a new window by draging down from the top left corner of the 3D Viewport and switch this one to "Texture Editor", then select your new texture (It should be blank). Now to bake, first off, head to the Render tab and switch your Engine to Cycles. Baking is currently not supported in the EEVEE engine. Then change the Render samples to 100, this is to make sure the render does not take too long.






Baking the Object Space Normal Map
To bake the map, select your model, and the Image Texture node. In the bake tab, select Normal from the dropdown, and change the space from Tangent to Object. Then click "Bake" If you get an error saying you have initialized images, you will need to delete all the other materials. Head to the materials tab and remove any that are not "vehicle_generic_smallspecmap" then, bake again.



Combining the Wireframe and the Normal map
Open the normal map in your favorite photo editing program, and simply put the wireframe texture over the top. I do feel that is is a little too dark, so I also add a 35% opacity white fill ontop of the normal map. Add your logo and maybe the name of the car if you fancy, and apart from that you are golden! Thank you for reading, and I hope you enjoyed!


Related Articles
Review this page
gtav blender zmod template
1 recommend this page