mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 06:52:55 +08:00
Merge branch 'master' into hit-shake
This commit is contained in:
commit
f35ea18755
@ -93,6 +93,9 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
||||
base.AccentColour = value;
|
||||
Body.AccentColour = AccentColour;
|
||||
Ball.AccentColour = AccentColour;
|
||||
if (HasNestedHitObjects)
|
||||
foreach (var drawableHitObject in NestedHitObjects)
|
||||
drawableHitObject.AccentColour = AccentColour;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -54,9 +54,9 @@ namespace osu.Game.Rulesets.Osu.Objects
|
||||
|
||||
public virtual bool NewCombo { get; set; }
|
||||
|
||||
public int IndexInCurrentCombo { get; set; }
|
||||
public virtual int IndexInCurrentCombo { get; set; }
|
||||
|
||||
public int ComboIndex { get; set; }
|
||||
public virtual int ComboIndex { get; set; }
|
||||
|
||||
public bool LastInCombo { get; set; }
|
||||
|
||||
|
@ -26,6 +26,28 @@ namespace osu.Game.Rulesets.Osu.Objects
|
||||
public Vector2 StackedPositionAt(double t) => StackedPosition + this.CurvePositionAt(t);
|
||||
public override Vector2 EndPosition => Position + this.CurvePositionAt(1);
|
||||
|
||||
public override int ComboIndex
|
||||
{
|
||||
get => base.ComboIndex;
|
||||
set
|
||||
{
|
||||
base.ComboIndex = value;
|
||||
foreach (var n in NestedHitObjects.OfType<IHasComboInformation>())
|
||||
n.ComboIndex = value;
|
||||
}
|
||||
}
|
||||
|
||||
public override int IndexInCurrentCombo
|
||||
{
|
||||
get => base.IndexInCurrentCombo;
|
||||
set
|
||||
{
|
||||
base.IndexInCurrentCombo = value;
|
||||
foreach (var n in NestedHitObjects.OfType<IHasComboInformation>())
|
||||
n.IndexInCurrentCombo = value;
|
||||
}
|
||||
}
|
||||
|
||||
public SliderCurve Curve { get; } = new SliderCurve();
|
||||
|
||||
public List<Vector2> ControlPoints
|
||||
@ -147,7 +169,8 @@ namespace osu.Game.Rulesets.Osu.Objects
|
||||
var distanceProgress = d / length;
|
||||
var timeProgress = reversed ? 1 - distanceProgress : distanceProgress;
|
||||
|
||||
var firstSample = Samples.FirstOrDefault(s => s.Name == SampleInfo.HIT_NORMAL) ?? Samples.FirstOrDefault(); // TODO: remove this when guaranteed sort is present for samples (https://github.com/ppy/osu/issues/1933)
|
||||
var firstSample = Samples.FirstOrDefault(s => s.Name == SampleInfo.HIT_NORMAL)
|
||||
?? Samples.FirstOrDefault(); // TODO: remove this when guaranteed sort is present for samples (https://github.com/ppy/osu/issues/1933)
|
||||
var sampleList = new List<SampleInfo>();
|
||||
|
||||
if (firstSample != null)
|
||||
|
@ -66,8 +66,8 @@ namespace osu.Game.Beatmaps
|
||||
|
||||
// General
|
||||
public int AudioLeadIn { get; set; }
|
||||
public bool Countdown { get; set; }
|
||||
public float StackLeniency { get; set; }
|
||||
public bool Countdown { get; set; } = true;
|
||||
public float StackLeniency { get; set; } = 0.7f;
|
||||
public bool SpecialStyle { get; set; }
|
||||
|
||||
public int RulesetID { get; set; }
|
||||
|
@ -1,26 +0,0 @@
|
||||
// Copyright (c) 2007-2018 ppy Pty Ltd <contact@ppy.sh>.
|
||||
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||
|
||||
namespace osu.Game.Rulesets.Objects.Types
|
||||
{
|
||||
/// <summary>
|
||||
/// A HitObject that is part of a combo and has extended information about its position relative to other combo objects.
|
||||
/// </summary>
|
||||
public interface IHasComboIndex : IHasCombo
|
||||
{
|
||||
/// <summary>
|
||||
/// The offset of this hitobject in the current combo.
|
||||
/// </summary>
|
||||
int IndexInCurrentCombo { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// The offset of this hitobject in the current combo.
|
||||
/// </summary>
|
||||
int ComboIndex { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Whether this is the last object in the current combo.
|
||||
/// </summary>
|
||||
bool LastInCombo { get; set; }
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user