started to work on tester item
This commit is contained in:
parent
8039dacff8
commit
fd5806d499
2 changed files with 30 additions and 0 deletions
|
@ -9,6 +9,7 @@
|
|||
package buildcraft.tests;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.Item;
|
||||
|
||||
import cpw.mods.fml.common.Mod;
|
||||
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
|
||||
|
@ -23,6 +24,8 @@ public class BuildCraftTests extends BuildCraftMod {
|
|||
|
||||
public static Block blockTestPathfinding;
|
||||
|
||||
public static Item tester;
|
||||
|
||||
@Mod.Instance("BuildCraft|Tests")
|
||||
public static BuildCraftTests instance;
|
||||
|
||||
|
@ -31,5 +34,9 @@ public class BuildCraftTests extends BuildCraftMod {
|
|||
blockTestPathfinding = new BlockTestPathfinding();
|
||||
CoreProxy.proxy.registerBlock(blockTestPathfinding);
|
||||
CoreProxy.proxy.registerTileEntity(TileTestPathfinding.class, "net.minecraft.src.builders.TileTestPathfinding");
|
||||
|
||||
tester = new ItemTester();
|
||||
tester.setUnlocalizedName("tester");
|
||||
CoreProxy.proxy.registerItem(tester);
|
||||
}
|
||||
}
|
||||
|
|
23
tests/buildcraft/tests/ItemTester.java
Executable file
23
tests/buildcraft/tests/ItemTester.java
Executable file
|
@ -0,0 +1,23 @@
|
|||
package buildcraft.tests;
|
||||
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.item.Item;
|
||||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import buildcraft.core.CreativeTabBuildCraft;
|
||||
|
||||
public class ItemTester extends Item {
|
||||
|
||||
public ItemTester() {
|
||||
setCreativeTab(CreativeTabBuildCraft.ITEMS.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void registerIcons(IIconRegister par1IconRegister) {
|
||||
this.itemIcon = par1IconRegister.registerIcon("buildcraft:tester");
|
||||
}
|
||||
|
||||
}
|
Loading…
Reference in a new issue