use of com.mcmoddev.lib.material.MMDMaterial in project BaseMetals by MinecraftModDevelopmentMods.
the class VanillaItems method addDiamondBits.
private static void addDiamondBits() {
final MMDMaterial diamond = Materials.getMaterialByName(MaterialNames.DIAMOND);
if (Materials.hasMaterial(MaterialNames.DIAMOND)) {
create(Names.BLEND, diamond);
create(Names.NUGGET, diamond);
create(Names.POWDER, diamond);
create(Names.SMALLBLEND, diamond);
create(Names.SMALLPOWDER, diamond);
create(Names.ARROW, diamond);
create(Names.BOLT, diamond);
create(Names.BOW, diamond);
create(Names.CRACKHAMMER, diamond);
create(Names.CROSSBOW, diamond);
create(Names.DOOR, diamond);
create(Names.FISHING_ROD, diamond);
create(Names.SHEARS, diamond);
create(Names.SHIELD, diamond);
create(Names.SLAB, diamond);
create(Names.ROD, diamond);
create(Names.GEAR, diamond);
create(Names.SCYTHE, diamond);
}
}
use of com.mcmoddev.lib.material.MMDMaterial in project BaseMetals by MinecraftModDevelopmentMods.
the class VanillaItems method addWoodBits.
private static void addWoodBits() {
final MMDMaterial wood = Materials.getMaterialByName(MaterialNames.WOOD);
if (Materials.hasMaterial(MaterialNames.WOOD)) {
create(Names.CRACKHAMMER, wood);
create(Names.GEAR, wood);
create(Names.SCYTHE, wood);
}
}
use of com.mcmoddev.lib.material.MMDMaterial in project BaseMetals by MinecraftModDevelopmentMods.
the class FallbackGeneratorData method addMaterial.
/**
* @param materialName
* @param blockName
* @param dimension
*/
public void addMaterial(@Nonnull final String materialName, @Nonnull final String blockName, @Nullable final Integer dimension) {
final MMDMaterial mat = Materials.getMaterialByName(materialName);
final int targetDim = dimension != null ? dimension : Integer.MIN_VALUE;
final Map<MMDMaterial, List<String>> blockMap = materials.getOrDefault(targetDim, new HashMap<MMDMaterial, List<String>>());
final List<String> blocks = blockMap.getOrDefault(mat, new ArrayList<>());
if (!blocks.contains(blockName)) {
blocks.add(blockName);
}
blockMap.put(mat, blocks);
materials.put(targetDim, blockMap);
}
use of com.mcmoddev.lib.material.MMDMaterial in project BaseMetals by MinecraftModDevelopmentMods.
the class ArmorRepair method parse.
@Override
public IRecipe parse(final JsonContext context, final JsonObject json) {
final String material = JsonUtils.getString(json, "material");
final String type = JsonUtils.getString(json, "armorType").toLowerCase();
final MMDMaterial mat = Materials.getMaterialByName(material.toLowerCase());
switch(type) {
case "boots":
return new BootsRepairRecipe(mat);
case "leggings":
return new LeggingsRepairRecipe(mat);
case "chestplate":
return new ChestplateRepairRecipe(mat);
case "helmet":
return new HelmetRepairRecipe(mat);
case "shield":
return new ShieldRepairRecipe(mat);
default:
throw new JsonSyntaxException("Unknown Armor Type '" + type + "' specified!");
}
}
use of com.mcmoddev.lib.material.MMDMaterial in project BaseMetals by MinecraftModDevelopmentMods.
the class Recipes method initPureVanillaCrusherRecipes.
protected static void initPureVanillaCrusherRecipes() {
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.STONE, // Stone to Cobblestone
new ItemStack(net.minecraft.init.Blocks.COBBLESTONE, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.STONEBRICK, // Stone Bricks to Cobblestone
new ItemStack(net.minecraft.init.Blocks.COBBLESTONE, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.STONE_SLAB, 1, 0), // Stone Slab to Cobblestone Slab
new ItemStack(net.minecraft.init.Blocks.STONE_SLAB, 1, 3));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.STONE_SLAB, 1, 5), // Stone Bricks Slab to Cobblestone Slab
new ItemStack(net.minecraft.init.Blocks.STONE_SLAB, 1, 3));
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.COBBLESTONE, // Cobblestone to Gravel
new ItemStack(net.minecraft.init.Blocks.GRAVEL, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.MOSSY_COBBLESTONE, // Mossy Cobblestone to Gravel
new ItemStack(net.minecraft.init.Blocks.GRAVEL, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.COBBLESTONE_WALL, 1, 0), // Cobblestone Wall to Gravel
new ItemStack(net.minecraft.init.Blocks.GRAVEL, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.COBBLESTONE_WALL, 1, 1), // Mossy Cobblestone Wall to Gravel
new ItemStack(net.minecraft.init.Blocks.GRAVEL, 1));
// Gravel
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.GRAVEL, new ItemStack(net.minecraft.init.Blocks.SAND, 1));
// to
// Sand
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.SANDSTONE, // Sandstone to Sand
new ItemStack(net.minecraft.init.Blocks.SAND, 4));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.STONE_SLAB, 1, 1), // Sandstone Slab to 2 Sand
new ItemStack(net.minecraft.init.Blocks.SAND, 2));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.GLASS, // Glass to Sand
new ItemStack(net.minecraft.init.Blocks.SAND, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.RED_SANDSTONE, // Red Sandstone to Red Sand
new ItemStack(net.minecraft.init.Blocks.SAND, 4, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.STONE_SLAB2, 1, 0), // Red Sandstone Slab to 2 Red Sand
new ItemStack(net.minecraft.init.Blocks.SAND, 2, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.STAINED_GLASS, // Red Stained Glass to Red Sand
new ItemStack(net.minecraft.init.Blocks.SAND, 4, 1));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.GLOWSTONE, // Glowstone to 4 Glowstone Dust
new ItemStack(net.minecraft.init.Items.GLOWSTONE_DUST, 4));
final MMDMaterial lapis = Materials.getMaterialByName(MaterialNames.LAPIS);
// Lapis Ore to 8 Lapis
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.ORE_LAPIS, lapis.getItemStack(Names.INGOT, 8));
// Lapis Block to 9 Lapis
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.BLOCK_LAPIS, lapis.getItemStack(Names.INGOT, 9));
final MMDMaterial redstone = Materials.getMaterialByName(MaterialNames.LAPIS);
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.ORE_REDSTONE, // Redstone Ore to 8 Redstone
redstone.getItemStack(Names.POWDER, 8));
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.BLOCK_REDSTONE, // Redstone Block to 9 Redstone
redstone.getItemStack(Names.POWDER, 9));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Items.REEDS, // Sugar Cane to 2 Sugar
new ItemStack(net.minecraft.init.Items.SUGAR, 2));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.BONE_BLOCK, // Bone Block to 9 Bonemeal
new ItemStack(net.minecraft.init.Items.DYE, 9, 15));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Items.BONE, // Bone to 3 Bonemeal
new ItemStack(net.minecraft.init.Items.DYE, 3, 15));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Items.BLAZE_ROD, // Blaze Rod to 2 Blaze Powder
new ItemStack(net.minecraft.init.Items.BLAZE_POWDER, 2));
final MMDMaterial quartz = Materials.getMaterialByName(MaterialNames.QUARTZ);
CrusherRecipeRegistry.addNewCrusherRecipe(Oredicts.ORE_QUARTZ, // Nether Quartz Ore to 2 Quartz
quartz.getItemStack(Names.INGOT, 2));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.QUARTZ_BLOCK, // Quartz Block to 4 Quartz
quartz.getItemStack(Names.INGOT, 4));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.STONE_SLAB, 1, 7), // Quartz Slab to 2 Quartz
quartz.getItemStack(Names.INGOT, 2));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.PRISMARINE, 1, 0), // Prismarine to Prismarine Shard
new ItemStack(net.minecraft.init.Items.PRISMARINE_SHARD, 4));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.PRISMARINE, 1, 1), // Brismarine Bricks to Prismarine Shard
new ItemStack(net.minecraft.init.Items.PRISMARINE_SHARD, 9));
CrusherRecipeRegistry.addNewCrusherRecipe(new ItemStack(net.minecraft.init.Blocks.PRISMARINE, 1, 2), // Dark Prismarine to Prismarine Shard
new ItemStack(net.minecraft.init.Items.PRISMARINE_SHARD, 8));
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.SEA_LANTERN, // Sea Lantern to 5 Prismarine Crystals
new ItemStack(net.minecraft.init.Items.PRISMARINE_CRYSTALS, 5));
// to Prismarine Shard
CrusherRecipeRegistry.addNewCrusherRecipe(net.minecraft.init.Blocks.SLIME_BLOCK, // Slime Block to 9 Slime Balls
new ItemStack(net.minecraft.init.Items.SLIME_BALL, 9));
}
Aggregations