mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-19 03:39:17 +00:00
Fix 1.8 stones not being voided, clean up ore dict registrations that are no longer needed
This commit is contained in:
4 files changed
+16
-32
No files matched your search
@@ -381,27 +381,13 @@ public final class ModBlocks {
|
||||
OreDictionary.registerOre(LibOreDict.BLAZE_BLOCK, blazeBlock);
|
||||
|
||||
// Vanilla OreDict entries
|
||||
OreDictionary.registerOre("dirt", Blocks.DIRT);
|
||||
OreDictionary.registerOre("grass", Blocks.GRASS);
|
||||
OreDictionary.registerOre("sand", Block.getBlockFromName("sand"));
|
||||
OreDictionary.registerOre("gravel", Block.getBlockFromName("gravel"));
|
||||
OreDictionary.registerOre("hardenedClay", new ItemStack(Blocks.HARDENED_CLAY, 1, OreDictionary.WILDCARD_VALUE));
|
||||
OreDictionary.registerOre("snowLayer", Blocks.SNOW_LAYER);
|
||||
OreDictionary.registerOre("mycelium", Blocks.MYCELIUM);
|
||||
OreDictionary.registerOre("podzol", new ItemStack(Blocks.DIRT, 1, 2));
|
||||
OreDictionary.registerOre("netherrack", Blocks.NETHERRACK);
|
||||
OreDictionary.registerOre("soulSand", Blocks.SOUL_SAND);
|
||||
OreDictionary.registerOre("ice", Blocks.ICE);
|
||||
OreDictionary.registerOre("slabCobblestone", new ItemStack(Blocks.STONE_SLAB, 1, 3));
|
||||
OreDictionary.registerOre("chestWood", Blocks.CHEST);
|
||||
OreDictionary.registerOre("craftingTableWood", Blocks.CRAFTING_TABLE);
|
||||
OreDictionary.registerOre(LibOreDict.PRISMARINE_BLOCK, new ItemStack(Blocks.PRISMARINE, 1, OreDictionary.WILDCARD_VALUE));
|
||||
OreDictionary.registerOre(LibOreDict.STONE_18_VARIANTS[3], new ItemStack(Blocks.STONE, 1, 1));
|
||||
OreDictionary.registerOre(LibOreDict.STONE_18_VARIANTS[2], new ItemStack(Blocks.STONE, 1, 3));
|
||||
OreDictionary.registerOre(LibOreDict.STONE_18_VARIANTS[0], new ItemStack(Blocks.STONE, 1, 5));
|
||||
OreDictionary.registerOre(LibOreDict.STONE_18_VARIANTS[7], new ItemStack(Blocks.STONE, 1, 2));
|
||||
OreDictionary.registerOre(LibOreDict.STONE_18_VARIANTS[6], new ItemStack(Blocks.STONE, 1, 4));
|
||||
OreDictionary.registerOre(LibOreDict.STONE_18_VARIANTS[4], new ItemStack(Blocks.STONE, 1, 6));
|
||||
|
||||
BotaniaAPI.registerPaintableBlock(unstableBlock, BotaniaStateProps.COLOR);
|
||||
BotaniaAPI.registerPaintableBlock(manaBeacon, BotaniaStateProps.COLOR);
|
||||
|
||||
@@ -1243,12 +1243,12 @@ public final class ModCraftingRecipes {
|
||||
// Crafty Crate Recipe
|
||||
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(ModBlocks.openCrate, 1, 1),
|
||||
"WCW", "W W", "W W",
|
||||
'C', "craftingTableWood",
|
||||
'C', "workbench",
|
||||
'W', new ItemStack(ModBlocks.dreamwood, 1, 1)));
|
||||
recipeCraftCrate = BotaniaAPI.getLatestAddedRecipe();
|
||||
|
||||
// Crafting Placeholder Recipe
|
||||
addShapelessOreDictRecipe(new ItemStack(ModItems.manaResource, 32, 11), "craftingTableWood", LibOreDict.LIVING_ROCK);
|
||||
addShapelessOreDictRecipe(new ItemStack(ModItems.manaResource, 32, 11), "workbench", LibOreDict.LIVING_ROCK);
|
||||
recipePlaceholder = BotaniaAPI.getLatestAddedRecipe();
|
||||
|
||||
// Nether Brick Recipe
|
||||
@@ -1523,7 +1523,7 @@ public final class ModCraftingRecipes {
|
||||
" P ", "ICI", " I ",
|
||||
'P', LibOreDict.MANA_PEARL,
|
||||
'I', LibOreDict.MANA_STEEL,
|
||||
'C', "craftingTableWood");
|
||||
'C', "workbench");
|
||||
recipeCraftingHalo = BotaniaAPI.getLatestAddedRecipe();
|
||||
|
||||
// Mana Lens: Flash Recipe
|
||||
|
||||
+13
-8
@@ -27,11 +27,8 @@ public class ItemElementiumPick extends ItemManasteelPick {
|
||||
for(int i = 0; i < event.getDrops().size(); i++) {
|
||||
ItemStack drop = event.getDrops().get(i);
|
||||
if(drop != null) {
|
||||
Block block = Block.getBlockFromItem(drop.getItem());
|
||||
if(block != null){
|
||||
if(isDisposable(block) || (isSemiDisposable(block) && !event.getHarvester().isSneaking()))
|
||||
event.getDrops().remove(i);
|
||||
}
|
||||
if(isDisposable(drop) || (isSemiDisposable(drop) && !event.getHarvester().isSneaking()))
|
||||
event.getDrops().remove(i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -39,7 +36,11 @@ public class ItemElementiumPick extends ItemManasteelPick {
|
||||
}
|
||||
|
||||
public static boolean isDisposable(Block block) {
|
||||
for(int id : OreDictionary.getOreIDs(new ItemStack(block))) {
|
||||
return isDisposable(new ItemStack(block));
|
||||
}
|
||||
|
||||
private static boolean isDisposable(ItemStack stack) {
|
||||
for(int id : OreDictionary.getOreIDs(stack)) {
|
||||
String name = OreDictionary.getOreName(id);
|
||||
if(BotaniaAPI.disposableBlocks.contains(name))
|
||||
return true;
|
||||
@@ -47,8 +48,12 @@ public class ItemElementiumPick extends ItemManasteelPick {
|
||||
return false;
|
||||
}
|
||||
|
||||
public static boolean isSemiDisposable(Block block) {
|
||||
for(int id : OreDictionary.getOreIDs(new ItemStack(block))) {
|
||||
private static boolean isSemiDisposable(Block block) {
|
||||
return isSemiDisposable(new ItemStack(block));
|
||||
}
|
||||
|
||||
private static boolean isSemiDisposable(ItemStack stack) {
|
||||
for(int id : OreDictionary.getOreIDs(stack)) {
|
||||
String name = OreDictionary.getOreName(id);
|
||||
if(BotaniaAPI.semiDisposableBlocks.contains(name))
|
||||
return true;
|
||||
|
||||
@@ -84,13 +84,6 @@ public final class LibOreDict {
|
||||
"runeSlothB", "runeWrathB", "runeEnvyB", "runePrideB"
|
||||
};
|
||||
|
||||
public static final String[] STONE_18_VARIANTS = new String[] {
|
||||
"stoneAndesite", "stoneBasalt", "stoneDiorite", "stoneGranite",
|
||||
"stoneAndesitePolished", "stoneBasaltPolished", "stoneDioritePolished", "stoneGranitePolished",
|
||||
"stoneAndesiteBricks", "stoneBasaltBricks", "stoneDioriteBricks", "stoneGraniteBricks",
|
||||
"stoneAndesiteChiseled", "stoneBasaltChiseled", "stoneDioriteChiseled", "stoneGraniteChiseled"
|
||||
};
|
||||
|
||||
public static final String[] QUARTZ = new String[] {
|
||||
"quartzDark", "quartzMana", "quartzBlaze",
|
||||
"quartzLavender", "quartzRed", "quartzElven", "quartzSunny"
|
||||
|
||||
Reference in new issue
Block a user