mirror of
https://github.com/All-Of-Us-Mods/MiraAPI.git
synced 2026-11-19 13:17:10 +00:00
clear warnings
This commit is contained in:
2 files changed
+7
-16
No files matched your search
@@ -103,6 +103,7 @@ public class ModdedEnumOption : ModdedOption<int>
|
||||
Configuration.PopUpIconTmp,
|
||||
false);
|
||||
}
|
||||
|
||||
if (!OptionBehaviour)
|
||||
{
|
||||
return;
|
||||
|
||||
@@ -4,25 +4,15 @@ using System.Linq;
|
||||
|
||||
namespace MiraAPI.Utilities;
|
||||
|
||||
/// <summary>
|
||||
/// A comparer used to sort role/modifier IDs based on which ones are currently active.
|
||||
/// </summary>
|
||||
/// <param name="activeIds">The collection of currently active IDs.</param>
|
||||
public class BasicGuideComparer(IEnumerable<uint> activeIds) : IComparer<uint>
|
||||
{
|
||||
/// <inheritdoc/>
|
||||
public int Compare(uint x, uint y)
|
||||
{
|
||||
if (x == null && y == null)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (x == null)
|
||||
{
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (y == null)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
var xActive = activeIds.Contains(x);
|
||||
var yActive = activeIds.Contains(y);
|
||||
|
||||
@@ -38,4 +28,4 @@ public class BasicGuideComparer(IEnumerable<uint> activeIds) : IComparer<uint>
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user