mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 13:32:54 +08:00
Add a check to make sure all hitobjects use relativepositionaxes
This commit is contained in:
parent
021019648e
commit
585e7ba312
@ -40,6 +40,9 @@ namespace osu.Game.Rulesets.Timing
|
||||
/// <param name="hitObject">The hit object to add.</param>
|
||||
public void Add(DrawableHitObject hitObject)
|
||||
{
|
||||
if (hitObject.RelativePositionAxes == Axes.None)
|
||||
throw new InvalidOperationException($"Make sure to set all {nameof(DrawableHitObject)}'s {nameof(RelativePositionAxes)} to some axis of relativity");
|
||||
|
||||
var target = adjustmentContainerFor(hitObject);
|
||||
|
||||
if (target == null)
|
||||
|
Loading…
Reference in New Issue
Block a user