1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 18:19:55 +00:00

Don't apply iWereWolfFleeMod to creatures

This commit is contained in:
Capostrophic 2018-08-02 08:31:45 +03:00 committed by Capostrophic
parent 1c13256456
commit 80f3bd9f86
2 changed files with 7 additions and 3 deletions

View file

@ -74,6 +74,7 @@
Bug #4510: Division by zero in MWMechanics::CreatureStats::setAttribute
Bug #4519: Knockdown does not discard movement in the 1st-person mode
Bug #4539: Paper Doll is affected by GUI scaling
Bug #4545: Creatures flee from werewolves
Feature #2606: Editor: Implemented (optional) case sensitive global search
Feature #3083: Play animation when NPC is casting spell via script
Feature #3276: Editor: Search- Show number of (remaining) search results and indicate a search without any results

View file

@ -494,10 +494,13 @@ namespace MWMechanics
static const int iWereWolfLevelToAttack = gmst.find("iWereWolfLevelToAttack")->getInt();
if (enemy.getClass().isNpc() && enemy.getClass().getNpcStats(enemy).isWerewolf() && stats.getLevel() < iWereWolfLevelToAttack)
if (actor.getClass().isNpc() && enemy.getClass().isNpc())
{
if (enemy.getClass().getNpcStats(enemy).isWerewolf() && stats.getLevel() < iWereWolfLevelToAttack)
{
static const int iWereWolfFleeMod = gmst.find("iWereWolfFleeMod")->getInt();
rating = iWereWolfFleeMod;
rating += iWereWolfFleeMod;
}
}
if (rating != 0.0f)