1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-12-25 18:03:08 +00:00

Merge branch 'iliketomoveitmoveitprovideditisacell' into 'master'

Insert exterior cells created by moved refs into mSharedExt

Closes #8875

See merge request OpenMW/openmw!5067
This commit is contained in:
Alexei Kotov 2025-12-25 00:54:49 +03:00
commit 87da40e6d2

View file

@ -597,9 +597,10 @@ namespace MWWorld
newCell.mAmbi.mFogDensity = 0;
newCell.updateId();
ESM::Cell* newCellInserted = &mCells.insert(std::make_pair(newCell.mId, newCell)).first->second;
return mExt.insert(std::make_pair(key, newCellInserted)).first->second;
ESM::Cell* newCellInserted = &mCells.emplace(newCell.mId, newCell).first->second;
mExt.emplace(key, newCellInserted);
mSharedExt.emplace_back(newCellInserted);
return newCellInserted;
}
const ESM::Cell* Store<ESM::Cell>::find(const ESM::RefId& id) const
{