1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-03-14 01:19:59 +00:00

Merge branch 'enchantment_exclamationmark' into 'master'

Allow GetSpellEffects to detect enchantments by id

Closes #3769

See merge request OpenMW/openmw!4521
This commit is contained in:
Evil Eye 2025-03-12 07:34:18 +00:00
commit edb374106b

View File

@ -884,8 +884,8 @@ namespace MWScript
return;
}
const MWMechanics::CreatureStats& stats = ptr.getClass().getCreatureStats(ptr);
runtime.push(stats.getActiveSpells().isSpellActive(id));
const auto& activeSpells = ptr.getClass().getCreatureStats(ptr).getActiveSpells();
runtime.push(activeSpells.isSpellActive(id) || activeSpells.isEnchantmentActive(id));
}
};