|
|
@ -395,18 +395,9 @@ c_creaturetype* Materials_getRaceEx(DFHackObject* mat)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
c_creaturetype* buf = NULL;
|
|
|
|
c_creaturetype* buf = NULL;
|
|
|
|
|
|
|
|
|
|
|
|
if(alloc_creaturetype_buffer_callback == NULL)
|
|
|
|
CreatureTypeConvert(((DFHack::Materials*)mat)->raceEx, &buf);
|
|
|
|
return NULL;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
((*alloc_creaturetype_buffer_callback)(&buf, matSize));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if(buf != NULL)
|
|
|
|
return buf;
|
|
|
|
{
|
|
|
|
|
|
|
|
for(int i = 0; i < matSize; i++)
|
|
|
|
|
|
|
|
CreatureTypeConvert(&materials->raceEx[i], &(buf[i]));
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return buf;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|