diff --git a/CHANGELOG.md b/CHANGELOG.md index 80e65d03e..da77ddc70 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -55,6 +55,7 @@ Bug #4942: Hand-to-Hand attack type is chosen randomly when "always use best attack" is turned off Bug #4947: Player character doesn't use lip animation Bug #4948: Footstep sounds while levitating on ground level + Bug #4963: Enchant skill progress is incorrect Feature #2229: Improve pathfinding AI Feature #3442: Default values for fallbacks from ini file Feature #3610: Option to invert X axis diff --git a/apps/openmw/mwmechanics/spellcasting.cpp b/apps/openmw/mwmechanics/spellcasting.cpp index 7b406cf9a..b3428e44d 100644 --- a/apps/openmw/mwmechanics/spellcasting.cpp +++ b/apps/openmw/mwmechanics/spellcasting.cpp @@ -864,16 +864,15 @@ namespace MWMechanics if (mCaster == getPlayer()) mCaster.getClass().skillUsageSucceeded (mCaster, ESM::Skill::Enchant, 1); } - if (enchantment->mData.mType == ESM::Enchantment::CastOnce && !godmode) + else if (enchantment->mData.mType == ESM::Enchantment::CastOnce) { - item.getContainerStore()->remove(item, 1, mCaster); + if (!godmode) + item.getContainerStore()->remove(item, 1, mCaster); } - else if (enchantment->mData.mType != ESM::Enchantment::WhenStrikes) + else if (enchantment->mData.mType == ESM::Enchantment::WhenStrikes) { if (mCaster == getPlayer()) - { mCaster.getClass().skillUsageSucceeded (mCaster, ESM::Skill::Enchant, 3); - } } inflict(mCaster, mCaster, enchantment->mEffects, ESM::RT_Self);