Backport of vanilla tool efficiency fix stuff.
This commit is contained in:
parent
63327f0727
commit
4e47b92cb7
|
@ -43,6 +43,7 @@ public class Aether {
|
|||
@EventHandler
|
||||
public void init(FMLInitializationEvent event) {
|
||||
BlocksAether.initialization();
|
||||
BlocksAether.initializeHarvestLevels();
|
||||
ItemsAether.initialization();
|
||||
AetherRegistries.register();
|
||||
EntitiesAether.initialization();
|
||||
|
|
|
@ -210,6 +210,74 @@ public class BlocksAether {
|
|||
skyroot_bed = registerBed("skyroot_bed", new BlockSkyrootBed().setBlockTextureName(Aether.find("skyroot_bed")));
|
||||
}
|
||||
|
||||
public static void initializeHarvestLevels()
|
||||
{
|
||||
BlocksAether.aether_grass.setHarvestLevel("shovel", 0);
|
||||
BlocksAether.enchanted_aether_grass.setHarvestLevel("shovel", 0);
|
||||
BlocksAether.aether_dirt.setHarvestLevel("shovel", 0);
|
||||
BlocksAether.holystone.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.mossy_holystone.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_brick.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.aercloud.setHarvestLevel("shovel", 0);
|
||||
BlocksAether.quicksoil.setHarvestLevel("shovel", 0);
|
||||
BlocksAether.icestone.setHarvestLevel("pickaxe", 1);
|
||||
BlocksAether.ambrosium_ore.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.zanite_ore.setHarvestLevel("pickaxe", 1);
|
||||
BlocksAether.gravitite_ore.setHarvestLevel("pickaxe", 2);
|
||||
BlocksAether.skyroot_log.setHarvestLevel("axe", 0);
|
||||
BlocksAether.skyroot_planks.setHarvestLevel("axe", 0);
|
||||
BlocksAether.aerogel.setHarvestLevel("pickaxe", 3);
|
||||
BlocksAether.enchanted_gravitite.setHarvestLevel("pickaxe", 2);
|
||||
BlocksAether.zanite_block.setHarvestLevel("pickaxe", 1);
|
||||
BlocksAether.berry_bush_stem.setHarvestLevel("axe", 0);
|
||||
BlocksAether.enchanter.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.freezer.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.incubator.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.carved_stone.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.angelic_stone.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.hellfire_stone.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.chest_mimic.setHarvestLevel("axe", 0);
|
||||
BlocksAether.pillar.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.pillar_top.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.skyroot_fence.setHarvestLevel("axe", 0);
|
||||
BlocksAether.skyroot_fence_gate.setHarvestLevel("axe", 0);
|
||||
BlocksAether.carved_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.angelic_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.angelic_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.hellfire_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_brick_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.mossy_holystone_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.aerogel_wall.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.carved_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.angelic_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.hellfire_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.skyroot_stairs.setHarvestLevel("axe", 0);
|
||||
BlocksAether.mossy_holystone_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_brick_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.aerogel_stairs.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.skyroot_double_slab.setHarvestLevel("axe", 0);
|
||||
BlocksAether.carved_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.angelic_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.hellfire_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.mossy_holystone_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_brick_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.aerogel_double_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.skyroot_slab.setHarvestLevel("axe", 0);
|
||||
BlocksAether.carved_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.angelic_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.hellfire_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.mossy_holystone_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.holystone_brick_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.aerogel_slab.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.sun_altar.setHarvestLevel("pickaxe", 0);
|
||||
BlocksAether.skyroot_bookshelf.setHarvestLevel("axe", 0);
|
||||
BlocksAether.skyroot_bed.setHarvestLevel("axe", 0);
|
||||
}
|
||||
|
||||
public static boolean isGood(Block block) {
|
||||
return block == Blocks.air || block == aercloud;
|
||||
}
|
||||
|
|
|
@ -36,6 +36,9 @@ public enum EnumAetherToolType {
|
|||
} else if (block == BlocksAether.gravitite_ore || block == BlocksAether.enchanted_gravitite) {
|
||||
return toolMaterial.getHarvestLevel() >= 2;
|
||||
}
|
||||
else if (block == BlocksAether.aerogel) {
|
||||
return toolMaterial.getHarvestLevel() == 3;
|
||||
}
|
||||
|
||||
return block == Blocks.obsidian ? toolMaterial.getHarvestLevel() == 3 : (block != Blocks.diamond_block && block != Blocks.diamond_ore ? (block != Blocks.emerald_ore && block != Blocks.emerald_block ? (block != Blocks.gold_block && block != Blocks.gold_ore ? (block != Blocks.iron_block && block != Blocks.iron_ore ? (block != Blocks.lapis_block && block != Blocks.lapis_ore ? (block != Blocks.redstone_ore && block != Blocks.lit_redstone_ore ? (state.getMaterial() == Material.rock ? true : (state.getMaterial() == Material.iron ? true : state.getMaterial() == Material.anvil)) : toolMaterial.getHarvestLevel() >= 2) : toolMaterial.getHarvestLevel() >= 1) : toolMaterial.getHarvestLevel() >= 1) : toolMaterial.getHarvestLevel() >= 2) : toolMaterial.getHarvestLevel() >= 2) : toolMaterial.getHarvestLevel() >= 2);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue