FiE-Game/Assets/Plugins/GameDataEditor/FlagExtensions.cs
2023-07-19 18:11:02 +01:00

16 lines
No EOL
373 B
C#

// Assembly-CSharp, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null
// GameDataEditor.FlagExtensions
using System;
namespace GameDataEditor
{
public static class FlagExtensions
{
public static bool IsSet(this Enum variable, Enum flag)
{
ulong num = Convert.ToUInt64(variable);
ulong num2 = Convert.ToUInt64(flag);
return (num & num2) == num2;
}
}
}