From 039f8e62421d13d23f532e146cadd97ec89e78d1 Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Fri, 24 Nov 2023 10:25:23 +0900 Subject: [PATCH] Add note about shared code --- osu.Game.Rulesets.Catch/Objects/CatchHitObject.cs | 2 ++ osu.Game.Rulesets.Osu/Objects/OsuHitObject.cs | 2 ++ 2 files changed, 4 insertions(+) diff --git a/osu.Game.Rulesets.Catch/Objects/CatchHitObject.cs b/osu.Game.Rulesets.Catch/Objects/CatchHitObject.cs index d122758a4e..17ff8afb87 100644 --- a/osu.Game.Rulesets.Catch/Objects/CatchHitObject.cs +++ b/osu.Game.Rulesets.Catch/Objects/CatchHitObject.cs @@ -157,6 +157,8 @@ protected override void ApplyDefaultsToSelf(ControlPointInfo controlPointInfo, I public void UpdateComboInformation(IHasComboInformation? lastObj) { + // Note that this implementation is shared with the osu! ruleset's implementation. + // If a change is made here, OsuHitObject.cs should also be updated. ComboIndex = lastObj?.ComboIndex ?? 0; ComboIndexWithOffsets = lastObj?.ComboIndexWithOffsets ?? 0; IndexInCurrentCombo = (lastObj?.IndexInCurrentCombo + 1) ?? 0; diff --git a/osu.Game.Rulesets.Osu/Objects/OsuHitObject.cs b/osu.Game.Rulesets.Osu/Objects/OsuHitObject.cs index 716c34d024..21f7b4b22d 100644 --- a/osu.Game.Rulesets.Osu/Objects/OsuHitObject.cs +++ b/osu.Game.Rulesets.Osu/Objects/OsuHitObject.cs @@ -161,6 +161,8 @@ protected override void ApplyDefaultsToSelf(ControlPointInfo controlPointInfo, I public void UpdateComboInformation(IHasComboInformation? lastObj) { + // Note that this implementation is shared with the osu!catch ruleset's implementation. + // If a change is made here, CatchHitObject.cs should also be updated. ComboIndex = lastObj?.ComboIndex ?? 0; ComboIndexWithOffsets = lastObj?.ComboIndexWithOffsets ?? 0; IndexInCurrentCombo = (lastObj?.IndexInCurrentCombo + 1) ?? 0;