См. определение в файле BSPModel.cpp строка 45
46 static_assert(
sizeof(
BSPModelData) == 188,
"Wrong type size");
47 static_assert(
sizeof(
BSPNode) == 8,
"Wrong type size");
48 static_assert(
sizeof(Vec3_int_) == 12,
"Wrong type size");
51 memcpy(&uNumBModels,
data, 4);
54 std::vector<BSPModelData> models;
55 for (
unsigned int i = 0; i < uNumBModels; ++i) {
59 models.push_back(model);
62 unsigned int model_index = 0;
67 new_model.
index = model_index;
89 unsigned int verticesSize = model.
uNumVertices *
sizeof(Vec3_int_);
94 for (
size_t i = 0; i < model.
uNumFaces; i++) {
95 new_model.
pFaces.emplace_back();
102 unsigned int facesOrderingSize = model.
uNumFaces *
sizeof(short);
105 data += facesOrderingSize;
107 for (
size_t i = 0; i < model.
uNumNodes; i++) {
110 new_model.
pNodes.push_back(node);
114 const char *textureFilenames =
115 (
const char *)malloc(10 * model.
uNumFaces);
116 memcpy((
char *)textureFilenames,
data, 10 * model.
uNumFaces);
118 for (
unsigned int j = 0; j < model.
uNumFaces; ++j) {
119 const char *texFilename = &textureFilenames[j * 10];
120 new_model.
pFaces[j].SetTexture(texFilename);
121 if (new_model.
pFaces[j].sCogTriggeredID) {
122 if (new_model.
pFaces[j].HasEventHint())
123 new_model.
pFaces[j].uAttributes |= FACE_HAS_EVENT;
125 new_model.
pFaces[j].uAttributes &= ~FACE_HAS_EVENT;
129 free((
void *)textureFilenames);
Перекрестные ссылки BSPModel::field_40, BSPModel::index, BSPModel::pFaces, BSPModel::pFacesOrdering, BSPModel::pModelName, BSPModel::pModelName2, BSPModel::pNodes, BSPVertexBuffer::pVertices, BSPModel::pVertices, BSPModel::sBoundingRadius, BSPModel::sCenterX, BSPModel::sCenterY, BSPModel::sMaxX, BSPModel::sMaxY, BSPModel::sMaxZ, BSPModel::sMinX, BSPModel::sMinY, BSPModel::sMinZ, BSPModel::sSomeOtherMaxX, BSPModel::sSomeOtherMaxY, BSPModel::sSomeOtherMaxZ, BSPModel::sSomeOtherMinX, BSPModel::sSomeOtherMinY, BSPModel::sSomeOtherMinZ, BSPModel::vBoundingCenter и BSPModel::vPosition.
Используется в OutdoorLocation::Load().