diff --git a/osu.Android.props b/osu.Android.props
index 584fe0a3ef..86f4337521 100644
--- a/osu.Android.props
+++ b/osu.Android.props
@@ -51,7 +51,7 @@
-
+
diff --git a/osu.Game/Overlays/Mods/ModSelectOverlay.cs b/osu.Game/Overlays/Mods/ModSelectOverlay.cs
index 69cb3a49fc..04c424461e 100644
--- a/osu.Game/Overlays/Mods/ModSelectOverlay.cs
+++ b/osu.Game/Overlays/Mods/ModSelectOverlay.cs
@@ -6,6 +6,8 @@ using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using osu.Framework.Allocation;
+using osu.Framework.Audio;
+using osu.Framework.Audio.Sample;
using osu.Framework.Bindables;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
@@ -28,6 +30,9 @@ namespace osu.Game.Overlays.Mods
{
public const int BUTTON_WIDTH = 200;
+ protected override string PopInSampleName => "";
+ protected override string PopOutSampleName => @"SongSelect/mod-select-overlay-pop-out";
+
[Cached]
public Bindable> SelectedMods { get; private set; } = new Bindable>(Array.Empty());
@@ -101,17 +106,21 @@ namespace osu.Game.Overlays.Mods
private ShearedToggleButton? customisationButton;
+ private Sample? columnAppearSample;
+
protected ModSelectOverlay(OverlayColourScheme colourScheme = OverlayColourScheme.Green)
: base(colourScheme)
{
}
[BackgroundDependencyLoader]
- private void load(OsuGameBase game, OsuColour colours)
+ private void load(OsuGameBase game, OsuColour colours, AudioManager audio)
{
Header.Title = ModSelectOverlayStrings.ModSelectTitle;
Header.Description = ModSelectOverlayStrings.ModSelectDescription;
+ columnAppearSample = audio.Samples.Get(@"SongSelect/mod-column-pop-in");
+
AddRange(new Drawable[]
{
new ClickToReturnContainer
@@ -453,8 +462,31 @@ namespace osu.Game.Overlays.Mods
.MoveToY(0, duration, Easing.OutQuint)
.FadeIn(duration, Easing.OutQuint);
- if (!allFiltered)
- nonFilteredColumnCount += 1;
+ if (allFiltered)
+ continue;
+
+ int columnNumber = nonFilteredColumnCount;
+ Scheduler.AddDelayed(() =>
+ {
+ var channel = columnAppearSample?.GetChannel();
+ if (channel == null) return;
+
+ // Still play sound effects for off-screen columns up to a certain point.
+ if (columnNumber > 5 && !column.Active.Value) return;
+
+ // use X position of the column on screen as a basis for panning the sample
+ float balance = column.Parent.BoundingBox.Centre.X / RelativeToAbsoluteFactor.X;
+
+ // dip frequency and ramp volume of sample over the first 5 displayed columns
+ float progress = Math.Min(1, columnNumber / 5f);
+
+ channel.Frequency.Value = 1.3 - (progress * 0.3) + RNG.NextDouble(0.1);
+ channel.Volume.Value = Math.Max(progress, 0.2);
+ channel.Balance.Value = -1 + balance * 2;
+ channel.Play();
+ }, delay);
+
+ nonFilteredColumnCount += 1;
}
}
diff --git a/osu.Game/Screens/Select/FooterButton.cs b/osu.Game/Screens/Select/FooterButton.cs
index c251e94ef2..3f8cf2e13a 100644
--- a/osu.Game/Screens/Select/FooterButton.cs
+++ b/osu.Game/Screens/Select/FooterButton.cs
@@ -4,19 +4,18 @@
#nullable disable
using System;
-using osuTK;
-using osuTK.Graphics;
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Shapes;
using osu.Framework.Graphics.Sprites;
+using osu.Framework.Input.Bindings;
using osu.Framework.Input.Events;
using osu.Framework.Localisation;
-using osu.Game.Graphics.Sprites;
using osu.Game.Graphics.Containers;
+using osu.Game.Graphics.Sprites;
using osu.Game.Input.Bindings;
-using osu.Framework.Input.Bindings;
-using osu.Game.Graphics.UserInterface;
+using osuTK;
+using osuTK.Graphics;
namespace osu.Game.Screens.Select
{
@@ -68,7 +67,6 @@ namespace osu.Game.Screens.Select
private readonly Box light;
public FooterButton()
- : base(HoverSampleSet.Toolbar)
{
AutoSizeAxes = Axes.Both;
Shear = SHEAR;
diff --git a/osu.Game/osu.Game.csproj b/osu.Game/osu.Game.csproj
index ff223f5107..40c22c1b21 100644
--- a/osu.Game/osu.Game.csproj
+++ b/osu.Game/osu.Game.csproj
@@ -37,7 +37,7 @@
-
+
diff --git a/osu.iOS.props b/osu.iOS.props
index b8a4aca02e..09ae70a01f 100644
--- a/osu.iOS.props
+++ b/osu.iOS.props
@@ -62,7 +62,7 @@
-
+