ESSImport: stolen items reading fix

openmw-35
scrawl 10 years ago
parent 378e91545d
commit af0e91c2d3

@ -364,15 +364,18 @@ public:
{ {
std::string itemid = esm.getHNString("NAME"); std::string itemid = esm.getHNString("NAME");
while (esm.isNextSub("ONAM")) while (esm.isNextSub("FNAM") || esm.isNextSub("ONAM"))
{ {
std::string ownerid = esm.getHString(); if (esm.retSubName().toString() == "FNAM")
mStolenItems.insert(std::make_pair(itemid, ownerid)); {
} std::string factionid = esm.getHString();
while (esm.isNextSub("FNAM")) mFactionStolenItems.insert(std::make_pair(itemid, factionid));
{ }
std::string factionid = esm.getHString(); else
mFactionStolenItems.insert(std::make_pair(itemid, factionid)); {
std::string ownerid = esm.getHString();
mStolenItems.insert(std::make_pair(itemid, ownerid));
}
} }
} }
private: private:

Loading…
Cancel
Save