Ok, almost 150 hits and no reply. I might add a few of my thoughts to start the challenge:
--------------------------------------------------------------------------------
poidata.txt
-----------
mgr.addPoIData( { id="POI_REGION_CANYON", offx=0.000488, offy=0.000977, widx=0.114746, widy=0.438477, screenx=108, screeny=1005} );
mgr.addRegionData( { area="POI_REGION_CANYON", startx=0, starty=19, endx=10, endy=34, richPresenceId=9 } );
quest.txt
---------
position = { 16,33,0 , 1340.650,689.000,1038.390, 23.000 }
position = { x = 97750.00, y = 90400.00, z = 0.00, layer = 0, orientation = 133.000, }
questscripts.txt
----------------
position = toWorldPosition("46;45;-2;1618.900024;18.850000;3301.454834;0.000000")
position = {sx=26;sy=44;sz=0;px=464.632813;py=2857.359375;pz=-100.702850}
print hero
----------
POS(21,27,0 2573.500,842.500,99.674)
--------------------------------------------------------------------------------
Scanning the addPoIData the
- offx/y have a range from 0..1 - scaling factor
- widx/y have a range from 0..1 - scaling factor
- screenx/y have a range from 0..2000 - a map of 2048x2048 units/pixels seems reasonable
Scanning the addRegionData the
- startx/y and endx/y have a range from 0..63 - 64x64 sectors
The offsets could be relative to the sector, so
* sectorwidth/height = mapwidth/height / sectorx/y = 2048 / 64 = a sector has 32/32 units/pixels
* posx/y = screenx/y + ( sectorwidth/height * offx/y )
--> the offx/y is more accurate than the 1/32 (steps of 0.031) would allow
* lenx/y = widx/y * scalex/y
--> assuming 1024 (or mapwidth/height / 2) as scalex/y factor
Although the 2 assumptions are weak the plotted result seems reasonable.
The PosX/Y of the PoI data is more or less accurate
The LenX/Y covers the PoI almost perfectly
see http://miriki.com/www/sacred2/sacred2map.jpg (beware: 20mb for a 12000x12000 image!)
Interesting: Most of the ellipses have more extent in Y than in X direction - different scaling factors? I tried with 1200/900 (4:3) and 1250/750 (5:3) - not that bad, too
The 1st syntax in the quest.txt seems to have SextorX/Y/Z and four unknown float values. Three of them might be offsets again, but what about the 4th then? The orientation is the next line in the script, so it's not the orientation.
The 2nd syntax seems to have the sectors + offsets already calculated into world positions. Those seem to have a range from 0..200000 (found a lot in the 180k region).
So the world might have 204800x204800 (or mapwidth/height * 100)?
The 1st syntax on the questscripts.txt is similar to the 1st in the quest.txt, but it calls toWorldPosition() with the values as parameters.
(The word "toWorldPosition" is found the in the s2logic.dll.)
The 2nd syntax seems quite similar to the 1st one except the missing 4th float value.
The "print hero" syntax, again, seems to be SectorX/Y/Z and OffX/Y/Z. The example shows the position of the hero chest in Schlehenfurt (Sloford?).
--------------------------------------------------------------------------------
Michael