SHARE
TWEET

TestFence.java

a guest Feb 16th, 2019 89 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package main.Test;
  2.  
  3. import cpw.mods.fml.common.Mod;
  4. import cpw.mods.fml.common.Mod.EventHandler;
  5. import cpw.mods.fml.common.event.FMLPreInitializationEvent;
  6. import cpw.mods.fml.common.registry.GameRegistry;
  7. import net.minecraft.block.Block;
  8. import net.minecraft.block.material.Material;
  9. import net.minecraft.creativetab.CreativeTabs;
  10.  
  11. @Mod(modid = TestFence.MODID, version = TestFence.VERSION)
  12. public class TestFence {
  13.     public static final String MODID = "TestMod";
  14.     public static final String VERSION = "1";
  15.     public static Block blockWoodenFence;
  16.  
  17.     @EventHandler
  18.     public void preInit(FMLPreInitializationEvent event) {
  19.         blockWoodenFence = new BlockWoodenFence("", Material.wood)
  20.             .setBlockName("wooden_fence")
  21.             .setBlockTextureName("minecraft:planks")
  22.             .setCreativeTab(CreativeTabs.tabBlock);
  23.         GameRegistry.registerBlock(blockWoodenFence, ItemWoodenFence.class, "blockWoodenFence");
  24.     }
  25. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top