So I noticed that in scripts/cob.cpp four of the fields in the header are marked as unknown. I had a closer look and here's what I found:
- Unknown_0 is CodeLength in units of 32-bit words (i.e. it's the sum of the sizes of all functions)
- Unknown_1 is StaticVariableCount
Knowing CodeLength means you know exactly how much code to read, so you can make a private copy of the code for the SCRIPT class instead of keeping all the file data in memory and not freeing it afterwards
Knowing StaticVariableCount means that you can allocate the array of statics just once per environment instead of dynamically resizing vectors.
Hope this helps :-)
COB header unknown variables uncovered
Who is online
Users browsing this forum: No registered users and 4 guests