1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-30 04:15:31 +00:00

Merge pull request #1084 from Allofich/water

Don't let water-only creatures prevent resting
This commit is contained in:
scrawl 2016-10-01 16:14:19 +02:00 committed by GitHub
commit b170efb9fa

View file

@ -1535,7 +1535,7 @@ namespace MWMechanics
for(std::vector<MWWorld::Ptr>::const_iterator iter(neighbors.begin());iter != neighbors.end();++iter)
{
const CreatureStats &stats = iter->getClass().getCreatureStats(*iter);
if (stats.isDead() || *iter == actor)
if (stats.isDead() || *iter == actor || iter->getClass().isPureWaterCreature(*iter))
continue;
const bool isFollower = std::find(followers.begin(), followers.end(), *iter) != followers.end();
if (stats.getAiSequence().isInCombat(actor) || (MWBase::Environment::get().getMechanicsManager()->isAggressive(*iter, actor) && !isFollower))