fix conflicts

This commit is contained in:
辉鸭蛋 2025-01-07 00:14:39 +08:00
parent 9f46fb00be
commit 30827b2ff4

View File

@ -242,34 +242,14 @@ public class PathExecutor
// 不管咋样,松开所有按键
Simulation.SendInput.Keyboard.KeyUp(User32.VK.VK_W);
Simulation.SendInput.Mouse.RightButtonUp();
}
}
catch (RetryException retryException)
{
StartSkipOtherOperations();
Logger.LogWarning(retryException.Message);
}
catch (RetryNoCountException retryException)
{
//特殊情况下,重试不消耗次数
i--;
StartSkipOtherOperations();
Logger.LogWarning(retryException.Message);
}
finally
{
// 不管咋样,松开所有按键
Simulation.SendInput.SimulateAction(GIActions.MoveForward, KeyType.KeyUp);
Simulation.SendInput.SimulateAction(GIActions.SprintMouse, KeyType.KeyUp);
}
}
}
finally
{
_unknownInterfaceCheckingTask = false;
}
}
private async Task<bool> SwitchPartyBefore(PathingTask task)
@ -315,16 +295,16 @@ public class PathExecutor
return true;
}
bool _unknownInterfaceCheckingTask = false;
private void UnknownInterfaceCheckingTaskStart()
{
/*if (_partyConfig.Enabled && _partyConfig.CloseUnknownInterfaceCheck)
{*/
_unknownInterfaceCheckingTask = true;
Task.Run(async () =>
{
Logger.LogInformation("开始未知界面检查");
while (_unknownInterfaceCheckingTask && !ct.IsCancellationRequested)
{
@ -336,10 +316,10 @@ public class PathExecutor
Logger.LogInformation("检测到烹饪界面使用ESC关闭界面");
Simulation.SendInput.Keyboard.KeyPress(User32.VK.VK_ESCAPE);
}
var mainRa2 = imageRegion.Find(AutoSkipAssets.Instance.PageCloseMainRo);
if (mainRa2.IsExist())
{
Logger.LogInformation("检测到主界面使用ESC关闭界面");
Simulation.SendInput.Keyboard.KeyPress(User32.VK.VK_ESCAPE);
}
@ -351,18 +331,17 @@ public class PathExecutor
{
break;
}
await Task.Delay(1000,ct);
await Task.Delay(1000, ct);
}
}
}
Logger.LogInformation("关闭未知界面检查");
},ct);
}, ct);
/*} */
}
private void InitializePathing(PathingTask task)
{
LogScreenResolution();
@ -997,7 +976,6 @@ public class PathExecutor
// 判断是否进入剧情
await AutoSkip();
}
}
private async Task AutoSkip()