quick creature API fix

develop
Petr Mrázek 2010-02-13 16:19:11 +00:00
parent a8d35f3724
commit a17cb053d4
2 changed files with 4 additions and 4 deletions

@ -788,7 +788,7 @@ void API::FinishReadVegetation()
}
bool API::InitReadCreatures( uint32_t numcreatures )
bool API::InitReadCreatures( uint32_t &numcreatures )
{
memory_info * minfo = d->offset_descriptor;
int creatures = d->offset_descriptor->getAddress ("creatures");
@ -844,7 +844,7 @@ bool API::InitReadCreatures( uint32_t numcreatures )
//InitReadNameTables();
d->creaturesInited = true;
numcreatures = d->p_cre->getSize();
return false;
return true;
}
else
{

@ -159,7 +159,7 @@ namespace DFHack
bool ReadVegetation(const int32_t &index, t_tree_desc & shrubbery);
void FinishReadVegetation();
bool InitReadCreatures( uint32_t numcreatures );
bool InitReadCreatures( uint32_t & numcreatures );
/// returns index of creature actually read or -1 if no creature can be found
int32_t ReadCreatureInBox(int32_t index, t_creature & furball,
const uint16_t &x1, const uint16_t &y1,const uint16_t &z1,