mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-03-14 01:19:59 +00:00
Merge branch 'conspiracyofsilence' into 'master'
Make powers immune to silence (#8371) Closes #8371 See merge request OpenMW/openmw!4557
This commit is contained in:
commit
f6cd90d9b0
@ -274,15 +274,15 @@ namespace MWMechanics
|
||||
|
||||
CreatureStats& stats = actor.getClass().getCreatureStats(actor);
|
||||
|
||||
if (stats.getMagicEffects().getOrDefault(ESM::MagicEffect::Silence).getMagnitude() && !godmode)
|
||||
return 0;
|
||||
|
||||
if (spell->mData.mType == ESM::Spell::ST_Power)
|
||||
return stats.getSpells().canUsePower(spell) ? 100 : 0;
|
||||
|
||||
if (godmode)
|
||||
return 100;
|
||||
|
||||
if (stats.getMagicEffects().getOrDefault(ESM::MagicEffect::Silence).getMagnitude())
|
||||
return 0;
|
||||
|
||||
if (spell->mData.mType != ESM::Spell::ST_Spell)
|
||||
return 100;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user