project reality header
Go Back   Project Reality Forums > PR:BF2 Mod Forums > PR:BF2 Community Modding > Modding Tutorials
09 Sep 2024, 00:00:00 (PRT)
Register Developer Blogs Members List Search Quick Links
Modding Tutorials Information and tutorials related to modding BF2.

Reply
 
Thread Tools Display Modes
Old 2016-03-13, 23:03   #1
Ratface
Retired PR Developer

Ratface's Avatar
Post Static Texturing Mini-Tutorial

Hello, guys! I had made this for the ww2 forum so I thought I'd add it here, too for those who are wanting to learn how UVing works with BF2. This basically follows the same ideas you'll see in Rhino's tutorial seen here: https://www.realitymod.com/forum/f18...ml#post2121844

The difference between UV mapping statics vs. dynamic models is that typically dynamic models have their own texture sheets (which are created after the model has been UV mapped), whereas statics typically work off of many texture sheets that are premade, which must be mapped to. I will cover the latter.

First, we start off with our completed mesh, a basic wall.



Now, what we want to do is start setting up the our material. Typically, we want to use a total of 2 materials in max: one for the actual textures, and one for the collision mesh. We start by selecting a material and changing it from Standard to Multi/Sub Object. This allows us to fit many materials inside of this single material, and texture our object using different material IDs, which I will explain next.



What we will do, once we've selected the Multi/Sub Object for the material, is to determine the number of materials we think we will use. We can change this at any time. In this case, I will only be using one material, which will be made up of 6 different parts (coming next). To show as an example, I have two materials shown. If I wanted to use a separate set of textures for another part of the model (for a building, let's say doors), I could change the polygons to material ID 2, which would make it use the second material in the Multi/Sub object material. In this case, we will just use the first, so we make sure to select all polygons, go the the "Material ID" section on the right, type "1", and hit enter.

WARNING: By default, material IDs can be fairly random. If, let's say, a polygon's material ID is 8, and we only have 2 materials in the applied Multi/Sub Object material, the export will either crash Max or the polygon will become invisible in the engine after export. BE SURE TO ASSIGN ALL POLYGONS!



Now, once we have our Multi/Sub Object material set up, we can go to our first material by clicking on it on the list. For BF2 statics, we must use the BF2 Static Object material (see highlighted below), which is given by the POE2 tools I believe. Change the material type to this.



Alright, so let me quickly explain the 6 types of material types:

-Base: Also known as the color material, we use this to give the base color to an object. Typically, we'll see textures that are meant for this end with "_c.dds", for "color".
-Detail: This is where we add our details such as brick, concrete, etc. This adds a layer on top of the base layer to give, go figure, more detail . We typically see textures meant for detail to end with "_de.dds".
-Dirt: Similar to detail, this layer goes above the Detail layer and typically is used to provide grime, but can also be used to add posters, etc. We typically see textures meant for dirt to end with "di.dds".
-Lastly, we have NDetail and NCrack. These are meant to give "3D-ness" to the 2D textures. We don't worry about mapping these because they are meant to be paired up with NDetail and NCrack, and copy their UV maps. If the detail or crack maps you are using have a normal to go with them, you can select them here.

To apply these, you will want to click on the buttons on the left have side, browse for the texture sheet you want to use, and then select it.

AS A QUICK ASIDE! When choosing your materials and texture sheets, try to choose those which have a good balance of both detail as well as variety. For example, if you can find a detail texture sheet that contains both walls, windows, and doors on the sheet, try to map all relevant things to this sheet. This way, you don't overload on too many materials (meaning one material for the walls, one for the doors, etc.). This is important because the more materials equals lower performance, especially in an urban environment!



For this example, let's use the mecity_01_c.dds (found in objects\staticobjects\_middle-east\city\textures\mecity_01_c.dds) for the base color of the wall.

Similarly, we'll use mecity_02_de.dds for the detail, mecity_01_di.dds for the dirt, and mecity_01_cr.dds for the crack layers, all found in the same directory. We'll browse for all these and add them.



OK, so from here,we will do the UV map for the base color. First, apply the UV modifier and select all faces. For this, I unclick the "normalize map" checkbox, and click the "box" UV option. From these, hit "Edit". In the top right corner you'll see a dropdown box. Click this, and hit "Pick Texture". Browse your way to the same directory your base color was at and select it. It should show up on the UV map screen.

From here, just select your faces and take them where you will to give a good texture to your model. Easy as that!

NOTE: If the texture sheet seems shrunk, hit "options" in the bottom right of the UV map window, and uncheck "use custom bitmap size". This will allow you to see the texture sheet properly and allow you to map to it better. Takes a little bit of practice but it gets fun when you get used to it



So, now we'll do the same for the rest of the material parts. To do this, collapse the UV map modifier to the object, and apply a new UV map modifier. To access the next texture sheet to UV it, under Parameters, under Channel, change the "Map Channel" to 2. This will allow us to work with the second, and likewise, the third, fourth, etc.

NOTE: Only work with one channel per modifier! As soon as you finish with one channel, collapse the UV modifier and apply a new one, then change the channel!

From there, repeat as you would with the base color layer. Your UVs will be screwed up initially for the model, but that is because we are working with a new layer that hasn't had it mapping done yet!

NOTE: For these other textures, they have an alpha map that only allows certain details to come through. For an example, on a crack map, you will only be applying the crack details, not the actual detail color, etc. that may be in it's background.



So, to speed things up, here is the detail mapped...



The dirt layer mapped...



And finally the crack layer mapped...



Now, we'll set up the object for export, export it, and open it up in BFMeshview! This is what we end up with:



There we go! Obviously it takes more work and more material types for a larger object such as a house or a church, but the same principles apply, just with more materials!

Let me know if I missed anything and I'll edit it in, thank you

Ratface is offline Reply With Quote
Old 2016-03-13, 23:55   #2
W.Darwin
Banned
Default Re: Static Texturing Mini-Tutorial

Great! Genious! Much appreciated! Gracias!



[edit: Everytime I try to export my models to BF2 this is what happens, '' C:\Users\Line\AppData\Local\VirtualStore\Program Files (x86)\EA GAMES\Battlefield2\mods\bf2\Objects\staticobjects\ '' Why?

I had to look up my Hard drive to find that the Object are exported in this place? Why do they not just export in the /programfile (86) ?? ]




Rhino, This is a edit, I didn't find the use of making a new post but, HOLY TARP! I had to figure this out how?? I was stuck at this point in your old tutorial for 2 days D: It was written no where

The post below was answered to this question:

I cannot find the way to load my texture in the material map/browser help!

W.Darwin is offline
Last edited by W.Darwin; 2016-03-14 at 03:15..
Reply With Quote
Old 2016-03-14, 02:40   #3
Rhino
Retired PR Developer
Supporting Member

Rhino's Avatar
Default Re: Static Texturing Mini-Tutorial

Select Bitmap, then browse to the texture.

Rhino is offline Reply With Quote
Old 2016-03-14, 02:58   #4
W.Darwin
Banned
Default Re: Static Texturing Mini-Tutorial

Well, i will post a new reply still, Thanks! hehe, but now my 3d model export in the wrong files. I think I can still export them Manually inside BF2editor thou
W.Darwin is offline Reply With Quote
Old 2016-03-14, 03:06   #5
Rhino
Retired PR Developer
Supporting Member

Rhino's Avatar
Default Re: Static Texturing Mini-Tutorial

1, you shouldn't remove stuff from your posts when editing, that could have helped someone in the future with the same problem....

2. the exporting part of this tutorial explains it: https://www.realitymod.com/forum/f18...structure.html

3. you shouldn't ask things unrelated to a tutorial in a tutorial topic.

Rhino is offline Reply With Quote
Old 2016-03-14, 03:16   #6
W.Darwin
Banned
Default Re: Static Texturing Mini-Tutorial

Copy! Wont happen twice.
W.Darwin is offline Reply With Quote
Old 2016-07-12, 04:47   #7
Kiaksar2142
Default Re: Static Texturing Mini-Tutorial

Its really useful tutorial =) Thank you!
will try to texture the bridge (not destroyed one) from BF2142 =)
Kiaksar2142 is offline Reply With Quote
Reply


Tags
minitutorial, static, texturing

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



All times are GMT. The time now is 09:33.