mirror of
https://github.com/babalae/better-genshin-impact.git
synced 2026-03-15 07:43:20 +08:00
release all key before tp & release all key after auto fight
This commit is contained in:
@@ -332,6 +332,10 @@ public class AutoFightTask : ISoloTask
|
||||
Debug.WriteLine(e.StackTrace);
|
||||
throw;
|
||||
}
|
||||
finally
|
||||
{
|
||||
Simulation.ReleaseAllKey();
|
||||
}
|
||||
}, cts2.Token);
|
||||
|
||||
await fightTask;
|
||||
|
||||
@@ -134,6 +134,9 @@ public class TpTask(CancellationToken ct)
|
||||
/// <param name="force">强制以当前的tpX,tpY坐标进行自动传送</param>
|
||||
private async Task<(double, double)> TpOnce(double tpX, double tpY, bool force = false)
|
||||
{
|
||||
// tp 前释放所有按键
|
||||
Simulation.ReleaseAllKey();
|
||||
await Delay(20, ct);
|
||||
// 1. 确认在地图界面
|
||||
await CheckInBigMapUi();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user