1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-26 09:35:28 +00:00

Merge branch 'forwardtothepast' into 'master'

Support /-separated big effect icon paths

See merge request OpenMW/openmw!2711
This commit is contained in:
psi29a 2023-02-10 17:44:26 +00:00
commit 5eba755174
2 changed files with 2 additions and 0 deletions

View File

@ -416,6 +416,7 @@ namespace MWGui
spell->mEffects.mList.front().mEffectID);
std::string icon = effect->mIcon;
std::replace(icon.begin(), icon.end(), '/', '\\');
int slashPos = icon.rfind('\\');
icon.insert(slashPos + 1, "b_");
icon = Misc::ResourceHelpers::correctIconPath(icon, MWBase::Environment::get().getResourceSystem()->getVFS());

View File

@ -302,6 +302,7 @@ namespace MWGui
const ESM::MagicEffect* effect = esmStore.get<ESM::MagicEffect>().find(spell->mEffects.mList.front().mEffectID);
std::string path = effect->mIcon;
std::replace(path.begin(), path.end(), '/', '\\');
int slashPos = path.rfind('\\');
path.insert(slashPos + 1, "b_");
path = Misc::ResourceHelpers::correctIconPath(path, MWBase::Environment::get().getResourceSystem()->getVFS());