Add a velocity multiplier to taiko hit objects.

This will be usable from the editor moving forward also - where every hit object can have its own velocity multiplier on top of the control point one.
This commit is contained in:
smoogipooo
2017-04-03 17:19:46 +09:00
parent aad8851460
commit d7ed392f27
3 changed files with 16 additions and 9 deletions

View File

@ -69,7 +69,7 @@ namespace osu.Game.Modes.Taiko.Objects
{
base.ApplyDefaults(timing, difficulty);
Velocity = base_distance * difficulty.SliderMultiplier * difficulty.SliderTickRate * timing.BeatLengthAt(StartTime) * timing.SpeedMultiplierAt(StartTime);
Velocity = base_distance * difficulty.SliderMultiplier * VelocityMultiplier / timing.BeatLengthAt(StartTime);
tickSpacing = timing.BeatLengthAt(StartTime) / TickRate;
RequiredGoodHits = TotalTicks * Math.Min(0.15, 0.05 + 0.10 / 6 * difficulty.OverallDifficulty);

View File

@ -19,6 +19,11 @@ namespace osu.Game.Modes.Taiko.Objects
/// </summary>
private const double base_scroll_time = 6000;
/// <summary>
/// The velocity multiplier applied to this hit object.
/// </summary>
public float VelocityMultiplier = 1;
/// <summary>
/// The time to scroll in the HitObject.
/// </summary>
@ -39,7 +44,7 @@ namespace osu.Game.Modes.Taiko.Objects
{
base.ApplyDefaults(timing, difficulty);
PreEmpt = base_scroll_time / difficulty.SliderMultiplier * timing.BeatLengthAt(StartTime) * timing.SpeedMultiplierAt(StartTime) / 1000;
PreEmpt = base_scroll_time / difficulty.SliderMultiplier * timing.BeatLengthAt(StartTime) * timing.SpeedMultiplierAt(StartTime) / VelocityMultiplier / 1000;
ControlPoint overridePoint;
Kiai = timing.TimingPointAt(StartTime, out overridePoint).KiaiMode;