use of pl.asie.charset.lib.material.ItemMaterialRegistry in project Charset by CharsetMC.
the class CharsetMiscShards method init.
@Mod.EventHandler
public void init(FMLInitializationEvent event) {
ItemMaterialRegistry imr = ItemMaterialRegistry.INSTANCE;
ItemStack shard = new ItemStack(shardItem, 1, 0);
OreDictionary.registerOre("shardGlass", new ItemStack(shardItem, 1, OreDictionary.WILDCARD_VALUE));
OreDictionary.registerOre("shardGlassColorless", shard);
imr.registerRelation(imr.getOrCreateMaterial(new ItemStack(Blocks.GLASS)), imr.getOrCreateMaterial(shard), "shard", "block");
for (int i = 0; i < 16; i++) {
ItemStack shardColored = new ItemStack(shardItem, 1, i + 1);
imr.registerRelation(imr.getOrCreateMaterial(new ItemStack(Blocks.STAINED_GLASS, 1, i)), imr.getOrCreateMaterial(shardColored), "shard", "block");
OreDictionary.registerOre(ColorUtils.getOreDictEntry("shardGlass", EnumDyeColor.byMetadata(i)), shardColored);
}
}
Aggregations