Use .Equals everywhere

This commit is contained in:
smoogipoo
2018-07-02 13:23:59 +09:00
parent 9f85c55915
commit aea50e770b
4 changed files with 7 additions and 7 deletions

View File

@ -21,6 +21,6 @@ namespace osu.Game.Beatmaps.ControlPoints
public override bool Equals(ControlPoint other) public override bool Equals(ControlPoint other)
=> base.Equals(other) => base.Equals(other)
&& other is DifficultyControlPoint difficulty && other is DifficultyControlPoint difficulty
&& SpeedMultiplier == difficulty.SpeedMultiplier; && SpeedMultiplier.Equals(difficulty.SpeedMultiplier);
} }
} }

View File

@ -18,7 +18,7 @@ namespace osu.Game.Beatmaps.ControlPoints
public override bool Equals(ControlPoint other) public override bool Equals(ControlPoint other)
=> base.Equals(other) => base.Equals(other)
&& other is EffectControlPoint effect && other is EffectControlPoint effect
&& KiaiMode == effect.KiaiMode && KiaiMode.Equals(effect.KiaiMode)
&& OmitFirstBarLine == effect.OmitFirstBarLine; && OmitFirstBarLine.Equals(effect.OmitFirstBarLine);
} }
} }

View File

@ -46,7 +46,7 @@ namespace osu.Game.Beatmaps.ControlPoints
public override bool Equals(ControlPoint other) public override bool Equals(ControlPoint other)
=> base.Equals(other) => base.Equals(other)
&& other is SampleControlPoint sample && other is SampleControlPoint sample
&& SampleBank == sample.SampleBank && SampleBank.Equals(sample.SampleBank)
&& SampleVolume == sample.SampleVolume; && SampleVolume.Equals(sample.SampleVolume);
} }
} }

View File

@ -27,7 +27,7 @@ namespace osu.Game.Beatmaps.ControlPoints
public override bool Equals(ControlPoint other) public override bool Equals(ControlPoint other)
=> base.Equals(other) => base.Equals(other)
&& other is TimingControlPoint timing && other is TimingControlPoint timing
&& TimeSignature == timing.TimeSignature && TimeSignature.Equals(timing.TimeSignature)
&& BeatLength == timing.beatLength; && BeatLength.Equals(timing.BeatLength);
} }
} }