// Path: src/main/java/com/darkona/adventurebackpack/AdventureBackpack.java
// @Mod(modid = ModInfo.MOD_ID,
//         name = ModInfo.MOD_NAME,
//         version = ModInfo.MOD_VERSION,
//         guiFactory = ModInfo.GUI_FACTORY_CLASS
// )
// public class AdventureBackpack
// {
// 
//     @SidedProxy(clientSide = ModInfo.MOD_CLIENT_PROXY, serverSide = ModInfo.MOD_SERVER_PROXY)
//     public static IProxy proxy;
//     @Mod.Instance(ModInfo.MOD_ID)
//     public static AdventureBackpack instance;
// 
//     //Static things
//     public static CreativeTabAB creativeTab = new CreativeTabAB();
// 
// 
//     public boolean chineseNewYear;
//     public boolean hannukah;
//     public String Holiday;
//     PlayerEventHandler playerEventHandler;
//     ClientEventHandler clientEventHandler;
//     GeneralEventHandler generalEventHandler;
// 
//     GuiHandler guiHandler;
// 
//     @Mod.EventHandler
//     public void preInit(FMLPreInitializationEvent event)
//     {
// 
//         int year = Calendar.getInstance().get(Calendar.YEAR), month = Calendar.getInstance().get(Calendar.MONTH) + 1, day = Calendar.getInstance().get(Calendar.DAY_OF_MONTH);
// 
//         //Configuration
//         FMLCommonHandler.instance().bus().register(new ConfigHandler());
//         ConfigHandler.init(event.getSuggestedConfigurationFile());
//         chineseNewYear = ChineseCalendar.isChineseNewYear(year, month, day);
//         hannukah = JewishCalendar.isHannukah(year, month, day);
//         Holiday = Utils.getHoliday();
// 
//         //ModStuff
//         ModItems.init();
//         ModBlocks.init();
//         ModFluids.init();
//         FluidEffectRegistry.init();
//         ModEntities.init();
//         ModNetwork.init();
//         proxy.initNetwork();
//         // EVENTS
//         playerEventHandler = new PlayerEventHandler();
//         generalEventHandler = new GeneralEventHandler();
//         clientEventHandler = new ClientEventHandler();
// 
// 
//         MinecraftForge.EVENT_BUS.register(generalEventHandler);
//         MinecraftForge.EVENT_BUS.register(clientEventHandler);
//         MinecraftForge.EVENT_BUS.register(playerEventHandler);
// 
//         FMLCommonHandler.instance().bus().register(playerEventHandler);
// 
//     }
// 
//     @Mod.EventHandler
//     public void init(FMLInitializationEvent event)
//     {
// 
//         proxy.init();
//         ModRecipes.init();
// 
//         ModWorldGen.init();
//         //GUIs
//         guiHandler = new GuiHandler();
//         NetworkRegistry.INSTANCE.registerGuiHandler(instance, guiHandler);
//     }
// 
//     @Mod.EventHandler
//     public void postInit(FMLPostInitializationEvent event)
//     {
// 
//         ConfigHandler.IS_TINKERS = Loader.isModLoaded("TConstruct");
//         ConfigHandler.IS_THAUM = Loader.isModLoaded("Thaumcraft");
//         ConfigHandler.IS_TWILIGHT = Loader.isModLoaded("TwilightForest");
//         ConfigHandler.IS_ENVIROMINE = Loader.isModLoaded("EnviroMine");
//         ConfigHandler.IS_BUILDCRAFT = Loader.isModLoaded("BuildCraft|Core");
//         ConfigHandler.IS_RAILCRAFT = Loader.isModLoaded("Railcraft");
// 
// 
//         if (ConfigHandler.IS_BUILDCRAFT)
//         {
//             LogHelper.info("Buildcraft is present. Acting accordingly");
//         }
// 
//         if (ConfigHandler.IS_TWILIGHT)
//         {
//             LogHelper.info("Twilight Forest is present. Acting accordingly");
//         }
// 
//         ConditionalFluidEffect.init();
//         ModItems.conditionalInit();
//         ModRecipes.conditionalInit();
// 
// 
//         /*
//         LogHelper.info("DUMPING FLUID INFORMATION");
//         LogHelper.info("-------------------------------------------------------------------------");
//         for(Fluid fluid : FluidRegistry.getRegisteredFluids().values())
//         {
// 
//             LogHelper.info("Unlocalized name: " + fluid.getUnlocalizedName());
//             LogHelper.info("Name: " + fluid.getName());
//             LogHelper.info("");
//         }
//         LogHelper.info("-------------------------------------------------------------------------");
//         */
//         /*
//         LogHelper.info("DUMPING TILE INFORMATION");
//         LogHelper.info("-------------------------------------------------------------------------");
//         for (Block block : GameData.getBlockRegistry().typeSafeIterable())
//         {
//             LogHelper.info("Block= " + block.getUnlocalizedName());
//         }
//         LogHelper.info("-------------------------------------------------------------------------");
//         */
//     }
// 
// }


import com.darkona.adventurebackpack.AdventureBackpack;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.relauncher.Side;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ChunkCoordinates;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.Vec3;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidRegistry;
import java.util.Calendar;

    public static int[] calculateEaster(int year)
    {


        int a = year % 19,
                b = year / 100,
                c = year % 100,
                d = b / 4,
                e = b % 4,
                g = (8 * b + 13) / 25,
                h = (19 * a + b - d - g + 15) % 30,
                j = c / 4,
                k = c % 4,
                m = (a + 11 * h) / 319,
                r = (2 * e + 2 * j - k - h + m + 32) % 7,
                n = (h - m + r + 90) / 25,
                p = (h - m + r + n + 19) % 32;

        return new int[]{n, p};
    }

    public static String getHoliday()
    {

        Calendar calendar = Calendar.getInstance();
        int year = calendar.get(Calendar.YEAR),
                month = calendar.get(Calendar.MONTH) + 1,
                day = calendar.get(Calendar.DAY_OF_MONTH);

// Path: src/main/java/com/darkona/adventurebackpack/AdventureBackpack.java
// @Mod(modid = ModInfo.MOD_ID,
//         name = ModInfo.MOD_NAME,
//         version = ModInfo.MOD_VERSION,
//         guiFactory = ModInfo.GUI_FACTORY_CLASS
// )
// public class AdventureBackpack
// {
// 
//     @SidedProxy(clientSide = ModInfo.MOD_CLIENT_PROXY, serverSide = ModInfo.MOD_SERVER_PROXY)
//     public static IProxy proxy;
//     @Mod.Instance(ModInfo.MOD_ID)
//     public static AdventureBackpack instance;
// 
//     //Static things
//     public static CreativeTabAB creativeTab = new CreativeTabAB();
// 
// 
//     public boolean chineseNewYear;
//     public boolean hannukah;
//     public String Holiday;
//     PlayerEventHandler playerEventHandler;
//     ClientEventHandler clientEventHandler;
//     GeneralEventHandler generalEventHandler;
// 
//     GuiHandler guiHandler;
// 
//     @Mod.EventHandler
//     public void preInit(FMLPreInitializationEvent event)
//     {
// 
//         int year = Calendar.getInstance().get(Calendar.YEAR), month = Calendar.getInstance().get(Calendar.MONTH) + 1, day = Calendar.getInstance().get(Calendar.DAY_OF_MONTH);
// 
//         //Configuration
//         FMLCommonHandler.instance().bus().register(new ConfigHandler());
//         ConfigHandler.init(event.getSuggestedConfigurationFile());
//         chineseNewYear = ChineseCalendar.isChineseNewYear(year, month, day);
//         hannukah = JewishCalendar.isHannukah(year, month, day);
//         Holiday = Utils.getHoliday();
// 
//         //ModStuff
//         ModItems.init();
//         ModBlocks.init();
//         ModFluids.init();
//         FluidEffectRegistry.init();
//         ModEntities.init();
//         ModNetwork.init();
//         proxy.initNetwork();
//         // EVENTS
//         playerEventHandler = new PlayerEventHandler();
//         generalEventHandler = new GeneralEventHandler();
//         clientEventHandler = new ClientEventHandler();
// 
// 
//         MinecraftForge.EVENT_BUS.register(generalEventHandler);
//         MinecraftForge.EVENT_BUS.register(clientEventHandler);
//         MinecraftForge.EVENT_BUS.register(playerEventHandler);
// 
//         FMLCommonHandler.instance().bus().register(playerEventHandler);
// 
//     }
// 
//     @Mod.EventHandler
//     public void init(FMLInitializationEvent event)
//     {
// 
//         proxy.init();
//         ModRecipes.init();
// 
//         ModWorldGen.init();
//         //GUIs
//         guiHandler = new GuiHandler();
//         NetworkRegistry.INSTANCE.registerGuiHandler(instance, guiHandler);
//     }
// 
//     @Mod.EventHandler
//     public void postInit(FMLPostInitializationEvent event)
//     {
// 
//         ConfigHandler.IS_TINKERS = Loader.isModLoaded("TConstruct");
//         ConfigHandler.IS_THAUM = Loader.isModLoaded("Thaumcraft");
//         ConfigHandler.IS_TWILIGHT = Loader.isModLoaded("TwilightForest");
//         ConfigHandler.IS_ENVIROMINE = Loader.isModLoaded("EnviroMine");
//         ConfigHandler.IS_BUILDCRAFT = Loader.isModLoaded("BuildCraft|Core");
//         ConfigHandler.IS_RAILCRAFT = Loader.isModLoaded("Railcraft");
// 
// 
//         if (ConfigHandler.IS_BUILDCRAFT)
//         {
//             LogHelper.info("Buildcraft is present. Acting accordingly");
//         }
// 
//         if (ConfigHandler.IS_TWILIGHT)
//         {
//             LogHelper.info("Twilight Forest is present. Acting accordingly");
//         }
// 
//         ConditionalFluidEffect.init();
//         ModItems.conditionalInit();
//         ModRecipes.conditionalInit();
// 
// 
//         /*
//         LogHelper.info("DUMPING FLUID INFORMATION");
//         LogHelper.info("-------------------------------------------------------------------------");
//         for(Fluid fluid : FluidRegistry.getRegisteredFluids().values())
//         {
// 
//             LogHelper.info("Unlocalized name: " + fluid.getUnlocalizedName());
//             LogHelper.info("Name: " + fluid.getName());
//             LogHelper.info("");
//         }
//         LogHelper.info("-------------------------------------------------------------------------");
//         */
//         /*
//         LogHelper.info("DUMPING TILE INFORMATION");
//         LogHelper.info("-------------------------------------------------------------------------");
//         for (Block block : GameData.getBlockRegistry().typeSafeIterable())
//         {
//             LogHelper.info("Block= " + block.getUnlocalizedName());
//         }
//         LogHelper.info("-------------------------------------------------------------------------");
//         */
//     }
// 
// }


// Path: src/main/java/com/darkona/adventurebackpack/util/Utils.java
import com.darkona.adventurebackpack.AdventureBackpack;
import cpw.mods.fml.common.FMLCommonHandler;
import cpw.mods.fml.relauncher.Side;
import net.minecraft.block.Block;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ChunkCoordinates;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.Vec3;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.common.util.ForgeDirection;
import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidRegistry;
import java.util.Calendar;


    public static int[] calculateEaster(int year)
    {


        int a = year % 19,
                b = year / 100,
                c = year % 100,
                d = b / 4,
                e = b % 4,
                g = (8 * b + 13) / 25,
                h = (19 * a + b - d - g + 15) % 30,
                j = c / 4,
                k = c % 4,
                m = (a + 11 * h) / 319,
                r = (2 * e + 2 * j - k - h + m + 32) % 7,
                n = (h - m + r + 90) / 25,
                p = (h - m + r + n + 19) % 32;

        return new int[]{n, p};
    }

    public static String getHoliday()
    {

        Calendar calendar = Calendar.getInstance();
        int year = calendar.get(Calendar.YEAR),
                month = calendar.get(Calendar.MONTH) + 1,
                day = calendar.get(Calendar.DAY_OF_MONTH);

        if (AdventureBackpack.instance.chineseNewYear) return "ChinaNewYear";