MCPcopy Create free account
hub / github.com/OpenApoc/OpenApoc / getItemImagePacksCount

Method getItemImagePacksCount

tools/extractors/extract_unit_image_packs.cpp:61–71  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59}
60
61int InitialGameStateExtractor::getItemImagePacksCount() const
62{
63 auto heldSpriteTabFileName = UString("xcom3/tacdata/unit/equip.tab");
64 auto heldSpriteTabFile = fw().data->fs.open(heldSpriteTabFileName);
65 if (!heldSpriteTabFile)
66 {
67 LogError("Failed to open held item sprite TAB file \"%s\"", heldSpriteTabFileName);
68 return -1;
69 }
70 return heldSpriteTabFile.size() / 4 / 8;
71}
72} // namespace OpenApoc

Callers 1

main.cppFile · 0.80

Calls 2

openMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected