-Fixed some Oredict stuff

This commit is contained in:
Ellpeck 2015-06-30 01:58:33 +02:00
parent d7382976e5
commit 639062693f
5 changed files with 7 additions and 3 deletions

View file

@ -91,8 +91,10 @@ public class ActuallyAdditions{
@EventHandler @EventHandler
public void serverStarting(FMLServerStartingEvent event){ public void serverStarting(FMLServerStartingEvent event){
BlockDispenser.dispenseBehaviorRegistry.putObject(InitItems.itemBucketCanolaOil, new DispenserHandlerEmptyBucket()); BlockDispenser.dispenseBehaviorRegistry.putObject(InitItems.itemBucketCanolaOil, new DispenserHandlerEmptyBucket());
BlockDispenser.dispenseBehaviorRegistry.putObject(InitItems.itemBucketOil, new DispenserHandlerEmptyBucket()); BlockDispenser.dispenseBehaviorRegistry.putObject(InitItems.itemBucketOil, new DispenserHandlerEmptyBucket());
BlockDispenser.dispenseBehaviorRegistry.putObject(InitItems.itemFertilizer, new DispenserHandlerFertilize()); BlockDispenser.dispenseBehaviorRegistry.putObject(InitItems.itemFertilizer, new DispenserHandlerFertilize());
} }
} }

View file

@ -15,6 +15,7 @@ public class GrinderCrafting{
public static void init(){ public static void init(){
Util.logInfo("Initializing Crusher Recipes..."); Util.logInfo("Initializing Crusher Recipes...");
GrinderRecipeManualRegistry.recipes.clear();
GrinderRecipeManualRegistry.registerRecipe(new ItemStack(Blocks.redstone_ore), new ItemStack(Items.redstone, 10)); GrinderRecipeManualRegistry.registerRecipe(new ItemStack(Blocks.redstone_ore), new ItemStack(Items.redstone, 10));
GrinderRecipeManualRegistry.registerRecipe(new ItemStack(Blocks.lapis_ore), new ItemStack(InitItems.itemDust, 12, TheDusts.LAPIS.ordinal())); GrinderRecipeManualRegistry.registerRecipe(new ItemStack(Blocks.lapis_ore), new ItemStack(InitItems.itemDust, 12, TheDusts.LAPIS.ordinal()));

View file

@ -15,6 +15,7 @@ import net.minecraft.item.Item;
import net.minecraft.item.ItemFood; import net.minecraft.item.ItemFood;
import net.minecraft.item.ItemStack; import net.minecraft.item.ItemStack;
import net.minecraftforge.common.IPlantable; import net.minecraftforge.common.IPlantable;
import net.minecraftforge.oredict.OreDictionary;
import net.minecraftforge.oredict.ShapedOreRecipe; import net.minecraftforge.oredict.ShapedOreRecipe;
import net.minecraftforge.oredict.ShapelessOreRecipe; import net.minecraftforge.oredict.ShapelessOreRecipe;
@ -192,7 +193,7 @@ public class ItemCrafting{
} }
//Resonant Rice //Resonant Rice
if(ConfigCrafting.RESONANT_RICE.isEnabled()) if(ConfigCrafting.RESONANT_RICE.isEnabled() && !OreDictionary.getOres("nuggetEnderium", false).isEmpty())
GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(InitItems.itemResonantRice), GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(InitItems.itemResonantRice),
TheFoods.RICE.getOredictName(), "nuggetEnderium", Items.gunpowder)); TheFoods.RICE.getOredictName(), "nuggetEnderium", Items.gunpowder));

View file

@ -36,7 +36,7 @@ public class ItemResonantRice extends Item implements INameableItem{
@SideOnly(Side.CLIENT) @SideOnly(Side.CLIENT)
public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) { public void addInformation(ItemStack stack, EntityPlayer player, List list, boolean isHeld) {
ItemUtil.addInformation(this, list, 1, ""); ItemUtil.addInformation(this, list, 1, "");
if(KeyUtil.isShiftPressed() && OreDictionary.getOres("nuggetEnderium", false).size() <= 0) list.add(StringUtil.RED + StatCollector.translateToLocal("tooltip." + ModUtil.MOD_ID_LOWER + ".itemResonantRice.uncraftable.desc")); if(KeyUtil.isShiftPressed() && OreDictionary.getOres("nuggetEnderium", false).isEmpty()) list.add(StringUtil.RED + StatCollector.translateToLocal("tooltip." + ModUtil.MOD_ID_LOWER + ".itemResonantRice.uncraftable.desc"));
} }
@Override @Override