Jump to content

FARC Files and Pokemon Models


evandixon

3759 views

Since the release of Pokémon Super Mystery Dungeon, it has been unknown how a proprietary archive file called FARC linked filenames to files. It functions like a hash table, where the game gets a filename somehow, does something to hash the filename, then corresponds that with a file. Until recently, the somehow and something have been unknown. Editing files in these archives required either putting up with the lack of filenames, or somehow knowing which filenames corresponded to which hashes. A little over a month ago, I discovered the something was a simple CRC32 hash. While I previously tried this hashing algorithm, I was unaware that in the files I was testing, the somehow involved appending a ".bin" file extension to the end of a file. While it is not possible to determine the filenames of files, it is possible to infer filenames from other parts of the game, and use coding and algorithms to match them to the appropriate file. Knowing how to do this makes it possible to do so much more with Pokémon Super Mystery Dungeon.

The first practical application of this was updating Sky Editor's starter editing project to replace placeholder Pokémon portraits with the default emotion. This makes it so that when one plays the game as a non-standard starter, the game no longer shows emotions like surprised without the face of that Pokémon.

The next practical application that is planned is to start substituting certain story-related models. For example, right now, when a non-standard Pokémon sleeps in a bed, the default attack animation is used instead. The player Pokémon just can't get a good night's sleep apparently. I hope to change that soon by substituting that animation with the sleep animation used in dungeons. If model behavior in Ohana3DS is any indicator, things should work out well. That is as long as the correct animation is used. Things can get amusing if the wrong one is used:

image.png

A Zorua, using Riolu's walking animation

While seeing this in-game will take more work, I've have a new build of Sky Editor that comes with support for extracting pokemon_graphic.bin with all the filenames. This is only useful for researchers or those who want to play around with models with Ohana3DS or SPICA or something. Basic instructions can be found here, and look for the new PsmdPokemonGraphicsProject project, which can repack the pokemon_graphic.bin file for anyone who's brave enough to try manual model edits. Download it here.

[Edit] Updated the build link to fix a memory leak. I don't think I mentioned it before, but you'll need 1-2 GB of free RAM because using all the RAM makes things go like 10x faster. I didn't do any actual measurements, but that's what it feels like at least.

Edited by evandixon
Fix links

0 Comments


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...