1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-21 18:10:40 +08:00

Remove unnecessary (and broken) requiresDebounce check

This commit is contained in:
Dean Herbert
2021-01-08 14:05:34 +09:00
Unverified
parent 11801d61c1
commit e156bcdcae
@@ -47,10 +47,9 @@ namespace osu.Game.Graphics.UserInterface
protected override bool OnHover(HoverEvent e)
{
bool requiresDebounce = HoverDebounceTime <= 0;
bool enoughTimePassedSinceLastPlayback = !lastPlaybackTime.Value.HasValue || Time.Current - lastPlaybackTime.Value >= HoverDebounceTime;
if (!requiresDebounce || enoughTimePassedSinceLastPlayback)
if (enoughTimePassedSinceLastPlayback)
{
sampleHover?.Play();
lastPlaybackTime.Value = Time.Current;