mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-06 00:55:50 +00:00
Don't allow talking to creatures that are in combat
This commit is contained in:
parent
a9847c9453
commit
c54ab2e846
@ -463,6 +463,8 @@ namespace MWClass
|
||||
|
||||
if(getCreatureStats(ptr).isDead())
|
||||
return boost::shared_ptr<MWWorld::Action>(new MWWorld::ActionOpen(ptr, true));
|
||||
if(ptr.getClass().getCreatureStats(ptr).getAiSequence().isInCombat())
|
||||
return boost::shared_ptr<MWWorld::Action>(new MWWorld::FailedAction(""));
|
||||
return boost::shared_ptr<MWWorld::Action>(new MWWorld::ActionTalk(ptr));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user