From 9e21755577d8f2ec0cb52836fedd72eddbea7d77 Mon Sep 17 00:00:00 2001 From: Liza Carvelli Date: Mon, 17 Mar 2025 18:47:24 +0100 Subject: [PATCH] Fix MoveTo not working if you entered combat while trying to mount --- Questionable/Controller/Steps/Common/Mount.cs | 6 +++++- Questionable/Controller/Steps/Shared/MoveTo.cs | 10 ++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/Questionable/Controller/Steps/Common/Mount.cs b/Questionable/Controller/Steps/Common/Mount.cs index 898ca14f..b347a71f 100644 --- a/Questionable/Controller/Steps/Common/Mount.cs +++ b/Questionable/Controller/Steps/Common/Mount.cs @@ -80,7 +80,11 @@ internal static class Mount return MountResult.WhenOutOfCombat; } - protected override bool Start() => EvaluateMountState() == MountResult.Mount; + protected override bool Start() + { + _mountTriggered = false; + return EvaluateMountState() == MountResult.Mount; + } public override ETaskResult Update() { diff --git a/Questionable/Controller/Steps/Shared/MoveTo.cs b/Questionable/Controller/Steps/Shared/MoveTo.cs index 741c5433..c10cb29e 100644 --- a/Questionable/Controller/Steps/Shared/MoveTo.cs +++ b/Questionable/Controller/Steps/Shared/MoveTo.cs @@ -248,6 +248,16 @@ internal static class MoveTo else return ETaskResult.TaskComplete; } + else if (!_condition[ConditionFlag.Mounted] && _condition[ConditionFlag.InCombat] && + nestedExecutor is { Triggered: true, Executor: Mount.MountExecutor }) + { + // if the problem wasn't caused by combat, the normal mount retry should handle it + _logger.LogDebug("Resetting mount trigger state"); + _nestedExecutor = nestedExecutor with { Triggered = false }; + + // however, we're also explicitly ignoring combat here and walking away + _startAction?.Invoke(); + } return ETaskResult.StillRunning; } -- 2.30.2