mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 11:07:52 +08:00
Merge pull request #21288 from peppy/fix-no-network-slow-gameplay-load
Fix entering gameplay while network connection is in a bad state taking too long
This commit is contained in:
commit
cc434c9113
@ -419,7 +419,7 @@ namespace osu.Game.Online.API
|
||||
failureCount++;
|
||||
log.Add($@"API failure count is now {failureCount}");
|
||||
|
||||
if (failureCount >= 3 && State.Value == APIState.Online)
|
||||
if (failureCount >= 3)
|
||||
{
|
||||
state.Value = APIState.Failing;
|
||||
flushQueue();
|
||||
|
@ -85,7 +85,7 @@ namespace osu.Game.Screens.Play
|
||||
api.Queue(req);
|
||||
|
||||
// Generally a timeout would not happen here as APIAccess will timeout first.
|
||||
if (!tcs.Task.Wait(60000))
|
||||
if (!tcs.Task.Wait(30000))
|
||||
req.TriggerFailure(new InvalidOperationException("Token retrieval timed out (request never run)"));
|
||||
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user