Skip to content

Conversation

@WilliamQiufeng
Copy link
Member

@WilliamQiufeng WilliamQiufeng commented May 23, 2025

Adds a field Type: HitObjectType that indicates whether the hit object is a Normal note or a Mine. With this design you would actually be able to make long mines?
When the player is pressing on the lane where a mine is present, and the timing falls into the marvelous timing window, then it is considered a miss. If the player does not press the mine and passes the marvelous window of the mine, a marvelous judgement is generated, indicating that the mine is not set off.

@WilliamQiufeng WilliamQiufeng mentioned this pull request May 23, 2025
1 task
@AiAe AiAe requested a review from Copilot June 9, 2025 21:59
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces support for mines by adding a new HitObjectType and updating scoring, replay, and hit object management to handle them appropriately.

  • Adds a new HitObjectType field and associated logic to differentiate normal notes from mines.
  • Updates scoring methods and replay handling to account for mines, including separate tracking and removal of active mines.
  • Adjusts replay key press handling and hit object retrieval to integrate the new mine behavior.

Reviewed Changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
Quaver.Tools/Commands/RecalculateCommand.cs Updated CalculateScore calls to pass additional parameters.
Quaver.API/Replays/Virtual/VirtualReplayPlayer.cs Added ActiveMines tracking and integrated mine handling logic.
Quaver.API/Replays/Replay.cs Skips mine objects during autoplay key generation.
Quaver.API/Maps/Structures/HitObjectInfo.cs Added Type property and updated judgement count logic.
Quaver.API/Maps/Qua.cs Propagates the new Type and adjusts hit object indexing.
Quaver.API/Maps/Processors/Scoring/ScoreProcessorKeys.cs Overloaded CalculateScore methods with mine support.
Quaver.API/Maps/Processors/Scoring/ScoreProcessor.cs Updated abstract CalculateScore signature for mine handling.
Quaver.API/Enums/HitObjectType.cs Introduces the new HitObjectType enum with Normal and Mine.
Comments suppressed due to low confidence (2)

Quaver.API/Replays/Virtual/VirtualReplayPlayer.cs:123

  • Consider adding a descriptive message to the ArgumentOutOfRangeException to clarify that an unsupported HitObjectType was encountered.
throw new ArgumentOutOfRangeException();

Quaver.API/Replays/Virtual/VirtualReplayPlayer.cs:463

  • Update this comment to accurately reflect that a marvelous judgement is applied for mines when not triggered, rather than a miss.
// Add a miss to the score.

@Warp9000 Warp9000 marked this pull request as draft December 6, 2025 12:08
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 4 comments.

Comments suppressed due to low confidence (1)

Quaver.API/Replays/Replay.cs:347

            foreach (var hitObject in map.HitObjects)
            {
                if (hitObject.Type is HitObjectType.Mine)
                    continue;

                // Add key press frame
                nonCombined.Add(new ReplayAutoplayFrame(hitObject, ReplayAutoplayFrameType.Press, hitObject.StartTime, KeyLaneToPressState(hitObject.Lane)));

                // If LN, add key up state at end time
                if (hitObject.IsLongNote)
                    nonCombined.Add(new ReplayAutoplayFrame(hitObject, ReplayAutoplayFrameType.Release, hitObject.EndTime - 1, KeyLaneToPressState(hitObject.Lane)));
                // If not ln, add key up frame 1ms after object.
                else
                    nonCombined.Add(new ReplayAutoplayFrame(hitObject, ReplayAutoplayFrameType.Release, hitObject.StartTime + 30, KeyLaneToPressState(hitObject.Lane)));
            }

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ESV-Sweetplum
Copy link

requesting support for utils.createhitobject to have a mine parameter

@WilliamQiufeng
Copy link
Member Author

requesting support for utils.createhitobject to have a mine parameter

This should be possible. util.createHitObject(0, 1, 2, hitsounds.Normal, hitobject_type.Mine)

@ESV-Sweetplum
Copy link

ah i see it in the other PR

my glorious king
my goat
my one
my coding genius
my development visionary

@Warp9000 Warp9000 merged commit f2ea1e6 into Quaver:master Dec 20, 2025
1 of 2 checks passed
@Warp9000 Warp9000 mentioned this pull request Dec 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants