[IGfxWorld] Map smodel index pointers
This commit is contained in:
parent
df59a4089e
commit
3ca58dd4ce
@ -230,8 +230,20 @@ namespace Assets
|
||||
Game::GfxAabbTree* aabbTree = &cellTree->aabbTree[j];
|
||||
|
||||
if (aabbTree->smodelIndexes)
|
||||
{
|
||||
void* oldPointer = aabbTree->smodelIndexes;
|
||||
if(builder->getAllocator()->isPointerMapped(oldPointer))
|
||||
{
|
||||
// We still have to read it
|
||||
reader.readArray<unsigned short>(aabbTree->smodelIndexCount);
|
||||
|
||||
aabbTree->smodelIndexes = builder->getAllocator()->getPointer<unsigned short>(oldPointer);
|
||||
}
|
||||
else
|
||||
{
|
||||
aabbTree->smodelIndexes = reader.readArray<unsigned short>(aabbTree->smodelIndexCount);
|
||||
builder->getAllocator()->mapPointer(oldPointer, aabbTree->smodelIndexes);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user