osu! Hit Sound Copy
This also combines default hitsounds if necessary
Example
If you have excess default hitsounds (Clap, Finish, Whistle), the algorithm will drop them. You can find out which are dropped in the DEBUG logger.
If you have excess named samples (e.g. "clap.wav", "sub.wav"), the algorithm will push it as an event sample. This can also be found with the DEBUG logger.
This algorithm uses a packing method for hitsound copying. i.e. it will group as many hitsounds together as possible while maintaining their resulting sound.
Packing
Packing Algorithm
Drop all non-hitsound notes
Group by offset and loop through them
For each offsetGroup, we group them by volume.
For each volumeGroup, we attempt to snap them into available notes in our target map. This process separates default hitsounds and samples
If there are no slots:
The algorithm will drop any default hitsounds
The algorithm will sample any named samples
Return the map