Wednesday, September 28, 2011

X-Packer Tutorials- Alternate method of doing texture mods using the generic functions

1. Create a directory to store all the files required for the mods. I’m creating a folder called c:\mods\.

2. Copy the character file which you wish to mod into the folder created above. The character file I’m going to be working on is Scorpions first costume and is called “CHAR_SCORPION.XXX”.

3. Copy Gildor’s tools i.e. decompress.exe and extract.exe into the mods folder.

4. Start up a command prompt. You can do this by typing “cmd” into your win 7 search box or in the run command on Windows XP. If you are running Windows 7, right click on the cmd program and select “Run as Administrator”.

5. Type in the following command to navigate to your mods directory: “cd c:\mods”

6. Now we need to decompress the xxx file. Type “decompress CHAR_SCORPION.XXX”. The capitalization is important as the game files are case sensitive.


This will create a folder called “unpacked” with a decompressed version of the file in it.



Navigate to the unpacked folder and copy the uncompressed file into your mods directory. This will overwrite the original xxx file.


You can delete the unpacked folder if you wish, as you don’t need it anymore. I like to keep it so that you have a backup of the original file you are working with.

7. Now we need to extract all the files from the xxx character file. In your command prompt Type “extract CHAR_SCORPION.XXX”


This will extract all the files contained within the xx file into a directory called “char_scorpion”. We need the texture2d files from here. Navigate into the char_scorpion directory. In this directory, there will be a directory called "textures" which contains all the textures we are going to be working with in texture2d format (in my example there are 21 files).



8. Now we are going to create a Table of Contents file (TOC) which lists where all the texture files are stored in the xxx archive. Navigate back to X-Packer and click on Utilities - Generic Injector - Locate Mutliple Files and create TOC file.

First you will be asked to open the main archive file, which in this case is the “CHAR_SCORPION.XXX” file. Secondly you will be asked to browse to a directory where all the texture files are stored, this is the "textures" driectory mentioned in step number 7.

X-Packer will search the xxx archive and create a TOc file for you.




9. Now that we have all the files ready, we can begin working on modifying the textures. you can either extract a texture2d file using X-Packer or work on one of the texture2d files extracted in step 7.

In X-packer select open “Texture2d” file and open the Texture2d which you wish to modify in the xxx file in our example, I want to modify the “Scorpion_Diff.Texture2D” file so I’ll open that. (Xbox users, make sure you select the option under the Xbox submenu).

Click export on the first row. You will be asked to specify a filename for the dds file which will be created. I’m going to call the file “diff.dds”.

10. You can now edit the dds file in whichever application you choose. Remember to save the file as a dxt5 dds file with mip maps. The best way to check if you have saved the file in the correct format is to check the filesize before and after the edit.

11. Click import from the first row and then select the dds file which you worked on previously. In our example this is the diff.dds file. The program will then create a modified texture2d file for you.

12. Open X-Packer and select Generic Injector - Open File with TOC.
You will be asked for to open the xxx character file, in our example this is the CHAR_SCORPION.XXX file.
The program will then display a grid with all the texture2d files in the xxx archive. 

12. Click import on the row containing the texture2d file you wish to replace, in this example the file we are going to replace is the “Scorpion_Diff.Texture2D”. In the open dialog box, select the modified texture2d file and X-Packer will inject it into the xxx archive for you.


13. If you have made changes to any of non dlc characters, you need to edit the filesize in the ps3toc.txt file. Scroll to right of the grid in X-Packer and see a field called “TOCSize”. Click on this and field and press “ctrl+c” to copy the value.


Open the pstoc.txt file and look for the entry for the character file you are modding. In our example this is the char_scorpion.xxx file. Once you locate the entry, the filesize is the value to the extreme left. In this example the value which is currently there is “13762560”. Highlight this value and select edit-paste from the menu. Our new value is “21461007”.

15. You are now done, copy the xxx file and the ps3toc.txt file to your ps3 and enjoy the game.

16. If you are working with the same xxx file future, you don't need to create a new toc file and can open the xxx archive using the Open file with TOC option.

6 comments:

  1. I cannot figure out how to make these awesome tools work for the Wii...please help!

    ReplyDelete
  2. Do i need a jtagged box? very nice work btw.

    ReplyDelete
  3. 1. "Locate Mutliple Files and create TOC file" won't work for me. I'm tring to modify an xbox 360 XXX archive (Rain_ui.xxx).
    I always get:
    File BD_Rain was not found in the archive
    File ladder_b was not found in the archive

    I'm pretty sure they exist in the archive, cause ... i just extracted them!

    2. Is there a way to create a new (xbox360) XXX archive? Using "Mortal Kombat PS3 .XXX Rebuilder" from skorpion2k7 won't do the job for xbox .XXX. Perhaps you could add to the X-PacKer??

    ReplyDelete
  4. @Lee Curtis, yes

    @peoman, try locating each file manually using the other method I posted. You can inject textures into the xbox version of the game using X-Packer, just make sure you use the xbox functions.

    ReplyDelete
  5. Please Tekken I second penman we need a way to rebuild an xbox .xxx file, or explore content like a winrar allowing us to rename files and or extract please could you make it? I will donate for it thanx

    If you decompress and extract Rain_ui.xxx and you mode your dss files then you cannot rename all files to Kintaro_ui.xxx to build your custom DLC this is what we would need, there is something like this please or at least some QuickBMS Script?

    Thanx

    ReplyDelete
  6. @vampirex, there was another tool by a guy named scorpion something or the other. I think his tool does what you need.

    ReplyDelete