Bunch more moves, changes in how additional information for items works.
This commit is contained in:
@@ -33,4 +33,13 @@ public static class EnumerableHelpers
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
public static void RemoveAll<T>(this IList<T> list, Func<T, bool> predicate)
|
||||
{
|
||||
for (var i = list.Count - 1; i >= 0; i--)
|
||||
{
|
||||
if (predicate(list[i]))
|
||||
list.RemoveAt(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -55,4 +55,10 @@ public static class NumericHelpers
|
||||
var result = (ulong)value * multiplier;
|
||||
return result > uint.MaxValue ? uint.MaxValue : (uint)result;
|
||||
}
|
||||
|
||||
public static uint MultiplyOrMax(this uint value, float multiplier)
|
||||
{
|
||||
var result = value * multiplier;
|
||||
return result > uint.MaxValue ? uint.MaxValue : (uint)result;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user