mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 17:43:05 +08:00
Add toggle for tournament client "auto progression" behaviour
Addresses https://github.com/ppy/osu/discussions/20038.
This commit is contained in:
parent
1908a2e394
commit
93bc4b9294
@ -40,5 +40,7 @@ namespace osu.Game.Tournament.Models
|
||||
MinValue = 3,
|
||||
MaxValue = 4,
|
||||
};
|
||||
|
||||
public Bindable<bool> AutoProgressScreens = new BindableBool(true);
|
||||
}
|
||||
}
|
||||
|
@ -199,16 +199,19 @@ namespace osu.Game.Tournament.Screens.Gameplay
|
||||
case TourneyState.Idle:
|
||||
contract();
|
||||
|
||||
const float delay_before_progression = 4000;
|
||||
|
||||
// if we've returned to idle and the last screen was ranking
|
||||
// we should automatically proceed after a short delay
|
||||
if (lastState == TourneyState.Ranking && !warmup.Value)
|
||||
if (LadderInfo.AutoProgressScreens.Value)
|
||||
{
|
||||
if (CurrentMatch.Value?.Completed.Value == true)
|
||||
scheduledOperation = Scheduler.AddDelayed(() => { sceneManager?.SetScreen(typeof(TeamWinScreen)); }, delay_before_progression);
|
||||
else if (CurrentMatch.Value?.Completed.Value == false)
|
||||
scheduledOperation = Scheduler.AddDelayed(() => { sceneManager?.SetScreen(typeof(MapPoolScreen)); }, delay_before_progression);
|
||||
const float delay_before_progression = 4000;
|
||||
|
||||
// if we've returned to idle and the last screen was ranking
|
||||
// we should automatically proceed after a short delay
|
||||
if (lastState == TourneyState.Ranking && !warmup.Value)
|
||||
{
|
||||
if (CurrentMatch.Value?.Completed.Value == true)
|
||||
scheduledOperation = Scheduler.AddDelayed(() => { sceneManager?.SetScreen(typeof(TeamWinScreen)); }, delay_before_progression);
|
||||
else if (CurrentMatch.Value?.Completed.Value == false)
|
||||
scheduledOperation = Scheduler.AddDelayed(() => { sceneManager?.SetScreen(typeof(MapPoolScreen)); }, delay_before_progression);
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
|
@ -197,10 +197,13 @@ namespace osu.Game.Tournament.Screens.MapPool
|
||||
|
||||
setNextMode();
|
||||
|
||||
if (pickType == ChoiceType.Pick && CurrentMatch.Value.PicksBans.Any(i => i.Type == ChoiceType.Pick))
|
||||
if (LadderInfo.AutoProgressScreens.Value)
|
||||
{
|
||||
scheduledChange?.Cancel();
|
||||
scheduledChange = Scheduler.AddDelayed(() => { sceneManager?.SetScreen(typeof(GameplayScreen)); }, 10000);
|
||||
if (pickType == ChoiceType.Pick && CurrentMatch.Value.PicksBans.Any(i => i.Type == ChoiceType.Pick))
|
||||
{
|
||||
scheduledChange?.Cancel();
|
||||
scheduledChange = Scheduler.AddDelayed(() => { sceneManager?.SetScreen(typeof(GameplayScreen)); }, 10000);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -131,6 +131,12 @@ namespace osu.Game.Tournament.Screens.Setup
|
||||
windowSize.Value = new Size((int)(height * aspect_ratio / TournamentSceneManager.STREAM_AREA_WIDTH * TournamentSceneManager.REQUIRED_WIDTH), height);
|
||||
}
|
||||
},
|
||||
new LabelledSwitchButton
|
||||
{
|
||||
Label = "Auto advance screens",
|
||||
Description = "Screens will progress automatically from gameplay -> results -> map pool",
|
||||
Current = LadderInfo.AutoProgressScreens,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user