- Site Map >
- Modding and Creation >
- Sims 4 Creation >
- Modding Tools >
- (Released as download) Combined XML (and Binary Tuning) Extractor
- Site Map >
- Modding and Creation >
- Sims 4 Creation >
- Modding Tools >
- (Released as download) Combined XML (and Binary Tuning) Extractor
Posts: 2,671
Thanks: 62690 in 190 Posts
The latest version of this program is now hosted in the Programs and Utilities download section here at MTS. You should go here to obtain it in the future.
Old Info...
Version 3.2.3 adds comments cross-referencing any XML files. Like the string table comments, this will only be performed when doing a full extract from the game install folder. The full extract will now also unpack a full build for a package if no delta build is available (new game packs that have never been patched).
Note, there was a big nasty bug in version 3.2.2 so if you downloaded that be sure to update to 3.2.3.
Version 3.1 will include the strings from the string tables in XML comments. This is only available when doing the full extract. It will load the strings from all the game string tables, index them, and dump a tab-delimited text file while it's at it. Including the string tables will take a bit extra time, but it's tough to say just how much as I ran my tests back to back and so a lot of data was still cached in RAM. I mean I can't even estimate, because the test including the strings ran a second faster. If you have a reasonably fast machine though, you will probably miss the "Extracting and indexing strings" message if you blink.
Version 3 can now process all the game XML in a single run. No more converting to binary files, then XML, and finally producing the XML extracts. Select the main game folder (it should find it automatically from the registry) and create a new empty output folder, hit extract and go for a short break. The program will find all of the SimulationDeltaBuild0 packages in the game, pull the binary tuning out, convert it to a combined XML file, and finally extract them into separate named folders, BG, EP01, etc. The temporary files are left behind in case you need them (you can still work with the individual files).
For good measure, I replaced that crappy .Net folder selector with a version that uses a common dialog.
As of version 2.0 the XML Extractor can now convert a binary tuning file into the combined XML format. The input file should be a .bnry file extract from one of the games delta packages. The binary file will be loaded and a new file written to the output folder with a .xml file extension. Expect this to take some time, but it only needs to be done once for each of the binary tuning files at each patch level. Once the combined XML has been output, it can be processed further to extract into individual folders and files.
I have written a short tutorial on using the XML Extractor.
Browse for the input file. If the input file has the .bnry file extension it will be processed as a binary tuning file and a combined XML file written to the output folder with a .xml file extension. Any other input file will be treated as a combined XML input file. If an invalid file is specified the program may crash or produce invalid results.
Select an output folder, select the game pack (this will occur automatically if a "standard" file naming is used) and click extract.
Sources are also attached, made in Visual Studio Express 2013 (VB .Net) if someone wants to change it to do something fancier.
The program requires the .NET v4.0 framework to run.
v1.0.1 - Bugfix - wasn't processing the Module instances (tun folder). Didn't update the sources, it's a really easy fix (see comment further below or PM me if you can't find it).
v1.0.2 - Additional Bugfix, the Module type number was generated wrong (thanks for pointing that out Fogity). Also made the application a bit more responsive while it's extracting (output won't hang, you can reposition the window, the buttons get disabled and if you click the close button it will prompt to exit or cancel).
v1.1.0 - Autodetects the game pack/group number if input file is named properly, all known packs are coded in
v2.0.0 - Convert a binary tuning file to the combined XML format. Added name for GP02. (Sources updated with the new code)
v3.0.0 (unreleased) - Pull the binary tuning out of a package file.
v3.0.1 - Full auto mode using the SimulationDeltaBuild0 package files found in the game install folder.
v3.1.0 - Added option to include the string table strings in the XML output when doing a full extract.
v3.2.2 - Added option to include XML cross reference comments.
v3.2.3 - Bugfix - program would crash when extracting a single combined XML.
TS4 Combined XML Extractor_src.rar (56.5 KB, 316 downloads) - View custom content | ||
----------- --------- -------- ----- -------- ----- -------- ---- I.A.... 1698 516 30% 21-08-15 01:55 1B4AA0D1 TS4 Combined XML Extractor/TS4 Combined XML Extractor/App.config I.A.... 15160 3488 23% 21-08-15 19:45 806F66D7 TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsBinaryTuningConvertor.vb I.A.... 1940 748 38% 21-08-15 03:32 533914A6 TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsCombinedCrossrefTable.vb I.A.... 2832 998 35% 21-08-15 03:11 5FAE4270 TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsCombinedStringTable.vb I.A.... 6466 1908 29% 18-08-15 16:55 59761D4A TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsFolderBrowser.vb I.A.... 24070 3995 16% 18-07-15 03:10 CC2B19BB TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsSimDataFile.vb I.A.... 6518 1350 20% 18-08-15 13:21 C6FEB02D TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsTS4Package.vb I.A.... 7145 1489 20% 19-08-15 09:50 D64538D7 TS4 Combined XML Extractor/TS4 Combined XML Extractor/clsTS4Resource.vb I.A.... 12280 2192 17% 21-08-15 01:57 11913341 TS4 Combined XML Extractor/TS4 Combined XML Extractor/frmMain.Designer.vb I.A.... 6219 1605 25% 21-08-15 01:57 1939E7C3 TS4 Combined XML Extractor/TS4 Combined XML Extractor/frmMain.resx I.A.... 20795 4092 19% 21-08-15 22:48 EE3F08FD TS4 Combined XML Extractor/TS4 Combined XML Extractor/frmMain.vb I.A.... 1532 708 46% 20-07-15 19:35 8249EAFE TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/Application.Designer.vb I.A.... 471 274 58% 07-05-15 21:23 D0C01F1A TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/Application.myapp I.A.... 1205 583 48% 21-08-15 22:48 00E99629 TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/AssemblyInfo.vb I.A.... 4106 1222 29% 20-07-15 19:35 80D8F35E TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/Resources.Designer.vb I.A.... 6187 1605 25% 03-07-15 03:43 676250D4 TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/Resources.resx I.A.... 6459 1262 19% 21-08-15 01:57 CA71B415 TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/Settings.Designer.vb I.A.... 1226 374 30% 21-08-15 01:55 41AF2B3F TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project/Settings.settings I.A.... 501 252 50% 18-08-15 11:53 DC238BE8 TS4 Combined XML Extractor/TS4 Combined XML Extractor/Settings.vb I.A.... 5993 1563 26% 21-08-15 02:26 78A06D58 TS4 Combined XML Extractor/TS4 Combined XML Extractor/TS4 Combined XML Extractor.vbproj I.A.... 143 140 97% 07-05-15 21:34 4459DF5D TS4 Combined XML Extractor/TS4 Combined XML Extractor/TS4 Combined XML Extractor.vbproj.user I.A.... 3628 389 10% 18-08-15 01:30 8BE2451A TS4 Combined XML Extractor/TS4 Combined XML Extractor/xmlGPData.xml I.A.... 927 393 42% 07-05-15 21:34 0842C36B TS4 Combined XML Extractor/TS4 Combined XML Extractor.sln I.A..H. 90112 9331 10% 18-07-15 04:42 F212C62E TS4 Combined XML Extractor/TS4 Combined XML Extractor.suo I.A..H. 202240 14275 7% 21-08-15 22:48 984F666D TS4 Combined XML Extractor/TS4 Combined XML Extractor.v12.suo I..D... 0 0 0% 21-08-15 22:48 00000000 TS4 Combined XML Extractor/TS4 Combined XML Extractor/My Project I..D... 0 0 0% 21-08-15 22:50 00000000 TS4 Combined XML Extractor/TS4 Combined XML Extractor I..D... 0 0 0% 20-07-15 19:35 00000000 TS4 Combined XML Extractor ----------- --------- -------- ----- -------- ----- -------- ---- 429853 54752 12% 28 |
||
Description: Source code (v3.2.3) - Visual Basic .NET project | ||
TS4 Combined XML Extractor_v3.2.3.rar (26.7 KB, 823 downloads) - View custom content | ||
----------- --------- -------- ----- -------- ----- -------- ---- I.A.... 78336 27222 34% 21-08-15 22:48 80947B05 TS4 Combined XML Extractor.exe ----------- --------- -------- ----- -------- ----- -------- ---- 78336 27222 34% 1 |
||
Description: Current version |
Thanks
Posts: 11,006
Thanks: 422688 in 1121 Posts
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 102
Thanks: 2407 in 18 Posts
Posts: 4,471
Thanks: 3629 in 16 Posts
Posts: 2,671
Thanks: 62690 in 190 Posts
Thank you, especially for providing the source |
Wasn't sure if anyone would be interested in the source, but glad some folks are finding it useful. It's fully uncommented, lol, but pretty straightforward. If anyone has any questions about what it's doing I'd be glad to follow up on them.
Mostly it's just a quick n' dirty something to get going while waiting for Fogity to make a far better tool, which I believe is close from the last post I remember seeing, so I didn't want to throw too much time at the code (like error checking, or comments).
Posts: 102
Thanks: 2407 in 18 Posts
Posts: 125
Posts: 2,932
Thanks: 15563 in 28 Posts
Please do not PM me with mod, tutorial, or general modding questions or problems; post them in the thread for the mod or tutorial or post them in the appropriate forum.
Visit my blogs for other Sims content:
Online Sims - general mods for Sims 3
Offline Sims - adult mods for Sims 3 and Sims 4
Posts: 2,671
Thanks: 62690 in 190 Posts
scumbumbo is your code derived from the source posted by velocitygrass or did you start from scratch? If it's the latter I shall split off the last couple posts into a new thread -- it might be confusing otherwise, particularly in case someone also starts to fiddle with velocitygrass' work. |
@plasticbox - Sure, might be a good idea to split it off as it's not the same tool. The code is from scratch.
Posts: 130
Posts: 4
Posts: 11,006
Thanks: 422688 in 1121 Posts
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 92
Thanks: 3799 in 5 Posts
So, @itsclarkkent, forget about velocitygrass' tool as it's obsolete, it doesn't extract the files correctly any more, specially the ones from the packs.
Posts: 11,006
Thanks: 422688 in 1121 Posts
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 2,671
Thanks: 62690 in 190 Posts
the /tun directory remained empty..., could this be due to a bug? |
Yeah, looks like I wasn't processing the Module ndoes in the XML that are used by the tun category so those files were skipped. I've uploaded a fixed EXE. Ran into the same issue doing the Tuning Description Browser and fixed it there so knew right away when I saw your post what the issue would be.
I didn't update the sources because it's such an easy fix, so for anyone playing with those just change the if statement in the for loop of ProcessFolder as so:
For Each nCurrent As XmlNode In node.ChildNodes If nCurrent.Name = "I" Or nCurrent.Name = "M" Then ProcessFile(nCurrent, strTG) End If Next
ETA - Sources have been updated with the v1.1.0 update
Posts: 125
Yeah, looks like I wasn't processing the Module ndoes in the XML that are used by the tun category so those files were skipped. I've uploaded a fixed EXE. Ran into the same issue doing the Tuning Description Browser and fixed it there so knew right away when I saw your post what the issue would be. I didn't update the sources because it's such an easy fix, so for anyone playing with those just change the if statement in the for loop of ProcessFolder as so:
Code:
For Each nCurrent As XmlNode In node.ChildNodes If nCurrent.Name = "I" Or nCurrent.Name = "M" Then ProcessFile(nCurrent, strTG) End If Next |
I haven't looked at your code or used your program, but I think you might have another "bug" now.
For module tunings the resource type shouldn't be calculated in the same way as the other tunings, instead the value 0x03B33DDF should be used.
Posts: 11,006
Thanks: 422688 in 1121 Posts
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Posts: 2,671
Thanks: 62690 in 190 Posts
I haven't looked at your code or used your program, but I think you might have another "bug" now. For module tunings the resource type shouldn't be calculated in the same way as the other tunings, instead the value 0x03B33DDF should be used. |
Thanks, I'd never noticed that. I'll fix that and get it uploaded yet tonight. Won't be a major change.
For those who've already done the extract and don't want to remove the tun files and reprocess - if you have Cygwin, here's a quick BASH command line you can run in that folder that will rename all of those files.
for fname in *; do mv $fname ${fname/266CA322/03B33DDF}; done
I had no idea where to look on the EA fora as I don't go there ever.
Where did your MTS uploads go? https://s2idownloads.blogspot.com/2...content-no.html
Contact me here: www.facebook.com/sims2idea
Overview all my creations: Download at once (SimFileShare)
Posts: 11,006
Thanks: 422688 in 1121 Posts
Stuff for TS2 · TS3 · TS4 | Please do not PM me with technical questions – we have Create forums for that.
In the kingdom of the blind, do as the Romans do.
Where did your MTS uploads go? https://s2idownloads.blogspot.com/2...content-no.html
Contact me here: www.facebook.com/sims2idea
Overview all my creations: Download at once (SimFileShare)
Posts: 327
Thanks: 11306 in 18 Posts
I was wondering if it works with SPs, since there is no option for SP01 or SP02.
Posts: 2,671
Thanks: 62690 in 190 Posts
Amazing! Thank you, scumbumbo! I was wondering if it works with SPs, since there is no option for SP01 or SP02. |
It should, I've never unpacked those as I don't have them. The only thing that option button does is to set the Group number in the TGI, so if you unpack the SP stuff with the BG selected it will just assign group 0x00000000 and you'll have to change that manually if required for the mod. I'll have to add buttons for the new SPs. Maybe not today, maybe not tomorrow... but soon.
Posts: 327
Thanks: 11306 in 18 Posts
It should, I've never unpacked those as I don't have them. The only thing that option button does is to set the Group number in the TGI, so if you unpack the SP stuff with the BG selected it will just assign group 0x00000000 and you'll have to change that manually if required for the mod. I'll have to add buttons for the new SPs. Maybe not today, maybe not tomorrow... but soon. |
Got it, I just need to rename the files after extracting, that's pretty okay for me. Thanks again! :D
Locked thread | Locked by: plasticbox Reason: See Downloads > Tools! | |
Who Posted
|