public static LiquidTypeClass MapToLiquidTypeClass(int type) { if (type > 20) throw new ArgumentOutOfRangeException("Algorithm does not generally support types greater than 20 (Naxxramas slime)"); return (LiquidTypeClass)((type - 1) & 3); }