*some* linux offsets

develop
Petr Mrázek 2010-05-20 06:50:16 +02:00
parent 5da1e1a75f
commit 25b6c99628
2 changed files with 312 additions and 97 deletions

@ -1540,11 +1540,10 @@ map_data_1b60_offset 0x1B9c
==== ====
<Address name="current_tick">0x0e47e08</Address> <Address name="current_tick">0x0e47e08</Address>
<Address name="current_year">0x0e79f00</Address> <Address name="current_year">0x0e79f00</Address>
</Entry> </Entry>
<Entry version="v0.31.04" os="windows" id="0.31.04" base="0.31.03" rebase="0x0"> <Entry version="v0.31.04" os="windows" id="0.31.04" base="0.31.03" rebase="0x0">
<String name="md5">aa</String> <String name="md5">655a895c5b90d15eb9bb71e28c6c62e5</String>
<HexValue name="pe_timestamp">0x4bf014fa</HexValue> <HexValue name="pe_timestamp">0x4bf014fa</HexValue>
<Address name="creature_vector">0x167870C</Address> <Address name="creature_vector">0x167870C</Address>
<Address name="dwarf_race_index">0x1471FBC</Address> <Address name="dwarf_race_index">0x1471FBC</Address>
@ -1616,15 +1615,236 @@ map_data_1b60_offset 0x1B9c
<Entry version="v0.30_04" os="linux" id="30_04lin" base="meta-2010"> <Entry version="v0.30_04" os="linux" id="30_04lin" base="meta-2010">
<String name="md5">1d759a11af258263ef5c139d6d9a3e15</String> <String name="md5">1d759a11af258263ef5c139d6d9a3e15</String>
Basic things
============
<HexValue name="sizeof_vector">0xC</HexValue>
<Offset name="vector_triplet">0x0</Offset>
<HexValue name="sizeof_string">0x4</HexValue>
<!-- most probably a static object, because its parts are often
referenced as offset to this address *and* as addresses -->
<Address name="WORLD">0x0</Address> 0x0165B188
Position and window dimensions
==============================
<Address name="window_x">0x8cd3b18</Address> 0xe32798
<Address name="window_y">0x8cd3b1c</Address> 0xe60838
<Address name="window_z">0x8cd3b20</Address> 0xe60814
<Address name="cursor_xyz">0x8b17370</Address> 0xae82cc
<HexValue name="sizeof_vector">0x10</HexValue> <Address name="window_dims">0x9464d6c</Address> 0x17f5ab8
<Offset name="vector_triplet">0x4</Offset> GUI State
=========
<Address name="pause_state">0x92c971c</Address> 0x146e45f
<!--
Bogus: <Address name="current_cursor_creature">0xae82cc</Address>
<Address name="current_menu_state">0x017f6f38</Address>
Bogus: <Address name="view_screen">0xae82cc</Address>
-->
Map stuff
=========
<Address name="map_data">0x9322d20</Address>
<Offset name="map_data_vein_vector">0x08</Offset>
<Offset name="map_data_feature_local">0x20</Offset>
<Offset name="map_data_feature_global">0x24</Offset>
<Offset name="map_data_type">0x006A</Offset>
<Offset name="map_data_designation">0x026C</Offset>
<Offset name="map_data_occupancy">0x066c</Offset>
<Offset name="map_data_temperature1_offset">0x156c</Offset>
<Offset name="map_data_temperature2_offset">0x176c</Offset>
<Offset name="map_data_biome_stuffs">0x1D6C</Offset>
<Offset name="map_data_pathfinding_offset">0x0D6c</Offset>
Map Features
============
WORLD + 0x54374
<Address name="global_feature_vector">0x16AF4FC</Address>
<Offset name= "global_feature_funcptr_">0x100</Offset>
WORLD + 0x54440
<Address name="local_feature_start_ptr">0x16AF5C8</Address>
* map size in blocks *
<Address name="x_count_block">0x9322d34</Address> 0x016ad738
<Address name="y_count_block">0x9322d38</Address>0x016ad73C
<Address name="z_count_block">0x9322d3C</Address>0x016ad740
* map size in tiles *
<Address name="x_count">0x9322d40</Address> 0x016ad744
<Address name="y_count">0x9322d44</Address> 0x016ad748
<Address name="z_count">0x9322d48</Address> 0x016ad74C
* region coords *
WORLD + 0x525C8
<Address name="region_x">0x9322d4C</Address> 0x016ad750
WORLD + 0x525CC
<Address name="region_y">0x9322d50</Address> 0x016ad754
WORLD + 0x525D0
<Address name="region_z">0x9322d54</Address> 0x016ad758
* World size * (WORDs)
<Address name="world_size_x">0x016AEDD4</Address> FIX
<Address name="world_size_y">0x016AEDD6</Address> FIX
<Address name="geoblock_vector">0x16AF52C</Address> FIX
<Address name="ptr2_region_array">0x16AF574</Address> FIX
values for the region structure
===============================
<HexValue name="region_size">0x64</HexValue> FIX
<Offset name="region_geo_index_off">0x60</Offset> FIX
geoblock offsets
================
<Offset name="geolayer_geoblock_offset">0x4</Offset> vector
<Offset name="type_inside_geolayer">0x4</Offset> vector
Name struct Name struct
=========== ===========
<Offset name="name_firstname">0x0</Offset> <Offset name="name_firstname">0x0</Offset>
<Offset name="name_nickname">0x1C</Offset> <Offset name="name_nickname">0x4</Offset>
<Offset name="name_words">0x38</Offset> <Offset name="name_words">0x8</Offset>
<!--
Creatures
=========
<Address name="creature_vector">0x0166ecc4</Address>
<Address name="dwarf_race_index">0x01470fbc</Address>
<Address name="dwarf_civ_id">0x01470fb0</Address>
<Offset name="creature_name">0x0</Offset>
<Offset name="creature_custom_profession">0x6c</Offset>
<Offset name="creature_profession">0x88</Offset>
<Offset name="creature_race">0x8C</Offset>
<Offset name="creature_position">0x90</Offset>
<Offset name="creature_flags1">0xF8</Offset>
<Offset name="creature_flags2">0xFC</Offset>
<Offset name="creature_sex">0x110</Offset>
<Offset name="creature_id">0x114</Offset>
<Offset name="creature_civ">0X120</Offset>
<Offset name="creature_soulskill_vector">0X1F4</Offset>
<Offset name="creature_pickup_equipment_bit">0X21C</Offset>
<Offset name="creature_mood">0x288</Offset>
<Offset name="creature_pregnancy">0x28C</Offset>
<Offset name="creature_pregnancy_ptr">0x290</Offset>
<Offset name="creature_birth_year">0x298</Offset>
<Offset name="creature_birth_time">0x29C</Offset>
<Offset name="creature_physical">0x464</Offset>
<Offset name="creature_current_job">0x390</Offset>
<Offset name="creature_mood_skill">0x394</Offset> the skill that will be increased at the end of the mood (or not)
<Offset name="creature_appearance_vector">0x604</Offset> seems to be indexes in the list of possible colors defined in the raws for each group
<Offset name="creature_artifact_name">0x6D0</Offset>
<Offset name="creature_labors">0x770</Offset>
<Offset name="creature_soul_vector">0x073C</Offset>
<Offset name="creature_default_soul">0x0754</Offset>
<Offset name="creature_happiness">0x830</Offset>
Souls
=====
<Offset name="soul_name">0x0</Offset>
<Offset name="soul_skills_vector">0x1F4</Offset>
<Offset name="soul_traits">0x224</Offset>
<Offset name="soul_mental">0x88</Offset>
Job structure
=============
<Offset name="job_id">0x0</Offset> Incrementaly assigned
<Offset name="job_type">0x8</Offset> seems to be just like the old occupations
<Offset name="job_materials_vector">0xa4</Offset>
Job materials
=============
<Offset name="job_material_maintype">0x0</Offset> like mood materials, 0=bars, 4=stone, 5=wood, 57=cloth, 54=leather ...
<Offset name="job_material_sectype1">0x2</Offset> subsubtype ?
<Offset name="job_material_sectype2">0x4</Offset> subtype ?
<Offset name="job_material_sectype3">0x8</Offset> index of material (for example, 2 is for silver)
<Offset name="job_material_flags">0x18</Offset> set only for shell / bone mood requirements ?
-->
Materials
=========
soil, stone, metal
inorganics vector = WORLD + 0x54B7C = 0x16AFD04
<Address name="mat_inorganics">0x9324e68</Address>0x16afd04
wood and plant matter, WORLD + 0x54B94
<Address name="mat_organics_all">0x9324E74</Address>
plant matter, WORLD + 0x54BAC
<Address name="mat_organics_plants">0x9324E80</Address>
just wood, WORLD + 0x54BDC
<Address name="mat_organics_trees">0x9324E98</Address>
<!--
creature types actually used for creatures,
WORLD + 0x54CD0
<Address name="creature_type_vector">0x016AFE58</Address>
<Offset name="creature_type_caste_vector">0x138</Offset>
<Offset name="creature_type_extract_vector">0x1A14</Offset>
<Offset name="creature_tile">0xE0</Offset>
<Offset name="creature_tile_color">0xF6</Offset>
Constructions
=============
WORLD + 0x108
<Address name="construction_vector">0x165b290</Address>
<Offset name="sizeof_construction">0x14</Offset>
Translations
============
WORLD + 0x54E50
<Address name="language_vector">0x016AFFD8</Address>
WORLD + 0x54E80
<Address name="translation_vector">0x016B0008</Address>
<Offset name="word_table">0x4C</Offset>
Vegetation
==========
WORLD + 0x15184
<Address name="vegetation_vector">0x0167030C</Address> belal: 0x017f6d98 ... what?
<Offset name="tree_desc_offset">0x6C</Offset>
Buildings
=========
WORLD + 0x14818
<Address name="buildings_vector">0x0166f9a0</Address>
<Offset name="building_custom_workshop_type">0x164</Offset>
WORLD + 0x5D610
<Address name="custom_workshop_vector">0x016B8798</Address>
<Offset name="custom_workshop_name">0x4</Offset>
<Offset name="custom_workshop_type">0x20</Offset>
Effects
=======
:(
Settlements
===========
:(
Hotkeys
=======
<Address name="hotkey_start">0x01476ecc</Address>
<Offset name="hotkey_mode">0x1C</Offset>
<Offset name="hotkey_xyz">0x20</Offset>
<HexValue name="hotkey_size">0x2C</HexValue>
-->
<!--
<HexValue name="sizeof_vector">0xC</HexValue>
<Offset name="vector_triplet">0x0</Offset>
Name struct
===========
<Offset name="name_firstname">0x0</Offset>
<Offset name="name_nickname">0x4</Offset>
<Offset name="name_words">0x8</Offset>
<HexValue name="sizeof_string">0x4</HexValue>
Position Position
======== ========
@ -1684,13 +1904,12 @@ map_data_1b60_offset 0x1B9c
<Offset name="creature_civ">0X120</Offset> <Offset name="creature_civ">0X120</Offset>
<Offset name="creature_soulskill_vector">0X1F4</Offset> <Offset name="creature_soulskill_vector">0X1F4</Offset>
<Offset name="creature_pickup_equipment_bit">0X21C</Offset> <Offset name="creature_pickup_equipment_bit">0X21C</Offset>
<!--<Offset name="creature_mood">0x238</Offset>-->
<Offset name="creature_mood">0x288</Offset> <Offset name="creature_mood">0x288</Offset>
<Offset name="creature_birth_year">0x298</Offset> <Offset name="creature_birth_year">0x298</Offset>
<Offset name="creature_birth_time">0x29C</Offset> <Offset name="creature_birth_time">0x29C</Offset>
<Offset name="creature_physical">0x464</Offset> <Offset name="creature_physical">0x464</Offset>
<Offset name="creature_current_job">0x390</Offset> <!-- from chmod --> <Offset name="creature_current_job">0x390</Offset> from chmod
<Offset name="creature_mood_skill">0x394</Offset> the skill that will be increased at the end of the mood (or not) <Offset name="creature_mood_skill">0x394</Offset> the skill that will be increased at the end of the mood (or not)
<Offset name="creature_appearance_vector">0x604</Offset> <Offset name="creature_appearance_vector">0x604</Offset>
<Offset name="creature_artifact_name">0x6D4</Offset> <Offset name="creature_artifact_name">0x6D4</Offset>
@ -1801,12 +2020,8 @@ map_data_1b60_offset 0x1B9c
Time Time
==== ====
<Address name="current_tick">0</Address> <Address name="current_tick">0</Address>
<Address name="current_year">0</Address> <Address name="current_year">0</Address>-->
</Entry> </Entry>
</MemoryDescriptors> </MemoryDescriptors>
</DFExtractor> </DFExtractor>

@ -90,7 +90,7 @@ int main (int argc, const char* argv[])
return 1; return 1;
} }
Maps->getSize(x_max,y_max,z_max); Maps->getSize(x_max,y_max,z_max);
/*
if(!Maps->ReadGlobalFeatures(global_features)) if(!Maps->ReadGlobalFeatures(global_features))
{ {
cerr << "Can't get global features." << endl; cerr << "Can't get global features." << endl;
@ -107,7 +107,7 @@ int main (int argc, const char* argv[])
cin.ignore(); cin.ignore();
#endif #endif
return 1; return 1;
} }*/
// get stone matgloss mapping // get stone matgloss mapping
if(!Mats->ReadInorganicMaterials()) if(!Mats->ReadInorganicMaterials())
{ {
@ -118,7 +118,7 @@ int main (int argc, const char* argv[])
#endif #endif
return 1; return 1;
} }
/*
// get region geology // get region geology
if(!Maps->ReadGeology( layerassign )) if(!Maps->ReadGeology( layerassign ))
{ {
@ -128,7 +128,7 @@ int main (int argc, const char* argv[])
#endif #endif
return 1; return 1;
} }
*/
int16_t tempvein [16][16]; int16_t tempvein [16][16];
vector <DFHack::t_vein> veins; vector <DFHack::t_vein> veins;
uint32_t maximum_regionoffset = 0; uint32_t maximum_regionoffset = 0;