Guest User

AgricraftureMain

a guest
Sep 21st, 2012
58
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package KBI.agricrafture.core;
  2.  
  3. import KBI.agricrafture.api.*;
  4.  
  5. import java.util.logging.Level;
  6. import net.minecraft.src.*;
  7. import net.minecraftforge.common.*;
  8. import net.minecraftforge.oredict.*;
  9. import net.minecraftforge.event.*;
  10. import cpw.mods.fml.common.*;
  11. import net.minecraftforge.common.Configuration;
  12. import net.minecraftforge.common.MinecraftForge;
  13. import cpw.mods.fml.common.FMLLog;
  14. import cpw.mods.fml.common.Mod;
  15. import cpw.mods.fml.common.Mod.Init;
  16. import cpw.mods.fml.common.Mod.Instance;
  17. import cpw.mods.fml.common.Mod.PostInit;
  18. import cpw.mods.fml.common.Mod.PreInit;
  19. import cpw.mods.fml.common.SidedProxy;
  20. import cpw.mods.fml.common.event.FMLInitializationEvent;
  21. import cpw.mods.fml.common.event.FMLPostInitializationEvent;
  22. import cpw.mods.fml.common.event.FMLPreInitializationEvent;
  23. import cpw.mods.fml.common.network.NetworkMod;
  24. import cpw.mods.fml.common.network.NetworkRegistry;
  25. import cpw.mods.fml.common.registry.*;
  26. import java.lang.Integer;
  27. import java.io.File;
  28. import java.io.IOException;
  29. import java.util.ArrayList;
  30. import java.util.List;
  31.  
  32. @Mod( modid = "KBIAgricrafture", name="Agricrafture", version="0.0.0.1")
  33. @NetworkMod(channels = {"AgricraftureCore"}, packetHandler = PacketHandlerCore.class, clientSideRequired = true, serverSideRequired = false)
  34. public class AgricraftureMain
  35. {
  36.  
  37.     @SidedProxy(clientSide = "KBI.agricrafture.core.ClientProxy", serverSide = "KBI.agricrafture.core.CommonProxy")
  38.     public static CommonProxy proxy;
  39.    
  40.     @Instance("Agricrafture")
  41.     public static AgricraftureMain instance;
  42.    
  43.     public static Configuration config;
  44.    
  45.     public static Block culinaryTable;
  46.    
  47.     @Init
  48.     public void load(FMLInitializationEvent event)
  49.     {
  50.         NetworkRegistry.instance().registerGuiHandler(instance, new CulinaryGuiHandler());
  51.         GameRegistry.registerTileEntity(TileEntityCulinary.class, "CulinaryBoard");
  52.        
  53.         culinaryTable = new BlockCulinary(Configurator.culinaryTableId);
  54.         GameRegistry.registerBlock(culinaryTable);
  55.         LanguageRegistry.addName(culinaryTable, "Culinary Board");
  56.         GameRegistry.addRecipe(new ItemStack(culinaryTable, 2), new Object[]
  57.                 {
  58.                     "xx", Character.valueOf('x'), Block.woodSingleSlab
  59.                 });
  60.     }
  61.    
  62.     @PreInit
  63.      public void preLoad(FMLPreInitializationEvent evt)
  64.      {
  65.         instance = this;
  66.         Configurator.init(config, evt.getSuggestedConfigurationFile());
  67.      }
  68.      
  69. }
RAW Paste Data