Editing Character Textures for Lazy Louts, and the Technically Inept(like me!)

First off, I mean absolutely no offense by the above post.

I had a lot of help(sorry!!) successfully editing textures with the great tools provided by idolninja, Scanti etc. Since I was planning on documenting this process in it's entirety for myself, I thought I would write a tutorial on editing textures from the ground up for total beginners or people looking for a quick dive into modding this game before really delving into the documentation for more Details.

Files to download (See mod tools section of this forum):
-----------------------
-Gibbed SR3
-SR3TextureUtilities
-Image Editing tool that can use .dds images (I'm an artist and own photoshop, but I saw a post that indicated that you can use gimp, a free opensource image editing program)



Instructions:
--------------------

-- PART 1: Extracting the image files --

1. All of the texture files in Saints Row 3 are compressed into a .vpp_pc file. You will have to extract them from the file customize_item.vpp_pc. Go to:
Code:
C:\Program Files (x86)\Steam\steamapps\common\saints row the third\packfiles\pc\cache

2. drag customize_item.vpp_pc on top of the Gibbed.SaintsRow3.UnpackVPP.exe (part of gibbed SR3 tools mentioned above)
-this will unpack the files into a folder called customize_item in same directory as the file you just dragged.

3. Inside that folder, there are several files with the .cmorph_pc extension, and several files with the prefix custmesh. these files with the prefix custmesh are the files that contain the textures for each item above. I will edit this after making a batch script for to extract all custmesh items, but for the time being you're going to want to extract every custmesh file to find the texture of the item you are looking to edit. (see next step)

4. drag the custmesh file of your choice onto Gibbed.SaintsRow3.UnpackSTR2 (part of Gibbed SR3). This will extract the texture files into a folder in the directory of the custmesh file you just dragged.

5. Inside this folder you will find an file with the extension .cpeg_pc. This is the file that contains your textures. Drag this file onto SR3UnpackTextures (part of SR3TextureUtilities) and it will extract several .dds files into the directory you dragged them from. If you want to keep this directory clean, you might want to create a folder, move the .cpeg_pc file into it, and then extract the .dds files into it.





-- PART 2: Editing the image files --

Okay, you've been patient, now you have some paintings that you can actually edit. Bear with me, and if you're a skimmer and you know a bit about 3D you can skip the next couple of paragraphs. Now I'm going to explain some things about textures in games / other 3D programs. Unfortunately, I'm not familiar enough with gimp to give a good tutorial in it, but these are some basic principles that might help you.

I'm going to use for example the file: cf_nlmb_lbdy_f_skirt_d.tga

there are several files in the directory you just extracted, but these are the files you are primarily interested in:

-cf_nlmb_lbdy_f_skirt_d.tga -->Diffuse Texture
-cf_nlmb_lbdy_f_skirt_n.tga --> Normal Map

texture files for 3D programs use several different maps (paintings) for different things. There is a diffuse map which is the base colours painted onto a model, an alpha on that diffuse which represents the transparency of that texture (black= see through, white = opaque) (you can probably stop reading this paragraph here). Sometimes there is a specular map which is a map that defines the shinyness of an object (how much light is bounced off the object towards the camera -- black=dark white=shiny), there are glow maps, normal maps(affects how light bounces off an object to make it look creased, or more detailed, even if the geometry is flat -- you may want to google this... )

suffice to say, the d stands for diffuse which is the file you will be editing for a simple retexture.

open the file with the suffix _d.tga. You will notice that it is all grey. Saints Row only uses greyscale images, but tweaks the hue and saturation (colour) inside the game engine so that you can change the colour of the clothes in-game.

1. open cf_nlmb_lbdy_f_skirt_d.tga (or another texture with the suffix _d.tga)

2. paint overtop of it in shades of grey (you will be able to add colour inside the game when customizing your character (if you are using gentlemen of steelport) or when buying new clothes (if you are using the game without mods)

3. If you want transparency open the Channels section. Here you will see layers R , G, B, and possibly Alpha1. R, G, and B layers are all greyscale representations of how much Red, Green, and Blue there is in the image, the Alpha1 channel is the transparency layer. Paint in black or dark shades if you want that section to be invisible or translucent (holes, invisible sections around keys, fur, microskirts/tops whatever you are trying to achieve) and make everything you want opaque white.

4. Save your image as a .dds file, and use the same filename as for the actual texture.

5. If you are using photoshop, you will get this gigantic pop-up box. If you are using transparency save as DXT5. If you are not using transparency, save as DXT1. That is all you need to worry about.



-- PART 3: Repacking image files --

Now you are going to need to repack the .tga files into .cpeg_pc/.gpeg_pc files, and then again into .str2_pc files. Also, you will need to update your asm file.

1. copy SR3RepackTextures and the original .cpeg_pc + .gpeg_pc files into the same directory as your cf_nlmb_lbdy_f_skirt_d.tga and cf_nlmb_lbdy_f_skirt_n.tga textures along with any other .tga or .dds files that may have been extracted.

2. Drag your filename.cpeg onto SR3RepackTextures. This should create a new .cpeg + .gpeg file (you can check the date modified if you have doubts, but the cmd prompt will generate an error if it knows it is missing something).

3. if you moved your textures into a working directory, you are going to want to make sure you copy+move or replace the orginal .cpeg_pc/.gpeg_pc files in the folder they started in (with the .ccmesh_pc, .gcmesh_pc files etc.) so you end up with a directory with all of the original files, and your new .cpeg_pc/.gpeg_pc files.

4. now you are going to need to track down the .asm file so you can update it.
- First check your "saints row the third" root folder. If there is already an existing customize_item.asm_pc, copy that to the same directory as the texture files you just edited

- If there is not already a file there, navigate to:
C:\Program Files (x86)\Steam\steamapps\common\saints row the third\packfiles\pc\cache\customize_item
and copy customize_item.asm_pc from there to the same directory as the texture files you just edited.

5. you are going to need a batch script for this next step. open notepad and enter the following code, replacing:

- Kaivai with your windows username
-custmesh_-2104451203f.str2_pc with the proper custmesh file you want to create
- The path with the path to your .tga files, .asm file etc.



Code:
REM param 1 is the file name to save - param 2 is the folder containing the str2 pc files
Gibbed.SaintsRow3.PackSTR2.exe custmesh_-2104451203f.str2_pc C:\Users\Kaivai\Desktop\SR3MOD\customize_item\custmesh_-2104451203f
 
REM param 1 is the asm - param 2 is the folder with the str2 files. . means current folder
Gibbed.SaintsRow3.UpdateASM.exe C:\Users\Kaivai\Desktop\SR3MOD\customize_item\custmesh_-2104451203f\customize_item.asm_pc .
pause

File > Save As
*** When you save the file, underneath the filename change the save as type: to All files

Save your file as filename.bat

Move it to the same directory as:
-Gibbed.SaintsRow3.UpdateASM
-Gibbed.SaintsRow3.PackSTR2

6. Double click on your batch script and if it executes properly, there should be a new .str2_pc file in the same folder as Gibbed.SaintsRow3.PackSTR2. Drag that into your

C:\Program Files (x86)\Steam\steamapps\common\saints row the third

and run Saints Row 3.

7. you're done. Wow that was a lot more long winded than I thought it would be.
 
I followed this as best I could, and it didn't work... I'm not sure what I'm doing wrong. My batch file didn't seem to work for some reason cause it didn't make a new .str2_pc file. I would love a video tutorial of this if possible.
 
I can't find the .asm files. I go to C:\Program Files (x86)\Steam\steamapps\common\saints row the third\packfiles\pc\cache\customize_item but it doesn't exist. Should I try redownloading the game overnight? I don't seem to have these .asm_pc files.
 
I can't find the .asm files. I go to C:\Program Files (x86)\Steam\steamapps\common\saints row the third\packfiles\pc\cache\customize_item but it doesn't exist. Should I try redownloading the game overnight? I don't seem to have these .asm_pc files.

asm files are stored inside of str2_pc files. You would need to extract them first with the tools to access them.

EDIT:
Oops. I didn't notice that you can't find the vpp. It should look like this:

Ne4U2qm.jpg


Are you sure you are sorting your folder by Name?
 
asm files are stored inside of str2_pc files. You would need to extract them first with the tools to access them.

EDIT:
Oops. I didn't notice that you can't find the vpp. One sec.


I can find the vpp, I just can't go further to find the asm like I thought I could. I'll find a tool to extract it out of the str2_pc file; my research hasn't gone too far in learning how to do everything x___x Thanks!
 
I have tried to follow your instructions as closely as possible, but I keep getting stuck where I have to start editing the tga images (the fun part! figures =.=").
I dragged the 'cpeg' file onto the 'R3UnpackTextures' as mentioned. Here are the files that were extracted with the 'dds' files highlighted (01 png)

Like you I dabble quite a bit in visual arts so I'm a photoshop guy but when I try to drag either one of these files in I get this error from photoshop (02.png)


I tried changing the file extention of the 'dds' to 'tga' (I'm willing to admit this might've been a stupid might have been a stupid attempt x/) in an attempt to make it a little more recognisable to photoshop (03.png) but intead it tells be it is unable to 'parse' the file.(04.png)


Can you see where I went wrong. Maybe I'm missing something from the extracted files? Hope you can help
 

Attachments

  • 01.PNG
    01.PNG
    66.4 KB · Views: 1,071
  • 02.PNG
    02.PNG
    59.2 KB · Views: 1,106
  • 03.PNG
    03.PNG
    46.1 KB · Views: 907
  • 04.PNG
    04.PNG
    44.5 KB · Views: 1,146
I have tried to follow your instructions as closely as possible, but I keep getting stuck where I have to start editing the tga images (the fun part! figures =.=").
I dragged the 'cpeg' file onto the 'R3UnpackTextures' as mentioned. Here are the files that were extracted with the 'dds' files highlighted (01 png)

Like you I dabble quite a bit in visual arts so I'm a photoshop guy but when I try to drag either one of these files in I get this error from photoshop (02.png)


I tried changing the file extention of the 'dds' to 'tga' (I'm willing to admit this might've been a stupid might have been a stupid attempt x/) in an attempt to make it a little more recognisable to photoshop (03.png) but intead it tells be it is unable to 'parse' the file.(04.png)


Can you see where I went wrong. Maybe I'm missing something from the extracted files? Hope you can help


same happened with me and i dont know how to fix is:S
 
The texture files are saved as dds files. This stands for direct draw surface and it's the internal format used by direct x.

Your art program must support the dds file format or use a plug-in that supports it. For Photoshop you can download a plug-in from nVidia from here.

Paint.NET, a free art program for Windows, also natively supports dds files.

You can also use a stand alone program to convert the file format. One program I'd recommend is the Compressonator. You can get it from here.
 
Back
Top