1
0
mirror of https://github.com/ppy/osu.git synced 2025-03-11 01:07:23 +08:00

Add taskbar flashing when a multiplayer game is starting

This commit is contained in:
Giovanni D. 2025-03-02 00:49:04 -08:00
parent c4e37a1566
commit ec6ff240f3

View File

@ -30,6 +30,9 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
[Resolved] [Resolved]
private MultiplayerClient client { get; set; } = null!; private MultiplayerClient client { get; set; } = null!;
[Resolved]
private OsuGame? game { get; set; }
private IBindable<bool> isConnected = null!; private IBindable<bool> isConnected = null!;
private readonly TaskCompletionSource<bool> resultsReady = new TaskCompletionSource<bool>(); private readonly TaskCompletionSource<bool> resultsReady = new TaskCompletionSource<bool>();
@ -142,6 +145,7 @@ namespace osu.Game.Screens.OnlinePlay.Multiplayer
if (client.LocalUser?.State == MultiplayerUserState.Loaded) if (client.LocalUser?.State == MultiplayerUserState.Loaded)
{ {
game?.Window?.Flash();
loadingDisplay.Show(); loadingDisplay.Show();
client.ChangeState(MultiplayerUserState.ReadyForGameplay); client.ChangeState(MultiplayerUserState.ReadyForGameplay);
} }