Tuesday, 15 May 2018

Checking for models

Just as a quick diversion from work I thought I'd look at the .naf files again and see if there was any way to get the models out.
The only real way to do this without knowing the format is to use process monitor from sysinternals to track the read access to the file and then dump it out to be processed.

So we end up with this kind of file where we can see the offsets that are being read from the file and the lengths that are being read. In this way we can work out the things like reads that are lengths of what to read next.

 So then writing some code to parse this file into something useful and look for these length values we end up with output like this.

The big lengths are what we are interested in here and you can see for example a length of 236,900 and 2 reads before it a potential length value of 11,845. If you divide 236,900 by 11,845 you get 20 exactly which suggests that this is 20 byte values repeated 11,845 times. 20 bytes would be 5 lots of 4 byte values. This could potentially be vertices and texture coordinates.

The 42 then 1 then 349680 are the dds files and you can see them increment as they go along.


  1. I respect your hard work! I really hope this broken game can be fixed. Especially the AI: for it's as dumb as can be! xD

  2. hey there and thank you for your info – I have certainly picked up anything new from right here. I did however expertise some technical points using this website, as I experienced to reload the web site many times previous to I could get it to load correctly. I had been wondering if your hosting is OK? Not that I'm complaining, but sluggish loading instances times will very frequently affect your placement in google and could damage your high-quality score if ads and marketing with Adwords. Well I am adding this RSS to my e-mail and can look out for a lot more of your respective fascinating content. Ensure that you update this again soon.. internet marketing strategies

  3. The more you settle the accounts, the less chances of mistakes remain in the end and this site is the main one that solves the problems in the end to overcome the problems.