2018-05-11 14:31:12 +08:00
|
|
|
|
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
|
|
|
|
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
|
|
|
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using osu.Game.Beatmaps;
|
|
|
|
|
using osu.Game.Rulesets.Scoring;
|
|
|
|
|
|
|
|
|
|
namespace osu.Game.Rulesets.Objects.Legacy.Taiko
|
|
|
|
|
{
|
2018-05-11 14:42:34 +08:00
|
|
|
|
public class ConvertHitWindows : HitWindows
|
2018-05-11 14:31:12 +08:00
|
|
|
|
{
|
|
|
|
|
private static readonly IReadOnlyDictionary<HitResult, (double od0, double od5, double od10)> base_ranges = new Dictionary<HitResult, (double, double, double)>
|
|
|
|
|
{
|
|
|
|
|
{ HitResult.Great, (100, 70, 40) },
|
|
|
|
|
{ HitResult.Good, (240, 160, 100) },
|
|
|
|
|
{ HitResult.Meh, (270, 190, 140) },
|
|
|
|
|
{ HitResult.Miss, (400, 400, 400) },
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
public override void SetDifficulty(double difficulty)
|
|
|
|
|
{
|
|
|
|
|
Great = BeatmapDifficulty.DifficultyRange(difficulty, base_ranges[HitResult.Great]);
|
|
|
|
|
Good = BeatmapDifficulty.DifficultyRange(difficulty, base_ranges[HitResult.Good]);
|
|
|
|
|
Meh = BeatmapDifficulty.DifficultyRange(difficulty, base_ranges[HitResult.Meh]);
|
|
|
|
|
Miss = BeatmapDifficulty.DifficultyRange(difficulty, base_ranges[HitResult.Miss]);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|