Firstly, thanks for your answers.
Secondly, I don't really know what I'm talking about ... this is just what I think from hours of tedious analysis, but here goes:
When you say extra texture levels, what do you mean?
In v56 you get 10 stratum layers but pre-v53 you get 8
See Map.vb:282 from HazardX's code.
Don't know if you know, but textureMapData is an image ... you divide each pixel into its ARGB channels ...
the A channel is used to represent how much (0 = 0%, 255=100%) alpha the texture from stratum1 should be drawn on that coordinate.
the R channel = how much alpha from stratum2
the G channel = stratum3
the B channel = stratum4
Then, there is a whole new image - TextureMapData2 ... which is also divided into ARGB channels where ARGB map to stratums 5-8
In pre-v56, the second image (TextureMapData2) isn't loaded at all.
You can also see on map:224 where additional layers are loaded from v56 maps - which are the stratum themselves.
In v56, It seems as though to me that there are 10 stratums but only 8 have texture maps. I understand this for Lower stratum, because its the bottom layer its always at 100%. But whats going on with 'Upper' stratum? Haven't looked into this.
Anyway it would be interesting to know how many of our maps actually use new features from v56 ... because if they don't we could just downgrade them all to v53 to get contour maps back. I've downgraded a few maps already (you just have to change the minorVersion) and they work fine but perhaps there is some subtle difference that I am missing.
The LUA code reads the other map files (scenario, script, save), but the code that loads the scmap format is internal to FA.
Thanks for this. Is there somewhere in LUA where it gets an object reference to the map? If so just looking at that class definition would surely help...