Fixes a bug that allowed for selecting the same mod twice in multiplayer
if the playlist entry has non-default settings for a required mod.
This happens due to a strict equality mod check in the mod set
compatibility check function, which only considers mods duplicates if
their settings are exactly the same. Replacing with a more lenient
`Type` check fixes this.
Adds a regression test for this behavior
Fixes https://github.com/ppy/osu/issues/37625.
---------
Co-authored-by: Bartłomiej Dach <dach.bartlomiej@gmail.com>
As it turns out, C# 8 provides an attribute that allows annotating that
an `out` parameter's nullability depends on the method's return value,
which is exactly what is desired here.