1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-22 22:20:53 +08:00

Log important message if user imported bad-checksum beatmap

This commit is contained in:
Salman Ahmed
2021-01-17 22:04:12 +03:00
Unverified
parent 0425a659a8
commit ccef50e2a2
@@ -4,6 +4,7 @@
using System;
using System.Linq;
using osu.Framework.Bindables;
using osu.Framework.Logging;
using osu.Game.Beatmaps;
namespace osu.Game.Online.Rooms
@@ -34,6 +35,15 @@ namespace osu.Game.Online.Rooms
}
protected override bool VerifyDatabasedModel(BeatmapSetInfo databasedSet)
{
var verified = verifyDatabasedModel(databasedSet);
if (!verified)
Logger.Log("The imported beatmapset does not match the online version.", LoggingTarget.Runtime, LogLevel.Important);
return verified;
}
private bool verifyDatabasedModel(BeatmapSetInfo databasedSet)
{
int? beatmapId = SelectedItem.Value.Beatmap.Value.OnlineBeatmapID;
string checksum = SelectedItem.Value.Beatmap.Value.MD5Hash;