diff --git a/Quaver.API/Enums/ModIdentifier.cs b/Quaver.API/Enums/ModIdentifier.cs
index 541559ff0..295abd236 100644
--- a/Quaver.API/Enums/ModIdentifier.cs
+++ b/Quaver.API/Enums/ModIdentifier.cs
@@ -62,6 +62,7 @@ public enum ModIdentifier : long
Speed195X = 1L << 42, // Speed 1.95x
HeatlthAdjust = 1L << 43, // Test mod for making long note windows easier
NoMiss = 1L << 44, // You miss, you die
+ NoMines = 1L << 45, // Removes mines from the map
SpeedMods = Speed05X | Speed055X | Speed06X | Speed065X | Speed07X | Speed075X | Speed08X | Speed085X | Speed09X | Speed095X | Speed105X | Speed11X | Speed115X | Speed12X | Speed125X | Speed13X | Speed135X | Speed14X | Speed145X | Speed15X | Speed155X | Speed16X | Speed165X | Speed17X | Speed175X | Speed18X | Speed185X | Speed19X | Speed195X | Speed20X
}
diff --git a/Quaver.API/Helpers/ModHelper.cs b/Quaver.API/Helpers/ModHelper.cs
index 26d17897e..b613d157a 100644
--- a/Quaver.API/Helpers/ModHelper.cs
+++ b/Quaver.API/Helpers/ModHelper.cs
@@ -167,6 +167,9 @@ public static string GetModsString(ModIdentifier mods)
case ModIdentifier.NoMiss:
modStrings.Add("NM");
break;
+ case ModIdentifier.NoMines:
+ modStrings.Add("NMN");
+ break;
default:
throw new ArgumentOutOfRangeException($"Short string for ModIdentifier: {mod} does not exist.");
}
diff --git a/Quaver.API/Maps/Qua.cs b/Quaver.API/Maps/Qua.cs
index 8c4c215a3..52a81439f 100644
--- a/Quaver.API/Maps/Qua.cs
+++ b/Quaver.API/Maps/Qua.cs
@@ -840,6 +840,11 @@ public void ReplaceLongNotesWithRegularNotes()
temp.EndTime = 0;
}
+ ///
+ /// Removes all mines from the map.
+ ///
+ public void RemoveMines() => HitObjects = HitObjects.Where(x => x.Type != HitObjectType.Mine).ToList();
+
///
/// Replaces regular notes with long notes and vice versa.
///
@@ -1014,6 +1019,9 @@ public void ApplyInverse()
/// a list of mods to apply
public void ApplyMods(ModIdentifier mods)
{
+ if (mods.HasFlag(ModIdentifier.NoMines))
+ RemoveMines();
+
if (mods.HasFlag(ModIdentifier.NoLongNotes))
ReplaceLongNotesWithRegularNotes();
@@ -1543,4 +1551,4 @@ private int MaxObjectTime()
return max;
}
}
-}
\ No newline at end of file
+}