    001    package net.minecraftforge.client;
    002
    003    import net.minecraft.src.EnumGameType;
    004    import net.minecraft.src.EnumOS;
    005    import net.minecraft.src.EnumOptions;
    006    import net.minecraft.src.EnumRarity;
    007    import net.minecraftforge.common.EnumHelper;
    008
    009    public class EnumHelperClient extends EnumHelper
    010    {
    011
    012        private static Class[][] clentTypes =
    013        {
    014            {EnumGameType.class, int.class, String.class},
    015            {EnumOptions.class, String.class, boolean.class, boolean.class},
    016            {EnumOS.class},
    017            {EnumRarity.class, int.class, String.class}
    018        };
    019
    020        public static EnumGameType addGameType(String name, int id, String displayName)
    021        {
    022            return addEnum(EnumGameType.class, name, id, displayName);
    023        }
    024
    025        public static EnumOptions addOptions(String name, String langName, boolean isSlider, boolean isToggle)
    026        {
    027            return addEnum(EnumOptions.class, name, langName, isSlider, isToggle);
    028        }
    029
    030        public static EnumOS addOS2(String name)
    031        {
    032            return addEnum(EnumOS.class, name);
    033        }
    034
    035        public static EnumRarity addRarity(String name, int color, String displayName)
    036        {
    037            return addEnum(EnumRarity.class, name, color, displayName);
    038        }
    039
    040        public static <T extends Enum<? >> T addEnum(Class<T> enumType, String enumName, Object... paramValues)
    041        {
    042            return addEnum(clentTypes, enumType, enumName, paramValues);
    043        }
    044    }