Hide the game mouse cursor when playing osu!catch with relax mod

This commit is contained in:
Dean Herbert
2022-11-30 18:13:53 +09:00
parent 005ce1c438
commit 5ce2d6f54a
3 changed files with 32 additions and 5 deletions

View File

@ -3,15 +3,19 @@
#nullable disable
using System.Linq;
using osu.Framework.Allocation;
using osu.Framework.Graphics;
using osu.Game.Beatmaps;
using osu.Game.Rulesets.Catch.Objects;
using osu.Game.Rulesets.Catch.Objects.Drawables;
using osu.Game.Rulesets.Judgements;
using osu.Game.Rulesets.Mods;
using osu.Game.Rulesets.Objects.Drawables;
using osu.Game.Rulesets.UI;
using osu.Game.Rulesets.UI.Scrolling;
using osuTK;
using osuTK.Graphics;
namespace osu.Game.Rulesets.Catch.UI
{
@ -49,6 +53,14 @@ namespace osu.Game.Rulesets.Catch.UI
this.difficulty = difficulty;
}
protected override GameplayCursorContainer CreateCursor()
{
if (Mods.Any(m => m is ModRelax))
return new CatchRelaxCursorContainer();
return base.CreateCursor();
}
[BackgroundDependencyLoader]
private void load()
{