mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-28 18:09:43 +00:00
Break invisibility before applying CE enchantments
This commit is contained in:
parent
a62b16df5d
commit
6196e777da
2 changed files with 4 additions and 0 deletions
|
@ -144,6 +144,7 @@
|
|||
Bug #6901: Morrowind.exe soul gem usage discrepancy
|
||||
Bug #6909: Using enchanted items has no animation
|
||||
Bug #6910: Torches should not be extinguished when not being held
|
||||
Bug #6913: Constant effect enchanted items don't break invisibility
|
||||
Feature #890: OpenMW-CS: Column filtering
|
||||
Feature #1465: "Reset" argument for AI functions
|
||||
Feature #2491: Ability to make OpenMW "portable"
|
||||
|
|
|
@ -219,6 +219,9 @@ namespace MWMechanics
|
|||
return params.mSlot == slotIndex && params.mType == ESM::ActiveSpells::Type_Enchantment && params.mId == slot->getCellRef().getRefId();
|
||||
}) != mSpells.end())
|
||||
continue;
|
||||
// world->breakInvisibility leads to a stack overflow as it calls this method so just break invisibility manually
|
||||
purgeEffect(ptr, ESM::MagicEffect::Invisibility);
|
||||
applyPurges(ptr);
|
||||
const ActiveSpellParams& params = mSpells.emplace_back(ActiveSpellParams{*slot, enchantment, slotIndex, ptr});
|
||||
for(const auto& effect : params.mEffects)
|
||||
MWMechanics::playEffects(ptr, *world->getStore().get<ESM::MagicEffect>().find(effect.mEffectId), playNonLooping);
|
||||
|
|
Loading…
Reference in a new issue