1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-03-27 04:10:24 +00:00

Fix case folding for faction reaction from ESX records

This commit is contained in:
scrawl 2014-05-27 19:02:48 +02:00
parent 2b15b85af1
commit 0b45a9e6b2

View file

@ -695,12 +695,14 @@ namespace MWDialogue
const ESM::Faction* faction = MWBase::Environment::get().getWorld()->getStore().get<ESM::Faction>().find(fact1); const ESM::Faction* faction = MWBase::Environment::get().getWorld()->getStore().get<ESM::Faction>().find(fact1);
std::map<std::string, int>::const_iterator it = faction->mReactions.find(fact2); std::map<std::string, int>::const_iterator it = faction->mReactions.begin();
if (it == faction->mReactions.end()) for (; it != faction->mReactions.end(); ++it)
return diff; {
else if (Misc::StringUtils::ciEqual(it->first, fact2))
return it->second + diff; return it->second + diff;
} }
return diff;
}
std::vector<HyperTextToken> ParseHyperText(const std::string& text) std::vector<HyperTextToken> ParseHyperText(const std::string& text)
{ {