Log in

View Full Version : [TEC] Texturing for dummies...


padmack
02-06-14, 05:21 PM
Hi

Just a quick shoutout as im trawling through various threads on the topic i thought id attempt to save time by asking about it directly;

Im experimenting with creating alternate textures for, say, the fishing boat or coastal boat - something simple.

In the old days, dropping properly modified .tga or .dds into the data/sea/ship folder did the trick as i remember some ships having maybe 15-20!

i have read SH5 only recognises 3? no worries, thats a bit of variety nonetheless.

Some ships in the sea folder dont even have .dat files. im using OH.

Do i need to edit GR2 files?

Whats the simplest explanation?

THE_MASK
02-06-14, 05:31 PM
S3D maybe

gap
02-07-14, 06:40 PM
1) Units missing a GR2/DAT file: those are the so called "proxy units", using the 3d model of another unit, with different equipment/skins. If you open their cfg file (sea or air folder), you will easily locate the GR2/DAT model they point to:

ClassName=AMCPatroclus
3DModelFileName=data/Sea/NAMC_Rawalpindi/NAMC_Rawalpindi


As stated above, their skin can be customized as for any other unit.

2) Giving GR2 ships new camo schemes, using their AO map. This is where stock sea unit's camoufflages are painted. Figuring out how each pixel in the texture is mapped on the 3d model, can require some experimenting. I strongly recommend you exporting model's AO meshes using TDW's GR2 Editor, and opening them in a 3D application where you can study their UV map. Overlaying the UV map on your custom skin also helps a lot. Once you have fiished with the texturing work, assigning the new AO texture to the model is very easy. Open ships' cfg file (in the roster), and look for her texture definition(s):

[Texture 1]
TextureName=
LightmapTextureName=data/Sea/NAMC_Penguin/Penguin_AO.tga
NormalmapTextureName=
StartDate=19390101
EndDate=19461231
Frequency=1

[Texture 2]
...

[Texture 3]
...



It has been said that we can have up to 3 different textures (i.e. three different texture definitions numbered from 1 to 3) for each unit in each roster. When testing new skins in single mission, I have noticed that the game always uses the first set texture though, no matter what dates and and frequency are set to.

3) Giving GR2 aircraft and DAT ships new camo schemes, using their diffuse map. Stock aircraft and most SHIII/IV ships don't have an AO map, and their camoufflages are painted straight on the diffuse map. This makes the painting process much easier, as their UV mapping is rather obvious. The shortcoming is that diffuse UV maps are often "overlapped" (i.e. the same pixels can be mapped on more than one area of the 3d model), thus preventing complex camo schemes.

The setting up of the new skins is made as before, with the one exception that texture's path is to be detailed as 'TextureName' rather than as 'LightmapTextureName':

[Texture 1]
TextureName=data/Air/AS_USFloatEarlyWar/FloatingPlane_T02.dds
LightmapTextureName=
NormalmapTextureName=
StartDate=19000101
EndDate=19991231
Frequency=1

[Texture 2]
...

[Texture 3]
...


3) Giving multitextured units new camo schemes. Generally speaking, stock ships have one AO map and two diffuse maps, which are shared by more than one model. We have already seen how to create and assign new AO maps, but sometimes editing their diffuse textures as well, can be convenient. Their editing is slightly different, compared to units with just one diffuse texture. Preliminary to the painting work, you need to locate the "standard" textures used on the model. This is done by opening the unit in GR2 Editor. All the textures used are listed in the 'Textures' tab. Once you have located them in the Textures folder, you should duplicate them and add a common suffix to their names (i.e. british, latewar, etc.). Assigning the new textures for use on the model is done as before, but in place of the texture file name, you should put an asterisk followed by the chosen suffix and file extension:

[Texture 1]
TextureName=*mil.dds
LightmapTextureName=data\Sea\NAMC_Rawalpindi\NAMC_ Rawalpindi_AO01.dds
NormalmapTextureName=
StartDate=19390101
EndDate=19461231
Frequency=1

[Texture 2]
...

[Texture 3]
...

4) If the new skins don't show up in game. Each unit's standard textures are hardcoded in her GR2/DAT file. For making them configurable through cfg file's texture settings, their material(s) must be named cfg#TXR*; this make any standard texture to be overridden by the one(s) set in cfg file. For GR2 units, the astesrisk can be replaced with any suffix, whereas for all the DAT units I have seen, the suffix is the name of the main unit node preceeded by an underscore (_). Moreover, DAT material's 'Enable explicit texture' checkbox (S3d), must be unchecked. All in all, the GR2 format seems to be lesser picky than the DAT one, as far as texture assignation is concerned. You can edit material's name and properties through GR2 Editor or, for DAT units, through S3d.

That should be all. I hope I didn't forget anything. Should you need for further assistance, don't hesitate asking :up:

padmack
02-10-14, 06:04 AM
Cheers gap

Thats a great help - its not as different from SH3 as I had feared!

:up:

gap
02-10-14, 06:24 AM
Cheers gap

Thats a great help - its not as different from SH3 as I had feared!

:up:

Not at all. Except maybe for the multi-textured sea units (multiple materials on the diffuse channel configurable trough suffixes), I think the whole system hasn't changed much from SHIV. :up:

Note also that most of the stock aircraft require their material to be renamed in GR2 editor (to cfg#TXRetc.), for accepting new paint schemes.

Don't hesitate asking in case you need for any further clarification :salute: