Fix creature vector on windows

develop
Petr Mrázek 2010-06-07 01:54:40 +02:00
parent 319e37b9b0
commit 9d143d8afb
2 changed files with 8 additions and 1 deletions

@ -1600,7 +1600,7 @@ map_data_1b60_offset 0x1B9c
<Entry version="v0.31.05" os="windows" id="0.31.05" base="0.31.04" rebase="0x8010"> <Entry version="v0.31.05" os="windows" id="0.31.05" base="0.31.04" rebase="0x8010">
<String name="md5">394ff63fc00fedd5df0b36e4beb589bc</String> <String name="md5">394ff63fc00fedd5df0b36e4beb589bc</String>
<HexValue name="pe_timestamp">0x4c091569</HexValue> <HexValue name="pe_timestamp">0x4c091569</HexValue>
<Address name="creature_vector">0x1678704</Address> CHMOD <!--<Address name="creature_vector">0x1678704</Address> CHMOD-->
<Address name="dwarf_race_index">0x014abee4</Address> CHMOD <Address name="dwarf_race_index">0x014abee4</Address> CHMOD
<Address name="dwarf_civ_id">0x1471FB0</Address> BOGUS! <Address name="dwarf_civ_id">0x1471FB0</Address> BOGUS!
<!-- <!--

@ -36,6 +36,7 @@ int main (int numargs, const char ** args)
DFHack::Constructions *Cons = DF->getConstructions(); DFHack::Constructions *Cons = DF->getConstructions();
DFHack::Materials *Mats = DF->getMaterials(); DFHack::Materials *Mats = DF->getMaterials();
Mats->ReadInorganicMaterials(); Mats->ReadInorganicMaterials();
Mats->ReadOrganicMaterials();
uint32_t numConstr; uint32_t numConstr;
Cons->Start(numConstr); Cons->Start(numConstr);
@ -59,6 +60,12 @@ int main (int numargs, const char ** args)
matstr = Mats->inorganic[con.mat_idx].id; matstr = Mats->inorganic[con.mat_idx].id;
else matstr = "inorganic"; else matstr = "inorganic";
} }
if(con.mat_type == 420)
{
if(con.mat_idx != 0xffffffff)
matstr = Mats->organic[con.mat_idx].id;
else matstr = "organic";
}
switch(con.form) switch(con.form)
{ {
case constr_bar: case constr_bar: