mirror of
https://github.com/babalae/better-genshin-impact.git
synced 2026-04-15 21:03:42 +08:00
fix 修复关闭自动钓鱼后意外输出的日志
关闭自动钓鱼后停止输出相关日志
This commit is contained in:
@@ -757,7 +757,7 @@ namespace BetterGenshinImpact.GameTask.AutoFishing
|
||||
{
|
||||
Retry.Do(() =>
|
||||
{
|
||||
if (!SystemControl.IsGenshinImpactActiveByProcess())
|
||||
if (IsEnabled && !SystemControl.IsGenshinImpactActiveByProcess())
|
||||
{
|
||||
_logger.LogWarning("当前获取焦点的窗口不是原神,暂停");
|
||||
throw new RetryException("当前获取焦点的窗口不是原神");
|
||||
@@ -1069,7 +1069,7 @@ namespace BetterGenshinImpact.GameTask.AutoFishing
|
||||
{
|
||||
var prevIsExclusive = IsExclusive;
|
||||
IsExclusive = FindButtonForExclusive(content);
|
||||
if (!prevIsExclusive && IsExclusive)
|
||||
if (IsEnabled && !prevIsExclusive && IsExclusive)
|
||||
{
|
||||
_logger.LogInformation("→ {Text}", "自动钓鱼,启动!");
|
||||
var autoThrowRodEnabled = TaskContext.Instance().Config.AutoFishingConfig.AutoThrowRodEnabled;
|
||||
@@ -1127,4 +1127,4 @@ namespace BetterGenshinImpact.GameTask.AutoFishing
|
||||
// ClearDraw();
|
||||
//}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user