2021-04-21 14:14:31 +08:00
|
|
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
|
|
|
// See the LICENCE file in the repository root for full licence text.
|
|
|
|
|
|
|
|
using osu.Game.Rulesets.Mods;
|
2023-02-09 16:57:51 +08:00
|
|
|
using osu.Game.Rulesets.Objects.Drawables;
|
2021-08-02 18:39:30 +08:00
|
|
|
using osu.Game.Rulesets.Taiko.Objects;
|
2023-02-09 16:57:51 +08:00
|
|
|
using osu.Game.Rulesets.Taiko.Objects.Drawables;
|
2021-08-02 18:39:30 +08:00
|
|
|
using osu.Game.Rulesets.Taiko.UI;
|
|
|
|
using osu.Game.Rulesets.UI;
|
2021-04-21 14:14:31 +08:00
|
|
|
|
|
|
|
namespace osu.Game.Rulesets.Taiko.Mods
|
|
|
|
{
|
2023-02-09 16:57:51 +08:00
|
|
|
public class TaikoModClassic : ModClassic, IApplicableToDrawableRuleset<TaikoHitObject>, IApplicableToDrawableHitObject
|
2021-04-21 14:14:31 +08:00
|
|
|
{
|
2021-08-02 18:39:30 +08:00
|
|
|
public void ApplyToDrawableRuleset(DrawableRuleset<TaikoHitObject> drawableRuleset)
|
|
|
|
{
|
2023-01-22 05:29:28 +08:00
|
|
|
var drawableTaikoRuleset = (DrawableTaikoRuleset)drawableRuleset;
|
2023-04-27 00:05:47 +08:00
|
|
|
drawableTaikoRuleset.LockPlayfieldAspectRange.Value = false;
|
2022-04-03 06:31:51 +08:00
|
|
|
|
|
|
|
var playfield = (TaikoPlayfield)drawableRuleset.Playfield;
|
|
|
|
playfield.ClassicHitTargetPosition.Value = true;
|
2021-08-02 18:39:30 +08:00
|
|
|
}
|
2023-02-09 16:57:51 +08:00
|
|
|
|
|
|
|
public void ApplyToDrawableHitObject(DrawableHitObject drawable)
|
|
|
|
{
|
2023-02-12 15:08:23 +08:00
|
|
|
if (drawable is DrawableTaikoHitObject hit)
|
|
|
|
hit.SnapJudgementLocation = true;
|
2023-02-09 16:57:51 +08:00
|
|
|
}
|
2021-04-21 14:14:31 +08:00
|
|
|
}
|
|
|
|
}
|