So hai. Here's a shiny new tutorial. I'll be showing you how to replace a hair here, but it's basically the same for clothes. You can replace hairs the same way you replace clothes, but it's more tricky because you have to deal with differences in the amount of groups. So here's a fail-proof way.
I'm going to make this friends-only for now, just to see if it's any good. Beware, this is way different from the other tutorial, so it may take some time to get it right.
What you'll need:
- Something to replace
- Something new to replace it with
- SimPE
I'm going to replace 'HairHatCowboyUpFlat' with some braids I found, by
stakeit_uk,
here.
So this:
Will hopefully end up looking like this:
OK. First off, you need to know what the piece you're trying to replace is called. So check in the
default database or make a quick recolor in bodyshop and open that in SimPE (see
tutorial no. 1).
Start up SimPE and open your Scenegraph Resource Finder. Put 'Find:' on 'PropertySet Search' and 'Type:' on 'Contains [match]'. Type the name of the hair you're replacing, in my case HairHatCowboyUp.
Now find all the hairs you want to replace. There might me multiple ages. You don't have to replace all ages or even all the hair colors.
Sometimes your finder will find the files in multiple Expansion Packs. Choose property sets from the latest EP can find.
Mine only has an adult mesh, but there are usually different property sets for the young adults. Don't forget to replace those as well. Open one of the files you want to replace.
You're going to need the property sets and the 3D ID referencing files. To get these as quickly as possible, first sort by name and select as many of the files you'll need. Then sort by Instance.
Now scroll along and use Ctrl+click to select all the 3D ID referencing files that have the same instance number.
After you've selected all of them, right-click one of the selected files and choose 'Extract...'.
Be sure to put them in a separate folder which you can find later on.
Do the same for the property sets and 3D ID referencing files of the other ages.
Now open a new file, right-click in white space and choose 'Add...'
Add all of the property sets and 3D ID referencing files you've just extracted.
Now would be a good time to save your file
Next, empty out all the 3D ID referencing files. You do this by selecting it and (in plugin view) deleting everything that's in it. Be sure to commit after deleting everything.
After you've done this for all 3D ID referencing files, save.
Now open the mesh file of the hair you're using as a replacement.
Now delete everything that belongs to ages you're not using. In my case, everything but the adult mesh.
And save that as a new file.
Now extract the cres and shpe files
And name them something you'll recognize.
Also, open the gmdc to check how many groups the mesh has.
In this case, there are two; hair and hairalpha5. Whoops, forgot to check the polycount beforehand... it's 18474, as you can see. That's kind of ridiculous...
Open the replacement file and add the cres and shpe files you've just extracted
Now select a 3D ID referencing file and click on 'package'
Now drag the cres (resource node) and shpe (shape) into the space you've emptied out earlier. In that order, so make sure the resource node is at the top. Commit.
After you've done this for all 3D ID referencing files (of the correct age!), delete the shpe and cres files and save.
Now, open a property set
OK, as you can see, there are a lot of things you may need to check.
Category (dtUInteger): This shows the clothing categories the hairs shows up for. In this case, the original shows up for everyday only (check the codes
here). To make a hair show up for all clothing categories, change the value to 0x0000137F.
numoverrides (dtUInteger):This shows the amount of groups your mesh has. Change this value to the amount of groups your mesh has, in this case it's the same, 0x00000002.
If however, your mesh has more groups than the original, after changing the numoverrides, you need to do something else. Select the override0shape and choose add.
Do the same for override0subset and override0resourcekeyidx. Change the number '0' to the next number, in this case '2'
Change the other two 0's to 2's as well.
override0subset (dtUInteger):This shows the names of your groups. Change them to match the the names of the groups of the new mesh. Commit.
override0resourcekeyidx (dtUInteger):These refer to the place of the TXMT files in the 3D ID referencing files. 0x00000002 means line 3, 0x00000003 means line 4, etc. Set the override0resourcekeyidx value on 0x00000002, set the override1resourcekeyidx value on 0x00000003 and so on.
Finally, if the property sets come from the basegame, you need to do something extra. Add a line called version to the set
Change the value to 0x00000002 and commit
Select the property set again and add a line called product
Change that value to 0x00000001 and commit
Do this for all the property sets and save.
Now, open one of the recolors of your replacement hair.
Extract the TXTR file and the TXMT files that refer to that TXTR file. You'll only need the TXMT files of one age. Also, in this case there's a TXMT file for a group called hairalpha3, which isn't even in the mesh, so I didn't extract that one.
To keep things clear, put them in a separate folder.
Do that for all the recolors; black, blond, brown, red and grey.
Now open the replacement file and add the TXMT files of one of the recolors
As you can see, I added the black TXMT files. So find the 3D ID referencing file that matches the instance value with a property set of a matching hair color. Click on package
Drag the TXMT (material definition) files into the 3D ID referencing file. Remember how the hair group had resourcekeyidx value 0x00000002? That means it's TXMT goes on line 3 here, above the TXMT of hairalpha5. Check the instance (high) values to make sure you put the files in the right place. Commit.
Match all the black 3D ID files with the TXMT's and then delete the TXMT files
Do the same for the other recolors.
After all the 3D ID referencing files are filled up again, add all the TXTR and TXMT files to the file
And finally, add the mesh.
Save and check in bodyshop.
Success!
Let me know if it works for you, too!