default race attributes values are now decoded and displayed

develop
simon 2010-05-10 13:11:46 +02:00
parent 81045aba5c
commit a7fb5efb28
3 changed files with 24 additions and 2 deletions

@ -297,6 +297,7 @@ bool Materials::ReadCreatureTypesEx (void)
uint32_t sizeof_string = mem->getHexValue ("sizeof_string"); uint32_t sizeof_string = mem->getHexValue ("sizeof_string");
uint32_t caste_colormod_offset = mem->getOffset ("caste_color_modifiers"); uint32_t caste_colormod_offset = mem->getOffset ("caste_color_modifiers");
uint32_t caste_bodypart_offset = mem->getOffset ("caste_bodypart_vector"); uint32_t caste_bodypart_offset = mem->getOffset ("caste_bodypart_vector");
uint32_t caste_attributes_offset = mem->getOffset ("caste_attributes");
uint32_t bodypart_id_offset = mem->getOffset ("bodypart_id"); uint32_t bodypart_id_offset = mem->getOffset ("bodypart_id");
uint32_t bodypart_category_offset = mem->getOffset ("bodypart_category"); uint32_t bodypart_category_offset = mem->getOffset ("bodypart_category");
uint32_t bodypart_layers_offset = mem->getOffset ("bodypart_layers_vector"); uint32_t bodypart_layers_offset = mem->getOffset ("bodypart_layers_vector");
@ -354,6 +355,9 @@ bool Materials::ReadCreatureTypesEx (void)
caste.bodypart.push_back(part); caste.bodypart.push_back(part);
} }
p->read(caste_start + caste_attributes_offset, sizeof(t_attrib) * (6+11), (uint8_t *)&caste.strength);
mat.castes.push_back(caste); mat.castes.push_back(caste);
} }
mat.tile_character = p->readByte( p_races[i] + tile_offset ); mat.tile_character = p->readByte( p_races[i] + tile_offset );

@ -96,7 +96,24 @@ int main (int numargs, const char ** args)
<< castes[j].rawname << ":" << castes[j].rawname << ":"
<< castes[j].singular << ":" << castes[j].singular << ":"
<< castes[j].plural << ":" << castes[j].plural << ":"
<< castes[j].adjective << "] "; << castes[j].adjective << "] ["
<< "st:" << castes[j].strength.level << "/"
<< "ag:" << castes[j].agility.level << "/"
<< "to:" << castes[j].toughness.level << "/"
<< "en:" << castes[j].endurance.level << "/"
<< "re:" << castes[j].recuperation.level << "/"
<< "di:" << castes[j].disease_resistance.level << "/"
<< "an:" << castes[j].analytical_ability.level << "/"
<< "fo:" << castes[j].focus.level << "/"
<< "wi:" << castes[j].willpower.level << "/"
<< "cr:" << castes[j].creativity.level << "/"
<< "in:" << castes[j].intuition.level << "/"
<< "pa:" << castes[j].patience.level << "/"
<< "me:" << castes[j].memory.level << "/"
<< "li:" << castes[j].linguistic_ability.level << "/"
<< "sp:" << castes[j].spatial_sense.level << "/"
<< "mu:" << castes[j].musicality.level << "/"
<< "ki:" << castes[j].kinesthetic_sense.level << "]";
cout << endl; cout << endl;
for(uint32_t k = 0; k < castes[j].ColorModifier.size(); k++) for(uint32_t k = 0; k < castes[j].ColorModifier.size(); k++)
{ {

@ -1444,9 +1444,10 @@ map_data_1b60_offset 0x1B9c
Castes Castes
====== ======
<Offset name="color_modifier_part">0x70</Offset>
<Offset name="caste_bodypart_vector">0x51C</Offset> <Offset name="caste_bodypart_vector">0x51C</Offset>
<Offset name="caste_color_modifiers">0xACC</Offset> <Offset name="caste_color_modifiers">0xACC</Offset>
<Offset name="color_modifier_part">0x70</Offset> <Offset name="caste_attributes">0x654</Offset>
Body Parts Body Parts
========== ==========