1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-03-29 22:20:33 +00:00

Remove some nonsense code

This commit is contained in:
scrawl 2015-01-09 01:01:55 +01:00
parent 2ddbe22da3
commit c77660ba20
3 changed files with 1 additions and 11 deletions

View File

@ -99,9 +99,6 @@ namespace MWWorld
ESMStore() ESMStore()
: mDynamicCount(0) : mDynamicCount(0)
{ {
// Cell store needs access to this for tracking moved references
mCells.mEsmStore = this;
mStores[ESM::REC_ACTI] = &mActivators; mStores[ESM::REC_ACTI] = &mActivators;
mStores[ESM::REC_ALCH] = &mPotions; mStores[ESM::REC_ALCH] = &mPotions;
mStores[ESM::REC_APPA] = &mAppas; mStores[ESM::REC_APPA] = &mAppas;

View File

@ -11,8 +11,7 @@ void Store<ESM::Cell>::handleMovedCellRefs(ESM::ESMReader& esm, ESM::Cell* cell)
ESM::MovedCellRef cMRef; ESM::MovedCellRef cMRef;
cell->getNextMVRF(esm, cMRef); cell->getNextMVRF(esm, cMRef);
MWWorld::Store<ESM::Cell> &cStore = const_cast<MWWorld::Store<ESM::Cell>&>(mEsmStore->get<ESM::Cell>()); ESM::Cell *cellAlt = const_cast<ESM::Cell*>(searchOrCreate(cMRef.mTarget[0], cMRef.mTarget[1]));
ESM::Cell *cellAlt = const_cast<ESM::Cell*>(cStore.searchOrCreate(cMRef.mTarget[0], cMRef.mTarget[1]));
// Get regular moved reference data. Adapted from CellStore::loadRefs. Maybe we can optimize the following // Get regular moved reference data. Adapted from CellStore::loadRefs. Maybe we can optimize the following
// implementation when the oher implementation works as well. // implementation when the oher implementation works as well.

View File

@ -582,14 +582,8 @@ namespace MWWorld
void handleMovedCellRefs(ESM::ESMReader& esm, ESM::Cell* cell); void handleMovedCellRefs(ESM::ESMReader& esm, ESM::Cell* cell);
public: public:
ESMStore *mEsmStore;
typedef SharedIterator<ESM::Cell> iterator; typedef SharedIterator<ESM::Cell> iterator;
Store<ESM::Cell>()
: mEsmStore(NULL)
{}
const ESM::Cell *search(const std::string &id) const { const ESM::Cell *search(const std::string &id) const {
ESM::Cell cell; ESM::Cell cell;
cell.mName = Misc::StringUtils::lowerCase(id); cell.mName = Misc::StringUtils::lowerCase(id);