Difference between revisions of "Category:FastFiles"

From COD Engine Research
Jump to: navigation, search
Line 18: Line 18:
 
|PC||0x5||0x183||0x114||0x1D9||0x1||0x93||0x135||0x13C
 
|PC||0x5||0x183||0x114||0x1D9||0x1||0x93||0x135||0x13C
 
|}
 
|}
 +
== Pointers in Zone Files ==
 +
Infinity Ward implemented their own way of loading data that can already be found earlier in the zone file. What should be an address in memory is instead stored either as -1 or as an offset. If the pointer is -1, than the data is loaded. When the data is loaded is programatically determined by the function that loads the asset. If the pointer is not -1, the first 4 bits are cleared, leaving the offset as the result. The offset is only correct after the zone file has been loaded in memory. The difference after zone is loaded:
 +
* strings are aligned
 +
* asset headers are stored in pools
 +
* sound, image, and shader programs are stored in pools
 +
* zone header is removed

Revision as of 02:49, 1 January 2014

FastFiles are the CoD engine's way of storing Zone files. FastFiles (FFs) almost always have some sort of RSA2048 signature, a zlib compression along the way, and then on later CoDs some encryption. The Zones are a library of assets. Every FF in every CoD game starts the same way...

struct DB_AuthHeader
{
  char magic[8];
  int version;
}

So by reading the version of the input FF, you can tell what system and game the FF is from.

CoD4 WaW MW2 BO1 MW3 BO2 Ghosts CoD: Online
Xbox 360 0x1 0x183 0x10D 0x1D9 0x70 0x92 0x22E n/a
Playstation 3 0x1 0x183 0x10D 0x1D9 0x70 0x92 0x22E n/a
Wii 0x1A2 0x19B n/a 0x1DD 0x6B n/a n/a n/a
PC 0x5 0x183 0x114 0x1D9 0x1 0x93 0x135 0x13C

Pointers in Zone Files

Infinity Ward implemented their own way of loading data that can already be found earlier in the zone file. What should be an address in memory is instead stored either as -1 or as an offset. If the pointer is -1, than the data is loaded. When the data is loaded is programatically determined by the function that loads the asset. If the pointer is not -1, the first 4 bits are cleared, leaving the offset as the result. The offset is only correct after the zone file has been loaded in memory. The difference after zone is loaded:

  • strings are aligned
  • asset headers are stored in pools
  • sound, image, and shader programs are stored in pools
  • zone header is removed