mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-01 04:45:34 +00:00
Fix fall damage crash
This commit is contained in:
parent
b1ffb64a1f
commit
3db299f1b2
1 changed files with 1 additions and 1 deletions
|
@ -599,7 +599,7 @@ namespace MWClass
|
|||
// NOTE: 'object' and/or 'attacker' may be empty.
|
||||
|
||||
// Attacking peaceful NPCs is a crime
|
||||
if (ptr.getClass().getCreatureStats(ptr).getAiSetting(MWMechanics::CreatureStats::AI_Fight).getModified() <= 30)
|
||||
if (!attacker.isEmpty() && ptr.getClass().getCreatureStats(ptr).getAiSetting(MWMechanics::CreatureStats::AI_Fight).getModified() <= 30)
|
||||
MWBase::Environment::get().getMechanicsManager()->commitCrime(attacker, ptr, MWBase::MechanicsManager::OT_Assault);
|
||||
|
||||
if(!successful)
|
||||
|
|
Loading…
Reference in a new issue