mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-03-28 20:36:42 +00:00
Restore empty target check in spell absorption
This commit is contained in:
parent
341bcb66f5
commit
1842f546c3
1 changed files with 1 additions and 1 deletions
|
@ -46,7 +46,7 @@ namespace MWMechanics
|
||||||
|
|
||||||
bool absorbSpell (const std::string& spellId, const MWWorld::Ptr& caster, const MWWorld::Ptr& target)
|
bool absorbSpell (const std::string& spellId, const MWWorld::Ptr& caster, const MWWorld::Ptr& target)
|
||||||
{
|
{
|
||||||
if (spellId.empty() || caster == target || !target.getClass().isActor())
|
if (spellId.empty() || target.isEmpty() || caster == target || !target.getClass().isActor())
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
CreatureStats& stats = target.getClass().getCreatureStats(target);
|
CreatureStats& stats = target.getClass().getCreatureStats(target);
|
||||||
|
|
Loading…
Reference in a new issue