mirror of
https://github.com/osukey/osukey.git
synced 2025-08-08 09:03:50 +09:00
Allow transfer of previously loaded background between WorkingBeatmaps
This commit is contained in:
@ -94,6 +94,9 @@ namespace osu.Game.Beatmaps
|
|||||||
{
|
{
|
||||||
if (track != null && BeatmapInfo.AudioEquals(other.BeatmapInfo))
|
if (track != null && BeatmapInfo.AudioEquals(other.BeatmapInfo))
|
||||||
other.track = track;
|
other.track = track;
|
||||||
|
|
||||||
|
if (background != null && BeatmapInfo.BackgroundEquals(other.BeatmapInfo))
|
||||||
|
other.background = background;
|
||||||
}
|
}
|
||||||
|
|
||||||
public virtual void Dispose()
|
public virtual void Dispose()
|
||||||
|
@ -93,5 +93,9 @@ namespace osu.Game.Database
|
|||||||
public bool AudioEquals(BeatmapInfo other) => other != null && BeatmapSet != null && other.BeatmapSet != null &&
|
public bool AudioEquals(BeatmapInfo other) => other != null && BeatmapSet != null && other.BeatmapSet != null &&
|
||||||
BeatmapSet.Path == other.BeatmapSet.Path &&
|
BeatmapSet.Path == other.BeatmapSet.Path &&
|
||||||
(Metadata ?? BeatmapSet.Metadata).AudioFile == (other.Metadata ?? other.BeatmapSet.Metadata).AudioFile;
|
(Metadata ?? BeatmapSet.Metadata).AudioFile == (other.Metadata ?? other.BeatmapSet.Metadata).AudioFile;
|
||||||
|
|
||||||
|
public bool BackgroundEquals(BeatmapInfo other) => other != null && BeatmapSet != null && other.BeatmapSet != null &&
|
||||||
|
BeatmapSet.Path == other.BeatmapSet.Path &&
|
||||||
|
(Metadata ?? BeatmapSet.Metadata).BackgroundFile == (other.Metadata ?? other.BeatmapSet.Metadata).BackgroundFile;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user