diff --git a/osu.Game/Screens/Edit/Compose/HitObjectContainerEventQueue.cs b/osu.Game/Screens/Edit/Compose/HitObjectContainerEventQueue.cs
index 7c21573b18..363f08cb41 100644
--- a/osu.Game/Screens/Edit/Compose/HitObjectContainerEventQueue.cs
+++ b/osu.Game/Screens/Edit/Compose/HitObjectContainerEventQueue.cs
@@ -68,6 +68,9 @@ namespace osu.Game.Screens.Edit.Compose
switch (existingEvent, newEvent)
{
+ // This mostly exists as a safeguard to ensure that the sequence: Began -> { Finished -> Began } -> Finished, where { ... } indicates a transferral within a single frame,
+ // correctly leads into a final "Finished" state. It's unlikely for this to happen normally as it requires the hitobject usage to finish (for the final time)
+ // immediately after the HitObjectContainer updates lifetime, but it's not inconceivable to occur with the Editor's scheduling and execution order.
case (EventType.Transferred, EventType.Finished):
pendingEvents[hitObject] = EventType.Finished;
break;
@@ -117,8 +120,24 @@ namespace osu.Game.Screens.Edit.Compose
private enum EventType
{
+ ///
+ /// A has started being used by a .
+ ///
Began,
+
+ ///
+ /// A has finished being used by a .
+ ///
Finished,
+
+ ///
+ /// An internal intermediate state that occurs when a has finished being used by one
+ /// and started being used by another in the same frame. The may be the same instance in both cases.
+ ///
+ ///
+ /// This usually occurs when a is transferred between s,
+ /// but also occurs if the dies and becomes alive again in the same frame within the same .
+ ///
Transferred
}
}