Building off my previous post, I want to go into more details how converting the songs to the new engine works.
I originally started because GH Nostalgic and Freg from MiloHax (come join us!) were wondering if the missing Guitar Hero 5 (GH5) and Band Hero (BH) songs could be exported to Warriors of Rock (WoR) with all animations intact. At the time, I didn’t have time to look into it, but promised I would later.
After finishing exams in the middle of December, I started looking into the exports and how they were handled.
Guitar Hero 5/Band Hero
Before I get into the weeds, it would be good to know how songs are set up. Every song from GH5 onward has its data set up like this:
Inside these files there are references to the song as well. For example in the mid.qb file the following strings exist:
The game expects these to be in the qb_key format, basically a hexadecimal representation of that string. “mrroboto_anim_notes” would be FC533C0B for example.
Turns out all exports get internally re-named. I’ve used this example a lot (mainly because it’s at the top of my head), but “Mr. Roboto” in Band Hero is “mrroboto” internally on-disc. However, it becomes “dlc638” once exported (and that’s what WoR expects).
So for the GH5/BH Missing Exports, what I ended up doing was finding out all the parts of the song that reference the internal name (including the file names themselves) and change them to their dlc names. In the example above, “mrroboto_anim_notes” became “dlc638_anim_notes” and the game would look for 5EB9A0D3 instead. Other than the very first song I converted, I didn’t even have to unpack the songs! I could just find and replace all of the hex strings in a single song’s package with a simple replace function in Python.
The audio was the same. It was encrypted using the internal name as an encryption key. So I decrypted all audio, and re-encrypted with the DLC name.
Guitar Hero Metallica
A challenge with the older games was that the file format changed a lot between World Tour (WT) style games, including Guitar Hero Metallica (GHM), and GH5. Compared to the Mr. Roboto example above, here is what WT-era games have:
A lot less.
With GH5 onwards, Neversoft (NS) took out all playable notes and stuck them in the .note file, as well as any camera cuts (and some animation references) were moved to the .perf file. Finally, mocap references were moved to the .perf.xml file.
Luckily in terms of how the data was represented, it was basically the same (just moved around a bit). I ended up writing a program that could parse the .mid.qb file and split it into its individual parts (playable notes, cameras, mocap stuff, etc.). Then it was a matter of building each file like LEGOs into a format that WoR will read.
My first draft turned out all right (with some stuff missing that I’ll get into), but I really wanted to see if the mocap that was present in these older games could be transferred.
What I didn’t show before it that the playable files were inside a “songs” folder in each song’s package and all animation sits outside of it:
Each song has its own animations, which is how NS was able to make a performance for each song unique, and they’re referenced in the files like so:
Basically each animation gets told which player is involved, where they’re located when the animation starts, which camera cuts to use and whether the animation moves their arms, or if they should remain playing their instrument (“slave” means the animation will move their arms, “guitar” means they keep playing during this animation).
In WoR, the same data is present, but moved around. For example, the image above, when converted to a format that WoR will read, now looks like this:
It took a while to figure out, but basically, once you change the mocap data to look like the above, the game will just read it using the exact same animation files from prior games! This was probably the most euphoric part of the conversion process, figuring out that it just worked.
Guitar Hero Smash Hits
Guitar Hero Smash Hits (GHSH) had essentially the same challenges as GHM, but it had a few extra things to do also.
The drum animations were not charted correctly and that resulted in incomplete animations (if you check out my trailer, during Beast and the Harlot you can see the drummer only moving at half time). This encouraged me to create an extractor to check out these drum animations and subsequently make a drum animation parser, allowing me to re-chart the drum animations and inject them back into the song files. I don’t have a custom creator, but I can override any drum animations now if I so choose to!
Another issue was that the missing songs had incomplete metadata on the setlist, as seen by this screenshot below:
Every single song had a duration of 15 seconds and all tiers set to 10. Fortunately, I found out that the GH DLC system is essentially a patching system too. Any data defined in the DLC will be used over data found on-disc. Once I discovered this, I re-defined the SH setlist with the tier and duration values properly defined (and in the case of Through the Fire and Flames, its proper name without the 2nd “the”).
Guitar Hero Van Halen
All the same challenges as GHSH applied here, but another task lay ahead of me. All of the mocap data for Van Halen (VH) songs were in separate files on-disc. I had to adjust my script to grab these files and merge them with the song files and combined with changing the animation references, the mocap just worked as well! It is unfortunate that we can’t get the singer to have a guitar in “Ice Cream Man” or inject the drill into “Intruder” for now, but I will take having the animations in-game!
I may have to disappoint Playstation 3 (PS3) users though. As of writing this, I have yet to be able to convert the VH songs because there is a file size limit on PS3. A song file can only be about 9MB or else the PS3 will hard crash. Most Van Halen songs are well above 9MB with some even reaching 17MB, nearly double what the PS3 will read:
The limit may have to do with the PS3 splitting its RAM. There’s 256MB dedicated to RAM, and 256MB dedicated to VRAM as opposed to the 360’s 512MB of just RAM. The 360 just chewed through these files, so I have no idea if there’s a size limit for it.
Guitar Hero World Tour
A unique challenge approaches me for porting the World Tour songs as it’s currently the only game I’ve yet to port. Unfortunately, the animation files are slightly different. They’re compressed in a way that WoR will not read them anymore. When it tries, animations became hilariously disfigured. Please see this link: https://streamable.com/e/tzp293
As of writing this, I have some ideas as to how to import them, but for now, it’s not possible. Fortunately, if I do crack it, it’ll be fairly straight forward to port it, no tier changes are needed and drum animations look properly charted.
I look forward to being able to convert WT songs for everyone to enjoy in the future! I am making some good progress, so I hope it will be sooner than later. Catch you on the next one!
Leave a Reply