[Client] Retain AiPursue for guards ignoring player because of dialogue

In OpenMW, guards starting combat with the player cause other guards with an AiPursue package to also join the combat in MechanicsManager::startCombat(). Previously, however, TES3MP was discarding AiPursue packages for the guards who hadn't started the arrest dialogue with the player by returning the wrong boolean in AiPursue::execute(), leading to just one-on-one combat with the arresting guard.
This commit is contained in:
David Cernat 2020-07-26 11:06:11 +02:00
parent ff10aa816b
commit 57734c172b

View File

@ -63,7 +63,7 @@ bool AiPursue::execute (const MWWorld::Ptr& actor, CharacterController& characte
Start of tes3mp addition
Because multiplayer does not pause the game, prevent infinite arrest loops by ignoring
players already engaged in dialogue
players already engaged in dialogue while retaining the AiPursue package
Additionally, do not arrest players who are currently jailed
*/
@ -72,7 +72,7 @@ bool AiPursue::execute (const MWWorld::Ptr& actor, CharacterController& characte
if (MWBase::Environment::get().getWindowManager()->containsMode(MWGui::GM_Dialogue) ||
MWBase::Environment::get().getWindowManager()->containsMode(MWGui::GM_Jail))
{
return true;
return false;
}
}
/*