Commit 5570eba0 authored by 潘栩锋's avatar 潘栩锋 🚴

修复 GM_Disconnected 写错了, 之前 无法 autoscan。

parent 9512dcc5
...@@ -288,7 +288,13 @@ namespace FLY.Thick.Base.Server ...@@ -288,7 +288,13 @@ namespace FLY.Thick.Base.Server
if (isReadyToAutoScan) if (isReadyToAutoScan)
{ {
//需要自动扫描 //需要自动扫描
if (stopwatch.Elapsed > TimeSpan.FromMinutes(3)) if (stopwatch.Elapsed < TimeSpan.FromSeconds(30)) {
isReadyToAutoScan = false;
stopwatch.Stop();
//30秒内又连上了,直接重启
mGMAutoScan.Start(0);
}
else if (stopwatch.Elapsed < TimeSpan.FromMinutes(3))
{ {
isReadyToAutoScan = false; isReadyToAutoScan = false;
stopwatch.Stop(); stopwatch.Stop();
...@@ -357,8 +363,16 @@ namespace FLY.Thick.Base.Server ...@@ -357,8 +363,16 @@ namespace FLY.Thick.Base.Server
} }
public bool Start(int delay) public bool Start(int delay)
{ {
Delay = delay; if (delay <= 0)
return Start(); {
ReScan();
return true;
}
else
{
Delay = delay;
return Start();
}
} }
public override bool Start() public override bool Start()
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment