From 413207f9af992c7073fb4c9bf52651bfbf307cc5 Mon Sep 17 00:00:00 2001 From: Andrei Kortunov Date: Sat, 6 Apr 2019 20:07:06 +0400 Subject: [PATCH] Reset old record, if its ID does not match with ID of new record (bug #4932) --- CHANGELOG.md | 1 + apps/openmw/mwworld/cellstore.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d5dcf5def..77d3b9c35 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -51,6 +51,7 @@ Bug #4916: Specular power (shininess) material parameter is ignored when shaders are used. Bug #4922: Werewolves can not attack if the transformation happens during attack Bug #4927: Spell effect having both a skill and an attribute assigned is a fatal error + Bug #4932: Invalid records matching when loading save with edited plugin Bug #4938: Strings from subrecords with actually empty headers can't be empty Bug #4942: Hand-to-Hand attack type is chosen randomly when "always use best attack" is turned off Bug #4947: Player character doesn't use lip animation diff --git a/apps/openmw/mwworld/cellstore.cpp b/apps/openmw/mwworld/cellstore.cpp index 12430ebde..4a8aff67d 100644 --- a/apps/openmw/mwworld/cellstore.cpp +++ b/apps/openmw/mwworld/cellstore.cpp @@ -133,7 +133,7 @@ namespace { for (typename MWWorld::CellRefList::List::iterator iter (collection.mList.begin()); iter!=collection.mList.end(); ++iter) - if (iter->mRef.getRefNum()==state.mRef.mRefNum) + if (iter->mRef.getRefNum()==state.mRef.mRefNum && iter->mRef.getRefId() == state.mRef.mRefID) { // overwrite existing reference iter->load (state);