|
|
@ -44,7 +44,7 @@ int main (int argc,const char* argv[])
|
|
|
|
mode = 1;
|
|
|
|
mode = 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
vector<DFHack::t_matgloss> creaturestypes;
|
|
|
|
map <uint32_t, string> custom_workshop_types;
|
|
|
|
|
|
|
|
|
|
|
|
DFHack::API DF ("Memory.xml");
|
|
|
|
DFHack::API DF ("Memory.xml");
|
|
|
|
try
|
|
|
|
try
|
|
|
@ -59,6 +59,7 @@ int main (int argc,const char* argv[])
|
|
|
|
#endif
|
|
|
|
#endif
|
|
|
|
return 1;
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
DFHack::memory_info * mem = DF.getMemoryInfo();
|
|
|
|
DFHack::memory_info * mem = DF.getMemoryInfo();
|
|
|
|
DFHack::Buildings * Bld = DF.getBuildings();
|
|
|
|
DFHack::Buildings * Bld = DF.getBuildings();
|
|
|
|
DFHack::Position * Pos = DF.getPosition();
|
|
|
|
DFHack::Position * Pos = DF.getPosition();
|
|
|
@ -66,6 +67,7 @@ int main (int argc,const char* argv[])
|
|
|
|
uint32_t numBuildings;
|
|
|
|
uint32_t numBuildings;
|
|
|
|
if(Bld->Start(numBuildings))
|
|
|
|
if(Bld->Start(numBuildings))
|
|
|
|
{
|
|
|
|
{
|
|
|
|
|
|
|
|
Bld->ReadCustomWorkshopTypes(custom_workshop_types);
|
|
|
|
if(mode)
|
|
|
|
if(mode)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
cout << numBuildings << endl;
|
|
|
|
cout << numBuildings << endl;
|
|
|
@ -110,6 +112,11 @@ int main (int argc,const char* argv[])
|
|
|
|
mem->resolveClassIDToClassname(temp.type, typestr);
|
|
|
|
mem->resolveClassIDToClassname(temp.type, typestr);
|
|
|
|
printf("Address 0x%x, type %d (%s), %d/%d/%d\n",temp.origin, temp.type, typestr.c_str(), temp.x1,temp.y1,temp.z);
|
|
|
|
printf("Address 0x%x, type %d (%s), %d/%d/%d\n",temp.origin, temp.type, typestr.c_str(), temp.x1,temp.y1,temp.z);
|
|
|
|
printf("Material %d %d\n", temp.material.type, temp.material.index);
|
|
|
|
printf("Material %d %d\n", temp.material.type, temp.material.index);
|
|
|
|
|
|
|
|
int32_t custom;
|
|
|
|
|
|
|
|
if((custom = Bld->GetCustomWorkshopType(temp)) != -1)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
printf("Custom workshop type %s (%d)\n",custom_workshop_types[custom].c_str(),custom);
|
|
|
|
|
|
|
|
}
|
|
|
|
hexdump(DF,temp.origin,120);
|
|
|
|
hexdump(DF,temp.origin,120);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|