+EA 23.324 Nightly - Plugin.BaseCore โ
July 1, 2026
2 files modified.
Important Changes โ
None.
ClassExtension โ
public static string Parentheses(this string str)
cs
public static string Bracket(this string str, int type = 0)
{
return type switch
{
-1 => str,
1 => "ใ" + str + "ใ",
2 => "ใ" + str + "ใ",
3 => "ใ" + str + "ใ",
4 => "(" + str + ")",
_ => "_bracketLeft".lang() + str + "_bracketRight".lang(),
};
switch (type)
{
case -1:
return str;
case 1:
case 2:
case 3:
case 4:
case 5:
{
string[] list = Lang.GetList("bracket_" + type);
return list[0] + str + list[1];
}
default:
return "_bracketLeft".lang() + str + "_bracketRight".lang();
}
}
public static byte[] ToBytes(this BitArray bits)MathEx โ
public static int ClampToInt(long a, int b = int.MaxValue)
cs
return (int)a;
}
public static int ClampToInt(long a, int min, int max)
{
if (a > max)
{
return max;
}
if (a < min)
{
return min;
}
return (int)a;
}
public static long Max(long a, long b)
{
if (a >= b)