mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-27 03:35:27 +00:00
Allow adding multiple Attribute/Skill effects in spell making (Fixes #2224)
This commit is contained in:
parent
73382b8aa4
commit
c796589420
@ -592,14 +592,6 @@ namespace MWGui
|
||||
|
||||
int buttonId = *sender->getUserData<int>();
|
||||
mSelectedKnownEffectId = mButtonMapping[buttonId];
|
||||
for (std::vector<ESM::ENAMstruct>::const_iterator it = mEffects.begin(); it != mEffects.end(); ++it)
|
||||
{
|
||||
if (it->mEffectID == mSelectedKnownEffectId)
|
||||
{
|
||||
MWBase::Environment::get().getWindowManager()->messageBox ("#{sOnetypeEffectMessage}");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
const ESM::MagicEffect* effect =
|
||||
MWBase::Environment::get().getWorld()->getStore().get<ESM::MagicEffect>().find(mSelectedKnownEffectId);
|
||||
@ -622,6 +614,15 @@ namespace MWGui
|
||||
}
|
||||
else
|
||||
{
|
||||
for (std::vector<ESM::ENAMstruct>::const_iterator it = mEffects.begin(); it != mEffects.end(); ++it)
|
||||
{
|
||||
if (it->mEffectID == mSelectedKnownEffectId)
|
||||
{
|
||||
MWBase::Environment::get().getWindowManager()->messageBox ("#{sOnetypeEffectMessage}");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
mAddEffectDialog.newEffect(effect);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user