From 86ff9fb6412765d0bbd3fa53f750fb78c0f20a37 Mon Sep 17 00:00:00 2001 From: Michael Hillcox Date: Mon, 1 Mar 2021 20:23:52 +0000 Subject: [PATCH] chore: ported most item constructors... --- .../data/ItemTagsGenerator.java | 4 +- .../mod/ActuallyAdditions.java | 4 +- .../mod/blocks/ActuallyBlocks.java | 10 +- .../mod/blocks/render/RenderLaserRelay.java | 6 +- .../mod/booklet/InitBooklet.java | 97 ++++---- .../mod/booklet/page/PageCoffeeMachine.java | 8 +- .../mod/entity/RenderWorm.java | 4 +- .../mod/event/CommonEvents.java | 6 +- .../VillageComponentEngineerHouse.java | 23 +- .../mod/inventory/ContainerCanolaPress.java | 4 +- .../mod/inventory/ContainerCoffeeMachine.java | 4 +- .../{InitItems.java => ActuallyItems.java} | 135 +++++++----- .../actuallyadditions/mod/items/ItemBag.java | 2 +- .../mod/items/ItemBattery.java | 4 +- .../mod/items/ItemBooklet.java | 4 +- .../mod/items/ItemCoffee.java | 5 +- .../mod/items/ItemCoffeeBean.java | 4 +- .../mod/items/ItemCrafterOnAStick.java | 2 +- .../mod/items/ItemCrystalShard.java | 2 +- .../mod/items/ItemDrill.java | 2 +- .../mod/items/ItemDrillUpgrade.java | 5 +- .../actuallyadditions/mod/items/ItemDust.java | 2 +- .../mod/items/ItemEngineerGoggles.java | 2 +- .../mod/items/ItemFertilizer.java | 4 +- .../mod/items/ItemFilter.java | 31 ++- .../mod/items/ItemFoods.java | 2 +- .../mod/items/ItemGrowthRing.java | 2 +- .../mod/items/ItemHairyBall.java | 5 +- .../actuallyadditions/mod/items/ItemJams.java | 2 +- .../mod/items/ItemKnife.java | 3 +- .../mod/items/ItemLaserWrench.java | 4 +- .../mod/items/ItemLeafBlower.java | 7 +- .../mod/items/ItemMagnetRing.java | 2 +- .../actuallyadditions/mod/items/ItemMisc.java | 207 ++++++++---------- .../mod/items/ItemPhantomConnector.java | 4 +- .../mod/items/ItemPlayerProbe.java | 7 +- .../mod/items/ItemPotionRing.java | 8 +- .../mod/items/ItemResonantRice.java | 2 +- .../mod/items/ItemSolidifiedExperience.java | 4 +- .../mod/items/ItemSpawnerChanger.java | 3 +- .../mod/items/ItemTeleStaff.java | 2 +- .../mod/items/ItemWaterBowl.java | 31 ++- .../mod/items/ItemWaterRemovalRing.java | 2 +- .../mod/items/ItemWingsOfTheBats.java | 6 +- .../actuallyadditions/mod/items/ItemWorm.java | 2 +- .../mod/items/base/ItemArmorAA.java | 4 +- .../mod/items/base/ItemBase.java | 4 +- .../mod/items/base/ItemEnergy.java | 4 +- .../mod/items/lens/ItemLens.java | 4 +- .../mod/items/metalists/TheCrystals.java | 2 +- .../mod/items/metalists/TheFoods.java | 6 +- .../mod/items/metalists/TheMiscItems.java | 48 ---- .../mod/jei/JEIActuallyAdditionsPlugin.java | 9 +- .../coffee/CoffeeMachineRecipeWrapper.java | 7 +- .../mod/material/ArmorMaterials.java | 18 +- .../mod/material/ToolMaterials.java | 16 +- .../mod/misc/BannerHelper.java | 10 +- .../mod/ore/InitOreDict.java | 62 +++--- .../mod/recipe/HairyBallHandler.java | 4 +- .../mod/tile/FilterSettings.java | 1 - .../mod/tile/TileEntityCanolaPress.java | 4 +- .../mod/tile/TileEntityCoffeeMachine.java | 9 +- .../mod/tile/TileEntityLaserRelay.java | 4 +- .../mod/tile/TileEntityXPSolidifier.java | 6 +- 64 files changed, 421 insertions(+), 480 deletions(-) rename src/main/java/de/ellpeck/actuallyadditions/mod/items/{InitItems.java => ActuallyItems.java} (77%) delete mode 100644 src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheMiscItems.java diff --git a/src/main/java/de/ellpeck/actuallyadditions/data/ItemTagsGenerator.java b/src/main/java/de/ellpeck/actuallyadditions/data/ItemTagsGenerator.java index f10f25171..9f9a94915 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/data/ItemTagsGenerator.java +++ b/src/main/java/de/ellpeck/actuallyadditions/data/ItemTagsGenerator.java @@ -2,7 +2,7 @@ package de.ellpeck.actuallyadditions.data; import de.ellpeck.actuallyadditions.api.ActuallyTags; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.data.BlockTagsProvider; import net.minecraft.data.DataGenerator; import net.minecraft.data.ItemTagsProvider; @@ -17,7 +17,7 @@ public class ItemTagsGenerator extends ItemTagsProvider { @Override protected void registerTags() { - this.getOrCreateBuilder(ActuallyTags.Items.COFFEE_BEANS).add(InitItems.itemCoffeeBean); + this.getOrCreateBuilder(ActuallyTags.Items.COFFEE_BEANS).add(ActuallyItems.itemCoffeeBean); // getOrCreateBuilder(ActuallyTags.Items.DRILLS).add( // ActuallyItems.DRILL_MAIN.get(), // ActuallyItems.DRILL_BLACK.get(), ActuallyItems.DRILL_BLACK.get(), ActuallyItems.DRILL_BLUE.get(), ActuallyItems.DRILL_BROWN.get(), diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/ActuallyAdditions.java b/src/main/java/de/ellpeck/actuallyadditions/mod/ActuallyAdditions.java index 04c0c5008..13e4aae73 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/ActuallyAdditions.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/ActuallyAdditions.java @@ -20,7 +20,7 @@ import de.ellpeck.actuallyadditions.mod.event.CommonEvents; import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.gen.AAWorldGen; import de.ellpeck.actuallyadditions.mod.inventory.ActuallyContainers; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemCoffee; import de.ellpeck.actuallyadditions.mod.items.lens.LensMining; import de.ellpeck.actuallyadditions.mod.items.lens.LensRecipeHandler; @@ -67,7 +67,7 @@ public class ActuallyAdditions { public static final ItemGroup GROUP = new ItemGroup(MODID) { @Override public ItemStack createIcon() { - return new ItemStack(InitItems.itemBooklet.get()); + return new ItemStack(ActuallyItems.itemBooklet.get()); } }; diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/ActuallyBlocks.java b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/ActuallyBlocks.java index 154c995b8..1b1b24879 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/ActuallyBlocks.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/ActuallyBlocks.java @@ -12,7 +12,7 @@ package de.ellpeck.actuallyadditions.mod.blocks; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.blocks.base.BlockPlant; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.metalists.TheCrystals; import net.minecraft.block.*; import net.minecraft.block.material.Material; @@ -117,10 +117,10 @@ public final class ActuallyBlocks { public static final RegistryObject blockCoalGenerator = BLOCKS.register("block_coal_generator", BlockCoalGenerator::new); public static final RegistryObject blockOilGenerator = BLOCKS.register("block_oil_generator", BlockOilGenerator::new); public static final RegistryObject blockFermentingBarrel = BLOCKS.register("block_fermenting_barrel", BlockFermentingBarrel::new); - public static final RegistryObject blockRice = BLOCKS.register("block_rice", () -> new BlockPlant(InitItems.itemRiceSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(1, 2)); - public static final RegistryObject blockCanola = BLOCKS.register("block_canola", () -> new BlockPlant(InitItems.itemCanolaSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(2, 3)); - public static final RegistryObject blockFlax = BLOCKS.register("block_flax", () -> new BlockPlant(InitItems.itemFlaxSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(2, 4)); - public static final RegistryObject blockCoffee = BLOCKS.register("block_coffee", () -> new BlockPlant(InitItems.itemCoffeeSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(2, 2)); + public static final RegistryObject blockRice = BLOCKS.register("block_rice", () -> new BlockPlant(ActuallyItems.itemRiceSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(1, 2)); + public static final RegistryObject blockCanola = BLOCKS.register("block_canola", () -> new BlockPlant(ActuallyItems.itemCanolaSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(2, 3)); + public static final RegistryObject blockFlax = BLOCKS.register("block_flax", () -> new BlockPlant(ActuallyItems.itemFlaxSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(2, 4)); + public static final RegistryObject blockCoffee = BLOCKS.register("block_coffee", () -> new BlockPlant(ActuallyItems.itemCoffeeSeed.get()));// TODO: [port][replace] ensure values match these new BlockPlant(2, 2)); public static final RegistryObject blockFurnaceDouble = BLOCKS.register("block_furnace_double", BlockFurnaceDouble::new); public static final RegistryObject blockInputter = BLOCKS.register("block_inputter", () -> new BlockInputter(false)); public static final RegistryObject blockInputterAdvanced = BLOCKS.register("block_inputter_advanced", () -> new BlockInputter(true)); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/render/RenderLaserRelay.java b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/render/RenderLaserRelay.java index 8c6560793..c11bf0325 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/render/RenderLaserRelay.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/render/RenderLaserRelay.java @@ -15,7 +15,7 @@ import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; import de.ellpeck.actuallyadditions.api.laser.IConnectionPair; import de.ellpeck.actuallyadditions.api.laser.LaserType; import de.ellpeck.actuallyadditions.mod.config.ConfigValues; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemEngineerGoggles; import de.ellpeck.actuallyadditions.mod.items.ItemLaserWrench; import de.ellpeck.actuallyadditions.mod.tile.TileEntityLaserRelay; @@ -54,7 +54,7 @@ public class RenderLaserRelay extends TileEntityRenderer { ItemStack upgrade = relay.inv.getStackInSlot(0); if (StackUtil.isValid(upgrade)) { - if (upgrade.getItem() == InitItems.itemLaserUpgradeInvisibility.get()) { + if (upgrade.getItem() == ActuallyItems.itemLaserUpgradeInvisibility.get()) { hasInvis = true; } @@ -85,7 +85,7 @@ public class RenderLaserRelay extends TileEntityRenderer { TileEntity secondTile = tile.getWorld().getTileEntity(second); if (secondTile instanceof TileEntityLaserRelay) { ItemStack secondUpgrade = ((TileEntityLaserRelay) secondTile).inv.getStackInSlot(0); - boolean otherInvis = StackUtil.isValid(secondUpgrade) && secondUpgrade.getItem() == InitItems.itemLaserUpgradeInvisibility.get(); + boolean otherInvis = StackUtil.isValid(secondUpgrade) && secondUpgrade.getItem() == ActuallyItems.itemLaserUpgradeInvisibility.get(); if (hasGoggles || !hasInvis || !otherInvis) { float[] color = hasInvis && otherInvis diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java index 134bd1326..1310a0617 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/InitBooklet.java @@ -32,12 +32,11 @@ import de.ellpeck.actuallyadditions.mod.crafting.*; import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.gen.AAWorldGen; import de.ellpeck.actuallyadditions.mod.gen.WorldGenLushCaves; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemWingsOfTheBats; import de.ellpeck.actuallyadditions.mod.items.lens.LensDisenchanting; import de.ellpeck.actuallyadditions.mod.items.lens.LensRecipeHandler; import de.ellpeck.actuallyadditions.mod.items.metalists.TheFoods; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; import de.ellpeck.actuallyadditions.mod.recipe.EmpowererHandler; import de.ellpeck.actuallyadditions.mod.tile.*; import de.ellpeck.actuallyadditions.mod.update.UpdateChecker; @@ -126,9 +125,9 @@ public final class InitBooklet { private static void initChapters() { //Getting Started - chaptersIntroduction[0] = new BookletChapter("bookTutorial", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemBooklet.get()), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3), new PageCrafting(4, ItemCrafting.recipeBook).setNoText()); - chaptersIntroduction[1] = new BookletChapter("videoGuide", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.YOUTUBE_ICON.ordinal()), new PageLinkButton(1, "https://www.youtube.com/watch?v=fhjz0Ew56pM"), new PageLinkButton(2, "https://www.youtube.com/playlist?list=PLJeFZ64pT89MrTRZYzD_rtHFajPVlt6cF")).setImportant(); - new BookletChapter("intro", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemBooklet.get()), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3)); + chaptersIntroduction[0] = new BookletChapter("bookTutorial", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(ActuallyItems.itemBooklet.get()), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3), new PageCrafting(4, ItemCrafting.recipeBook).setNoText()); + // chaptersIntroduction[1] = new BookletChapter("videoGuide", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.YOUTUBE_ICON.ordinal()), new PageLinkButton(1, "https://www.youtube.com/watch?v=fhjz0Ew56pM"), new PageLinkButton(2, "https://www.youtube.com/playlist?list=PLJeFZ64pT89MrTRZYzD_rtHFajPVlt6cF")).setImportant(); + new BookletChapter("intro", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(ActuallyItems.itemBooklet.get()), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3)); ArrayList crystalPages = new ArrayList<>(); crystalPages.addAll(Arrays.asList(new PageTextOnly(1).addTextReplacement("", TileEntityAtomicReconstructor.ENERGY_USE), new PageTextOnly(2), new PageTextOnly(3), new PagePicture(4, "page_atomic_reconstructor", 0).setNoText(), new PageTextOnly(5), new PageCrafting(6, BlockCrafting.recipeAtomicReconstructor).setWildcard())); for (int i = 0; i < LensRecipeHandler.MAIN_PAGE_RECIPES.size(); i++) { @@ -147,18 +146,18 @@ public final class InitBooklet { empowererPages.add(new PageCrafting(empowererPages.size() + 1, MiscCrafting.RECIPES_EMPOWERED_CRYSTALS).setNoText()); empowererPages.add(new PageCrafting(empowererPages.size() + 1, MiscCrafting.RECIPES_EMPOWERED_CRYSTAL_BLOCKS).setNoText()); new BookletChapter("empowerer", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(ActuallyBlocks.blockEmpowerer.get()), empowererPages.toArray(new BookletPage[empowererPages.size()])).setSpecial(); - new BookletChapter("craftingIngs", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.COIL.ordinal()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeCoil).setNoText(), new PageCrafting(3, ItemCrafting.recipeCoilAdvanced).setNoText(), new PageCrafting(4, BlockCrafting.recipeCase).setNoText(), new PageCrafting(5, BlockCrafting.recipeEnderPearlBlock).setNoText(), new PageCrafting(6, BlockCrafting.recipeEnderCase).setNoText(), new PageCrafting(7, ItemCrafting.recipeRing).setNoText(), new PageCrafting(8, ItemCrafting.recipeKnifeHandle).setNoText(), new PageCrafting(9, ItemCrafting.recipeKnifeBlade).setNoText(), new PageCrafting(10, ItemCrafting.recipeKnife).setNoText(), new PageCrafting(11, ItemCrafting.recipeDough).setNoText(), new PageCrafting(12, ItemCrafting.recipeRiceDough).setNoText(), new PageCrafting(13, BlockCrafting.recipeIronCase).setNoText(), new PageCrafting(14, ItemCrafting.recipeLens).setNoText()); + new BookletChapter("craftingIngs", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(ActuallyItems.itemCoil.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeCoil).setNoText(), new PageCrafting(3, ItemCrafting.recipeCoilAdvanced).setNoText(), new PageCrafting(4, BlockCrafting.recipeCase).setNoText(), new PageCrafting(5, BlockCrafting.recipeEnderPearlBlock).setNoText(), new PageCrafting(6, BlockCrafting.recipeEnderCase).setNoText(), new PageCrafting(7, ItemCrafting.recipeRing).setNoText(), new PageCrafting(8, ItemCrafting.recipeKnifeHandle).setNoText(), new PageCrafting(9, ItemCrafting.recipeKnifeBlade).setNoText(), new PageCrafting(10, ItemCrafting.recipeKnife).setNoText(), new PageCrafting(11, ItemCrafting.recipeDough).setNoText(), new PageCrafting(12, ItemCrafting.recipeRiceDough).setNoText(), new PageCrafting(13, BlockCrafting.recipeIronCase).setNoText(), new PageCrafting(14, ItemCrafting.recipeLens).setNoText()); chaptersIntroduction[4] = new BookletChapter("rf", ActuallyAdditionsAPI.entryGettingStarted, new ItemStack(Items.REDSTONE), new PageTextOnly(1), new PageTextOnly(2)).setImportant(); //Miscellaneous - new BookletChapter("worms", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemWorm.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemWorm.get())), new PagePicture(2, "page_worms", 145)).setImportant(); + new BookletChapter("worms", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemWorm.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemWorm.get())), new PagePicture(2, "page_worms", 145)).setImportant(); new BookletChapter("lushCaves", ActuallyAdditionsAPI.entryMisc, new ItemStack(Blocks.STONE), new PageTextOnly(1), new PagePicture(2, "page_lush_caves", 0).setNoText()); new BookletChapter("crystalClusters", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyBlocks.blockCrystalClusterEmerald), new PageTextOnly(1).addItemsToPage(WorldGenLushCaves.CRYSTAL_CLUSTERS), new PageCrafting(2, MiscCrafting.RECIPES_CRYSTAL_SHARDS).setNoText(), new PageCrafting(3, MiscCrafting.RECIPES_CRYSTAL_SHARDS_BACK).setNoText()).setSpecial(); new BookletChapter("banners", ActuallyAdditionsAPI.entryMisc, new ItemStack(Items.BLUE_BANNER, 1), new PageTextOnly(1)); new BookletChapter("miscDecorStuffsAndThings", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyBlocks.blockTestifiBucksGreenWall), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeWhiteWall).setNoText(), new PageReconstructor(3, LensRecipeHandler.recipeGreenWall).setNoText()); - chaptersIntroduction[3] = new BookletChapter("quartz", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.QUARTZ.ordinal()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyBlocks.blockMisc, 1, TheMiscBlocks.ORE_QUARTZ.ordinal())).addTextReplacement("", AAWorldGen.QUARTZ_MIN).addTextReplacement("", AAWorldGen.QUARTZ_MAX), new PageTextOnly(2).addItemsToPage(new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.QUARTZ.ordinal())), new PageCrafting(3, BlockCrafting.recipeQuartzBlock).setNoText(), new PageCrafting(4, BlockCrafting.recipeQuartzPillar).setNoText(), new PageCrafting(5, BlockCrafting.recipeQuartzChiseled).setNoText()); + chaptersIntroduction[3] = new BookletChapter("quartz", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemBlackQuartz.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyBlocks.blockMisc, 1, TheMiscBlocks.ORE_QUARTZ.ordinal())).addTextReplacement("", AAWorldGen.QUARTZ_MIN).addTextReplacement("", AAWorldGen.QUARTZ_MAX), new PageTextOnly(2).addItemsToPage(new ItemStack(ActuallyItems.itemBlackQuartz.get())), new PageCrafting(3, BlockCrafting.recipeQuartzBlock).setNoText(), new PageCrafting(4, BlockCrafting.recipeQuartzPillar).setNoText(), new PageCrafting(5, BlockCrafting.recipeQuartzChiseled).setNoText()); // new BookletChapter("cloud", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyBlocks.blockSmileyCloud), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeSmileyCloud).setWildcard()).setSpecial(); - new BookletChapter("coalStuff", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.TINY_COAL.ordinal()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeTinyCoal).setNoText(), new PageCrafting(3, ItemCrafting.recipeTinyChar).setNoText(), new PageCrafting(4, BlockCrafting.recipeBlockChar).setNoText()); + new BookletChapter("coalStuff", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemTinyCoal.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeTinyCoal).setNoText(), new PageCrafting(3, ItemCrafting.recipeTinyChar).setNoText(), new PageCrafting(4, BlockCrafting.recipeBlockChar).setNoText()); ArrayList lampPages = new ArrayList<>(); lampPages.add(new PageTextOnly(lampPages.size() + 1)); lampPages.add(new PageTextOnly(lampPages.size() + 1)); @@ -167,35 +166,35 @@ public final class InitBooklet { lampPages.add(new PageCrafting(lampPages.size() + 1, recipe).setNoText()); } new BookletChapter("lamps", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyBlocks.blockColoredLampOn.get(), 1, TheColoredLampColors.GREEN.ordinal()), lampPages.toArray(new BookletPage[lampPages.size()])); - new BookletChapter("enderStar", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.ENDER_STAR.ordinal()), new PageCrafting(1, ItemCrafting.recipeEnderStar)); - new BookletChapter("spawnerShard", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.SPAWNER_SHARD.ordinal()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.SPAWNER_SHARD.ordinal()))); + new BookletChapter("enderStar", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemEnderStar.get()), new PageCrafting(1, ItemCrafting.recipeEnderStar)); + new BookletChapter("spawnerShard", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemSpawnerShard.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemSpawnerShard.get()))); // new BookletChapter("treasureChest", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitBlocks.blockTreasureChest.get()), new PagePicture(1, "page_treasure_chest", 150).addItemsToPage(new ItemStack(InitBlocks.blockTreasureChest.get())), new PageTextOnly(2)).setSpecial(); - new BookletChapter("hairBalls", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemHairyBall.get()), new PagePicture(1, "page_fur_balls", 110).addItemsToPage(new ItemStack(InitItems.itemHairyBall.get())), new PageTextOnly(2)).setSpecial(); + new BookletChapter("hairBalls", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemHairyBall.get()), new PagePicture(1, "page_fur_balls", 110).addItemsToPage(new ItemStack(ActuallyItems.itemHairyBall.get())), new PageTextOnly(2)).setSpecial(); // new BookletChapter("blackLotus", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitBlocks.blockBlackLotus.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitBlocks.blockBlackLotus.get())), new PageCrafting(2, ItemCrafting.recipeBlackDye)); - new BookletChapter("waterBowl", ActuallyAdditionsAPI.entryMisc, new ItemStack(InitItems.itemWaterBowl.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemWaterBowl.get()))); + new BookletChapter("waterBowl", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyItems.itemWaterBowl.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemWaterBowl.get()))); new BookletChapter("tinyTorch", ActuallyAdditionsAPI.entryMisc, new ItemStack(ActuallyBlocks.blockTinyTorch.get()), new PageCrafting(1, BlockCrafting.recipesTinyTorch).setWildcard()).setSpecial(); //Reconstruction - chaptersIntroduction[7] = new BookletChapter("reconstructorLenses", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.LENS.ordinal()), new PageTextOnly(1)).setImportant(); + chaptersIntroduction[7] = new BookletChapter("reconstructorLenses", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemLens.get()), new PageTextOnly(1)).setImportant(); new BookletChapter("additionalRecipes", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(Items.LEATHER), new PageReconstructor(1, LensRecipeHandler.recipeSoulSand).setNoText(), new PageReconstructor(2, LensRecipeHandler.recipeLeather).setNoText(), new PageReconstructor(3, LensRecipeHandler.recipeNetherWart).setNoText(), new PageReconstructor(4, LensRecipeHandler.recipePrismarine).setNoText()).setSpecial(); new BookletChapter("bookSplitting", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(Items.ENCHANTED_BOOK), new PageTextOnly(1), new PageReconstructor(2, new LensConversionRecipe(Ingredient.fromItem(Items.ENCHANTED_BOOK), new ItemStack(Items.ENCHANTED_BOOK), 0, ActuallyAdditionsAPI.lensDefaultConversion)).setNoText()); - new BookletChapter("lensColor", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemColorLens.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeColorLens).setNoText()); - new BookletChapter("lensDeath", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemDamageLens.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeDamageLens).setNoText()); - new BookletChapter("lensMoreDeath", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemMoreDamageLens.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLensMoreDeath).setNoText()); - new BookletChapter("lensDetonation", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemExplosionLens.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeExplosionLens).setNoText()); - new BookletChapter("lensDisenchanting", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemDisenchantingLens.get()), new PageTextOnly(1).addTextReplacement("", LensDisenchanting.ENERGY_USE), new PageCrafting(2, ItemCrafting.recipeDisenchantingLens).setNoText()).setSpecial(); - new BookletChapter("lensMining", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(InitItems.itemMiningLens.get()), new PageTextOnly(1).addTextReplacement("", ConfigIntValues.MINING_LENS_USE.getValue()), new PageCrafting(2, ItemCrafting.recipeMiningLens).setNoText()).setImportant(); + new BookletChapter("lensColor", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemColorLens.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeColorLens).setNoText()); + new BookletChapter("lensDeath", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemDamageLens.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeDamageLens).setNoText()); + new BookletChapter("lensMoreDeath", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemMoreDamageLens.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLensMoreDeath).setNoText()); + new BookletChapter("lensDetonation", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemExplosionLens.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeExplosionLens).setNoText()); + new BookletChapter("lensDisenchanting", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemDisenchantingLens.get()), new PageTextOnly(1).addTextReplacement("", LensDisenchanting.ENERGY_USE), new PageCrafting(2, ItemCrafting.recipeDisenchantingLens).setNoText()).setSpecial(); + new BookletChapter("lensMining", ActuallyAdditionsAPI.entryReconstruction, new ItemStack(ActuallyItems.itemMiningLens.get()), new PageTextOnly(1).addTextReplacement("", ConfigIntValues.MINING_LENS_USE.getValue()), new PageCrafting(2, ItemCrafting.recipeMiningLens).setNoText()).setImportant(); //Laser Relays - chaptersIntroduction[8] = new BookletChapter("laserIntro", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(InitItems.itemLaserWrench.get()), new PageTextOnly(1), new PageTextOnly(2).addTextReplacement("", TileEntityLaserRelay.MAX_DISTANCE), new PageCrafting(3, ItemCrafting.recipeLaserWrench)).setImportant(); + chaptersIntroduction[8] = new BookletChapter("laserIntro", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyItems.itemLaserWrench.get()), new PageTextOnly(1), new PageTextOnly(2).addTextReplacement("", TileEntityLaserRelay.MAX_DISTANCE), new PageCrafting(3, ItemCrafting.recipeLaserWrench)).setImportant(); new BookletChapter("laserRelays", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyBlocks.blockLaserRelay.get()), new PageTextOnly(1), new PageTextOnly(2).addTextReplacement("", TileEntityLaserRelayEnergy.CAP).addTextReplacement("", TileEntityLaserRelayEnergyAdvanced.CAP).addTextReplacement("", TileEntityLaserRelayEnergyExtreme.CAP), new PagePicture(3, "page_laser_relay", 0).setNoText(), new PageCrafting(4, BlockCrafting.recipeLaserRelay).setWildcard().setNoText(), new PageCrafting(5, BlockCrafting.recipeLaserRelayAdvanced).setWildcard().setNoText(), new PageCrafting(6, BlockCrafting.recipeLaserRelayExtreme).setWildcard().setNoText()); new BookletChapter("fluidLaser", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyBlocks.blockLaserRelayFluids.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeFluidLaser).setWildcard().setNoText()); new BookletChapter("itemRelays", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyBlocks.blockLaserRelayItem.get()), new PageTextOnly(1), new PageReconstructor(2, LensRecipeHandler.recipeItemLaser).setWildcard().setNoText()).setSpecial(); new BookletChapter("itemInterfaces", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyBlocks.blockItemViewer.get()), new PageTextOnly(1), new PageTextOnly(2), new PageCrafting(3, BlockCrafting.recipeItemInterface).setNoText()); new BookletChapter("itemRelaysAdvanced", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyBlocks.blockLaserRelayItemWhitelist.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeLaserRelayItemWhitelist).setWildcard()); new BookletChapter("itemInterfacesHopping", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyBlocks.blockItemViewerHopping.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeItemInterfaceHopping).setWildcard().setNoText()); - new BookletChapter("laserUpgradeInvisibility", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(InitItems.itemLaserUpgradeInvisibility.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLaserUpgradeInvisibility).setNoText()).setImportant(); - new BookletChapter("laserUpgradeRange", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(InitItems.itemLaserUpgradeRange.get()), new PageTextOnly(1).addTextReplacement("", TileEntityLaserRelay.MAX_DISTANCE).addTextReplacement("", TileEntityLaserRelay.MAX_DISTANCE_RANGED), new PageCrafting(2, ItemCrafting.recipeLaserUpgradeRange).setNoText()).setImportant(); + new BookletChapter("laserUpgradeInvisibility", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyItems.itemLaserUpgradeInvisibility.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLaserUpgradeInvisibility).setNoText()).setImportant(); + new BookletChapter("laserUpgradeRange", ActuallyAdditionsAPI.entryLaserRelays, new ItemStack(ActuallyItems.itemLaserUpgradeRange.get()), new PageTextOnly(1).addTextReplacement("", TileEntityLaserRelay.MAX_DISTANCE).addTextReplacement("", TileEntityLaserRelay.MAX_DISTANCE_RANGED), new PageCrafting(2, ItemCrafting.recipeLaserUpgradeRange).setNoText()).setImportant(); //No RF Using Blocks new BookletChapter("breaker", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockBreaker.get()), new PageCrafting(1, BlockCrafting.recipeBreaker).setWildcard(), new PageCrafting(2, BlockCrafting.recipePlacer).setWildcard(), new PageCrafting(3, BlockCrafting.recipeLiquidPlacer).setWildcard(), new PageCrafting(4, BlockCrafting.recipeLiquidCollector).setWildcard()); @@ -204,7 +203,7 @@ public final class InitBooklet { new BookletChapter("phantomRedstoneface", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockPhantomRedstoneface.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipePhantomRedstoneface).setNoText()); new BookletChapter("phantomBreaker", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockPhantomBreaker.get()), new PageTextOnly(1).addTextReplacement("", TileEntityPhantomPlacer.RANGE), new PageCrafting(2, BlockCrafting.recipePhantomPlacer).setNoText(), new PageCrafting(3, BlockCrafting.recipePhantomBreaker).setNoText()); new BookletChapter("esd", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockInputterAdvanced.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeESD).setNoText(), new PageCrafting(3, BlockCrafting.recipeAdvancedESD).setNoText()).setSpecial(); - new BookletChapter("xpSolidifier", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockXPSolidifier.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemSolidifiedExperience.get())), new PageCrafting(2, BlockCrafting.recipeSolidifier).setNoText()).setImportant(); + new BookletChapter("xpSolidifier", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockXPSolidifier.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemSolidifiedExperience.get())), new PageCrafting(2, BlockCrafting.recipeSolidifier).setNoText()).setImportant(); new BookletChapter("greenhouseGlass", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockGreenhouseGlass.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeGlass)); // new BookletChapter("fishingNet", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockFishingNet.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeFisher).setNoText()); new BookletChapter("feeder", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyBlocks.blockFeeder.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeFeeder).setNoText()); @@ -215,9 +214,9 @@ public final class InitBooklet { //RF Using Blocks new BookletChapter("fireworkBox", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockFireworkBox.get()), new PageTextOnly(1).addTextReplacement("", TileEntityFireworkBox.USE_PER_SHOT), new PageCrafting(2, BlockCrafting.recipeFireworkBox)).setSpecial(); new BookletChapter("batteryBox", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockBatteryBox.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeBatteryBox).setNoText()).setSpecial(); - new BookletChapter("farmer", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockFarmer.get()), new PageTextOnly(1), new PagePicture(2, "page_farmer_crops", 95).addItemsToPage(new ItemStack(Items.WHEAT_SEEDS)).addItemsToPage(new ItemStack(InitItems.itemCanolaSeed.get())), new PagePicture(3, "page_farmer_cactus", 105).addItemsToPage(new ItemStack(Blocks.CACTUS)), new PagePicture(4, "page_farmer_wart", 95).addItemsToPage(new ItemStack(Items.NETHER_WART)), new PagePicture(5, "page_farmer_reeds", 105).addItemsToPage(new ItemStack(Items.REEDS)), new PagePicture(6, "page_farmer_melons", 105).addItemsToPage(new ItemStack(Items.MELON), new ItemStack(Blocks.PUMPKIN), new ItemStack(Blocks.MELON_BLOCK)), new PagePicture(7, "page_farmer_enderlilly", 105), new PagePicture(8, "page_farmer_redorchid", 105), new PageCrafting(4, BlockCrafting.recipeFarmer).setWildcard().setNoText()).setImportant(); + new BookletChapter("farmer", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockFarmer.get()), new PageTextOnly(1), new PagePicture(2, "page_farmer_crops", 95).addItemsToPage(new ItemStack(Items.WHEAT_SEEDS)).addItemsToPage(new ItemStack(ActuallyItems.itemCanolaSeed.get())), new PagePicture(3, "page_farmer_cactus", 105).addItemsToPage(new ItemStack(Blocks.CACTUS)), new PagePicture(4, "page_farmer_wart", 95).addItemsToPage(new ItemStack(Items.NETHER_WART)), new PagePicture(5, "page_farmer_reeds", 105).addItemsToPage(new ItemStack(Items.REEDS)), new PagePicture(6, "page_farmer_melons", 105).addItemsToPage(new ItemStack(Items.MELON), new ItemStack(Blocks.PUMPKIN), new ItemStack(Blocks.MELON_BLOCK)), new PagePicture(7, "page_farmer_enderlilly", 105), new PagePicture(8, "page_farmer_redorchid", 105), new PageCrafting(4, BlockCrafting.recipeFarmer).setWildcard().setNoText()).setImportant(); new BookletChapter("miner", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockMiner.get()), new PageTextOnly(1).addTextReplacement("", TileEntityMiner.ENERGY_USE_PER_BLOCK).addTextReplacement("", TileEntityMiner.DEFAULT_RANGE), new PageCrafting(2, BlockCrafting.recipeMiner)).setSpecial(); - new BookletChapterCoffee("coffeeMachine", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockCoffeeMachine.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemCoffeeBean.get())).addTextReplacement("", TileEntityCoffeeMachine.ENERGY_USED).addTextReplacement("", TileEntityCoffeeMachine.CACHE_USE).addTextReplacement("", TileEntityCoffeeMachine.WATER_USE), new PageTextOnly(2).addItemsToPage(new ItemStack(InitItems.itemCoffee.get())), new PagePicture(3, "page_coffee_machine", 115), new PageCrafting(4, BlockCrafting.recipeCoffeeMachine).setWildcard().setNoText(), new PageCrafting(5, ItemCrafting.recipeCup).setNoText()).setImportant(); + new BookletChapterCoffee("coffeeMachine", ActuallyAdditionsAPI.entryFunctionalRF, new ItemStack(ActuallyBlocks.blockCoffeeMachine.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemCoffeeBean.get())).addTextReplacement("", TileEntityCoffeeMachine.ENERGY_USED).addTextReplacement("", TileEntityCoffeeMachine.CACHE_USE).addTextReplacement("", TileEntityCoffeeMachine.WATER_USE), new PageTextOnly(2).addItemsToPage(new ItemStack(ActuallyItems.itemCoffee.get())), new PagePicture(3, "page_coffee_machine", 115), new PageCrafting(4, BlockCrafting.recipeCoffeeMachine).setWildcard().setNoText(), new PageCrafting(5, ItemCrafting.recipeCup).setNoText()).setImportant(); List list = new ArrayList<>(); list.add(new PageTextOnly(1).addTextReplacement("", TileEntityGrinder.ENERGY_USE)); @@ -246,56 +245,56 @@ public final class InitBooklet { //RF Generating Blocks // new BookletChapter("solarPanel", ActuallyAdditionsAPI.entryGeneratingRF, new ItemStack(ActuallyBlocks.blockFurnaceSolar.get()), new PageTextOnly(1).addTextReplacement("", TileEntityFurnaceSolar.PRODUCE), new PageCrafting(2, BlockCrafting.recipeSolar).setNoText()); new BookletChapter("heatCollector", ActuallyAdditionsAPI.entryGeneratingRF, new ItemStack(ActuallyBlocks.blockHeatCollector.get()), new PageTextOnly(1).addTextReplacement("", TileEntityHeatCollector.ENERGY_PRODUCE).addTextReplacement("", TileEntityHeatCollector.BLOCKS_NEEDED), new PageCrafting(2, BlockCrafting.recipeHeatCollector).setNoText()); - new BookletChapter("canola", ActuallyAdditionsAPI.entryGeneratingRF, new ItemStack(ActuallyBlocks.blockFermentingBarrel.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.CANOLA.ordinal())).addItemsToPage(new ItemStack(InitItems.itemCanolaSeed.get())).addFluidToPage(InitFluids.fluidCanolaOil), new PageTextOnly(2).addFluidToPage(InitFluids.fluidRefinedCanolaOil).addFluidToPage(InitFluids.fluidCrystalOil).addFluidToPage(InitFluids.fluidEmpoweredOil), new PageCrafting(3, BlockCrafting.recipeCanolaPress).setNoText(), new PageCrafting(4, BlockCrafting.recipeFermentingBarrel), new PageCrafting(5, BlockCrafting.recipeOilGen), new PageReconstructor(6, LensRecipeHandler.recipeCrystallizedCanolaSeed).setNoText(), new PageEmpowerer(7, EmpowererHandler.recipeEmpoweredCanolaSeed).setNoText()); + new BookletChapter("canola", ActuallyAdditionsAPI.entryGeneratingRF, new ItemStack(ActuallyBlocks.blockFermentingBarrel.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemCanola.get())).addItemsToPage(new ItemStack(ActuallyItems.itemCanolaSeed.get())).addFluidToPage(InitFluids.fluidCanolaOil), new PageTextOnly(2).addFluidToPage(InitFluids.fluidRefinedCanolaOil).addFluidToPage(InitFluids.fluidCrystalOil).addFluidToPage(InitFluids.fluidEmpoweredOil), new PageCrafting(3, BlockCrafting.recipeCanolaPress).setNoText(), new PageCrafting(4, BlockCrafting.recipeFermentingBarrel), new PageCrafting(5, BlockCrafting.recipeOilGen), new PageReconstructor(6, LensRecipeHandler.recipeCrystallizedCanolaSeed).setNoText(), new PageEmpowerer(7, EmpowererHandler.recipeEmpoweredCanolaSeed).setNoText()); new BookletChapter("leafGen", ActuallyAdditionsAPI.entryGeneratingRF, new ItemStack(ActuallyBlocks.blockLeafGenerator.get()), new PageTextOnly(1).addTextReplacement("", ConfigIntValues.LEAF_GENERATOR_CF_PER_LEAF.getValue()).addTextReplacement("", ConfigIntValues.LEAF_GENERATOR_AREA.getValue()), new PageCrafting(2, BlockCrafting.recipeLeafGen)).setImportant(); new BookletChapter("bioReactor", ActuallyAdditionsAPI.entryGeneratingRF, new ItemStack(ActuallyBlocks.blockBioReactor.get()), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeBioReactor).setNoText()).setSpecial(); //No RF Using Items - chaptersIntroduction[9] = new BookletChapter("goggles", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemEngineerGoggles.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeGoggles).setNoText(), new PageCrafting(3, ItemCrafting.recipeGogglesAdvanced).setNoText()).setImportant(); - new BookletChapter("bags", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemBag.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeBag), new PageCrafting(3, ItemCrafting.recipeVoidBag).setNoText()).setImportant(); - new BookletChapter("wings", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemWingsOfTheBats.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.BAT_WING.ordinal())).addTextReplacement("", ItemWingsOfTheBats.MAX_FLY_TIME / 20), new PageCrafting(2, ItemCrafting.recipeWings).setNoText()).setSpecial(); - new BookletChapter("foods", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemFoods.get(), 1, TheFoods.HAMBURGER.ordinal()), new PageCrafting(1, FoodCrafting.recipeBacon).setNoText(), new PageFurnace(2, new ItemStack(InitItems.itemFoods.get(), 1, TheFoods.RICE_BREAD.ordinal())).setNoText(), new PageCrafting(3, FoodCrafting.recipeHamburger).setNoText(), new PageCrafting(4, FoodCrafting.recipeBigCookie).setNoText(), new PageCrafting(5, FoodCrafting.recipeSubSandwich).setNoText(), new PageCrafting(6, FoodCrafting.recipeFrenchFry).setNoText(), new PageCrafting(7, FoodCrafting.recipeFrenchFries).setNoText(), new PageCrafting(8, FoodCrafting.recipeFishNChips).setNoText(), new PageCrafting(9, FoodCrafting.recipeCheese).setNoText(), new PageCrafting(10, FoodCrafting.recipePumpkinStew).setNoText(), new PageCrafting(11, FoodCrafting.recipeCarrotJuice).setNoText(), new PageCrafting(12, FoodCrafting.recipeSpaghetti).setNoText(), new PageCrafting(13, FoodCrafting.recipeNoodle).setNoText(), new PageCrafting(14, FoodCrafting.recipeChocolate).setNoText(), new PageCrafting(15, FoodCrafting.recipeChocolateCake).setNoText(), new PageCrafting(16, FoodCrafting.recipeToast).setNoText(), new PageFurnace(17, new ItemStack(InitItems.itemFoods.get(), 1, TheFoods.BAGUETTE.ordinal())).setNoText(), new PageCrafting(18, FoodCrafting.recipeChocolateToast).setNoText(), new PageCrafting(1, FoodCrafting.recipePizza).setNoText()); - new BookletChapter("leafBlower", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemLeafBlowerAdvanced.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLeafBlower).setNoText(), new PageCrafting(3, ItemCrafting.recipeLeafBlowerAdvanced).setNoText()).setImportant(); - new BookletChapter("playerProbe", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemPlayerProbe.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipePlayerProbe).setNoText()).setSpecial(); + chaptersIntroduction[9] = new BookletChapter("goggles", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemEngineerGoggles.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeGoggles).setNoText(), new PageCrafting(3, ItemCrafting.recipeGogglesAdvanced).setNoText()).setImportant(); + new BookletChapter("bags", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemBag.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeBag), new PageCrafting(3, ItemCrafting.recipeVoidBag).setNoText()).setImportant(); + new BookletChapter("wings", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemWingsOfTheBats.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemBatWing.get())).addTextReplacement("", ItemWingsOfTheBats.MAX_FLY_TIME / 20), new PageCrafting(2, ItemCrafting.recipeWings).setNoText()).setSpecial(); + new BookletChapter("foods", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemFoods.get(), 1, TheFoods.HAMBURGER.ordinal()), new PageCrafting(1, FoodCrafting.recipeBacon).setNoText(), new PageFurnace(2, new ItemStack(ActuallyItems.itemFoods.get(), 1, TheFoods.RICE_BREAD.ordinal())).setNoText(), new PageCrafting(3, FoodCrafting.recipeHamburger).setNoText(), new PageCrafting(4, FoodCrafting.recipeBigCookie).setNoText(), new PageCrafting(5, FoodCrafting.recipeSubSandwich).setNoText(), new PageCrafting(6, FoodCrafting.recipeFrenchFry).setNoText(), new PageCrafting(7, FoodCrafting.recipeFrenchFries).setNoText(), new PageCrafting(8, FoodCrafting.recipeFishNChips).setNoText(), new PageCrafting(9, FoodCrafting.recipeCheese).setNoText(), new PageCrafting(10, FoodCrafting.recipePumpkinStew).setNoText(), new PageCrafting(11, FoodCrafting.recipeCarrotJuice).setNoText(), new PageCrafting(12, FoodCrafting.recipeSpaghetti).setNoText(), new PageCrafting(13, FoodCrafting.recipeNoodle).setNoText(), new PageCrafting(14, FoodCrafting.recipeChocolate).setNoText(), new PageCrafting(15, FoodCrafting.recipeChocolateCake).setNoText(), new PageCrafting(16, FoodCrafting.recipeToast).setNoText(), new PageFurnace(17, new ItemStack(ActuallyItems.itemFoods.get(), 1, TheFoods.BAGUETTE.ordinal())).setNoText(), new PageCrafting(18, FoodCrafting.recipeChocolateToast).setNoText(), new PageCrafting(1, FoodCrafting.recipePizza).setNoText()); + new BookletChapter("leafBlower", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemLeafBlowerAdvanced.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLeafBlower).setNoText(), new PageCrafting(3, ItemCrafting.recipeLeafBlowerAdvanced).setNoText()).setImportant(); + new BookletChapter("playerProbe", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemPlayerProbe.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipePlayerProbe).setNoText()).setSpecial(); ArrayList aiotPages = new ArrayList<>(); aiotPages.add(new PageTextOnly(aiotPages.size() + 1)); for (IRecipe recipe : ToolCrafting.RECIPES_PAXELS) { aiotPages.add(new PageCrafting(aiotPages.size() + 1, recipe).setWildcard().setNoText()); } - new BookletChapter("aiots", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.emeraldPaxel.get()), aiotPages.toArray(new BookletPage[aiotPages.size()])).setImportant(); + new BookletChapter("aiots", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.emeraldPaxel.get()), aiotPages.toArray(new BookletPage[aiotPages.size()])).setImportant(); - new BookletChapter("jams", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemJams.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemJams.get(), 1, Util.WILDCARD)), new PagePicture(2, "page_jam_house", 150), new PageTextOnly(3)); + new BookletChapter("jams", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemJams.get()), new PageTextOnly(1).addItemsToPage(new ItemStack(ActuallyItems.itemJams.get(), 1, Util.WILDCARD)), new PagePicture(2, "page_jam_house", 150), new PageTextOnly(3)); ArrayList potionRingPages = new ArrayList<>(); potionRingPages.add(new PageTextOnly(potionRingPages.size() + 1)); for (IRecipe recipe : ItemCrafting.RECIPES_POTION_RINGS) { potionRingPages.add(new PageCrafting(potionRingPages.size() + 1, recipe).setNoText()); } - new BookletChapter("potionRings", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemPotionRing.get()), potionRingPages.toArray(new BookletPage[potionRingPages.size()])); - new BookletChapter("spawnerChanger", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(InitItems.itemSpawnerChanger.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeSpawnerChanger).setNoText()); - new BookletChapter("itemFilter", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitItems.itemFilter.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeFilter).setNoText()).setImportant(); + new BookletChapter("potionRings", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemPotionRing.get()), potionRingPages.toArray(new BookletPage[potionRingPages.size()])); + new BookletChapter("spawnerChanger", ActuallyAdditionsAPI.entryItemsNonRF, new ItemStack(ActuallyItems.itemSpawnerChanger.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeSpawnerChanger).setNoText()); + new BookletChapter("itemFilter", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(ActuallyItems.itemFilter.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeFilter).setNoText()).setImportant(); //RF Using Items - new BookletChapter("drill", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemDrill.get(), 1, TheColoredLampColors.LIGHT_BLUE.ordinal()), new PageTextOnly(1), new PageTextOnly(2), new PageCrafting(3, ItemCrafting.recipeDrill).setNoText(), new PageCrafting(4, ItemCrafting.RECIPES_DRILL_COLORING), new PageCrafting(4, ItemCrafting.recipeDrillCore).setNoText(), new PageCrafting(5, ItemCrafting.recipeDrillSpeedI).setNoText(), new PageCrafting(6, ItemCrafting.recipeDrillSpeedII).setNoText(), new PageCrafting(7, ItemCrafting.recipeDrillSpeedIII).setNoText(), new PageCrafting(8, ItemCrafting.recipeDrillFortuneI).setNoText(), new PageCrafting(9, ItemCrafting.recipeDrillFortuneII).setNoText(), new PageCrafting(10, ItemCrafting.recipeDrillSilk).setNoText(), new PageCrafting(11, ItemCrafting.recipeDrillThree).setNoText(), new PageCrafting(12, ItemCrafting.recipeDrillFive).setNoText(), new PageCrafting(13, ItemCrafting.recipeDrillPlacing).setNoText()).setSpecial(); - new BookletChapter("fillingWand", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemFillingWand.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeFillingWand).setNoText()).setSpecial(); - new BookletChapter("staff", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemTeleStaff.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeStaff).setNoText()).setImportant(); - new BookletChapter("magnetRing", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemMagnetRing.get()), new PageCrafting(1, ItemCrafting.recipeMagnetRing)); - new BookletChapter("growthRing", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemGrowthRing.get()), new PageCrafting(1, ItemCrafting.recipeGrowthRing)); - new BookletChapter("waterRemovalRing", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemWaterRemovalRing.get()), new PageCrafting(1, ItemCrafting.recipeWaterRing)); - new BookletChapter("batteries", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(InitItems.itemBatteryTriple.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeBattery).setNoText(), new PageCrafting(3, ItemCrafting.recipeBatteryDouble).setNoText(), new PageCrafting(4, ItemCrafting.recipeBatteryTriple).setNoText(), new PageCrafting(5, ItemCrafting.recipeBatteryQuadruple).setNoText(), new PageCrafting(6, ItemCrafting.recipeBatteryQuintuple).setNoText()); + new BookletChapter("drill", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemDrill.get(), 1, TheColoredLampColors.LIGHT_BLUE.ordinal()), new PageTextOnly(1), new PageTextOnly(2), new PageCrafting(3, ItemCrafting.recipeDrill).setNoText(), new PageCrafting(4, ItemCrafting.RECIPES_DRILL_COLORING), new PageCrafting(4, ItemCrafting.recipeDrillCore).setNoText(), new PageCrafting(5, ItemCrafting.recipeDrillSpeedI).setNoText(), new PageCrafting(6, ItemCrafting.recipeDrillSpeedII).setNoText(), new PageCrafting(7, ItemCrafting.recipeDrillSpeedIII).setNoText(), new PageCrafting(8, ItemCrafting.recipeDrillFortuneI).setNoText(), new PageCrafting(9, ItemCrafting.recipeDrillFortuneII).setNoText(), new PageCrafting(10, ItemCrafting.recipeDrillSilk).setNoText(), new PageCrafting(11, ItemCrafting.recipeDrillThree).setNoText(), new PageCrafting(12, ItemCrafting.recipeDrillFive).setNoText(), new PageCrafting(13, ItemCrafting.recipeDrillPlacing).setNoText()).setSpecial(); + new BookletChapter("fillingWand", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemFillingWand.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeFillingWand).setNoText()).setSpecial(); + new BookletChapter("staff", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemTeleStaff.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeStaff).setNoText()).setImportant(); + new BookletChapter("magnetRing", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemMagnetRing.get()), new PageCrafting(1, ItemCrafting.recipeMagnetRing)); + new BookletChapter("growthRing", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemGrowthRing.get()), new PageCrafting(1, ItemCrafting.recipeGrowthRing)); + new BookletChapter("waterRemovalRing", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemWaterRemovalRing.get()), new PageCrafting(1, ItemCrafting.recipeWaterRing)); + new BookletChapter("batteries", ActuallyAdditionsAPI.entryItemsRF, new ItemStack(ActuallyItems.itemBatteryTriple.get()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeBattery).setNoText(), new PageCrafting(3, ItemCrafting.recipeBatteryDouble).setNoText(), new PageCrafting(4, ItemCrafting.recipeBatteryTriple).setNoText(), new PageCrafting(5, ItemCrafting.recipeBatteryQuadruple).setNoText(), new PageCrafting(6, ItemCrafting.recipeBatteryQuintuple).setNoText()); //Updates and infos new BookletChapter("changelog", ActuallyAdditionsAPI.entryUpdatesAndInfos, new ItemStack(Items.CLOCK), new PageLinkButton(1, UpdateChecker.CHANGELOG_LINK)); new BookletChapter("curse", ActuallyAdditionsAPI.entryUpdatesAndInfos, new ItemStack(Items.FLINT_AND_STEEL), new PageLinkButton(1, "http://ellpeck.de/actadd")); - new BookletChapter("patreon", ActuallyAdditionsAPI.entryUpdatesAndInfos, new ItemStack(InitItems.EMERADIC_CRYSTAL.get(), 1), new PageLinkButton(1, "http://patreon.com/Ellpeck"), new PagePicture(2, "page_patreon", 153)).setImportant(); - new BookletChapter("website", ActuallyAdditionsAPI.entryUpdatesAndInfos, new ItemStack(InitItems.itemBooklet.get()), new PageLinkButton(1, "http://ellpeck.de")); + new BookletChapter("patreon", ActuallyAdditionsAPI.entryUpdatesAndInfos, new ItemStack(ActuallyItems.EMERADIC_CRYSTAL.get(), 1), new PageLinkButton(1, "http://patreon.com/Ellpeck"), new PagePicture(2, "page_patreon", 153)).setImportant(); + new BookletChapter("website", ActuallyAdditionsAPI.entryUpdatesAndInfos, new ItemStack(ActuallyItems.itemBooklet.get()), new PageLinkButton(1, "http://ellpeck.de")); //Trials chaptersIntroduction[10] = new BookletChapter("trialsIntro", ActuallyAdditionsAPI.entryTrials, new ItemStack(Items.GOLD_INGOT), new PageTextOnly(1), new PageTextOnly(2)).setSpecial(); - new BookletChapterTrials("crystalProduction", new ItemStack(InitItems.EMERADIC_CRYSTAL.get()), false); + new BookletChapterTrials("crystalProduction", new ItemStack(ActuallyItems.EMERADIC_CRYSTAL.get()), false); new BookletChapterTrials("leatherProduction", new ItemStack(Items.LEATHER), false); new BookletChapterTrials("crystalOil", FluidUtil.getFilledBucket(new FluidStack(InitFluids.fluidCrystalOil, Fluid.BUCKET_VOLUME)), false); - new BookletChapterTrials("autoDisenchanter", new ItemStack(InitItems.itemDisenchantingLens.get()), false); + new BookletChapterTrials("autoDisenchanter", new ItemStack(ActuallyItems.itemDisenchantingLens.get()), false); new BookletChapterTrials("empoweredOil", FluidUtil.getFilledBucket(new FluidStack(InitFluids.fluidEmpoweredOil, Fluid.BUCKET_VOLUME)), false); new BookletChapterTrials("mobFarm", new ItemStack(Items.ROTTEN_FLESH), false); new BookletChapterTrials("empowererAutomation", new ItemStack(ActuallyBlocks.blockEmpowerer.get()), false); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageCoffeeMachine.java b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageCoffeeMachine.java index 4287cdc77..bb3f4f4b9 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageCoffeeMachine.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/booklet/page/PageCoffeeMachine.java @@ -14,7 +14,7 @@ import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; import de.ellpeck.actuallyadditions.api.booklet.internal.GuiBookletBase; import de.ellpeck.actuallyadditions.api.recipe.CoffeeIngredient; import de.ellpeck.actuallyadditions.mod.booklet.gui.GuiBooklet; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.item.ItemStack; import net.minecraftforge.api.distmarker.Dist; import net.minecraftforge.api.distmarker.OnlyIn; @@ -35,7 +35,7 @@ public class PageCoffeeMachine extends BookletPage { this.ingredient = ingredient; this.stacks = ingredient.getInput().getMatchingStacks(); - this.outcome = new ItemStack(InitItems.itemCoffee.get()); + this.outcome = new ItemStack(ActuallyItems.itemCoffee.get()); ActuallyAdditionsAPI.methodHandler.addEffectToStack(this.outcome, this.ingredient); } @@ -65,8 +65,8 @@ public class PageCoffeeMachine extends BookletPage { gui.addOrModifyItemRenderer(this.stacks[0], startX + 5 + 82, startY + 10 + 1, 1F, true); gui.addOrModifyItemRenderer(this.outcome, startX + 5 + 36, startY + 10 + 42, 1F, false); - gui.addOrModifyItemRenderer(new ItemStack(InitItems.itemCoffeeCup.get()), startX + 5 + 37, startY + 10 + 1, 1F, true); - gui.addOrModifyItemRenderer(new ItemStack(InitItems.itemCoffee.get()), startX + 5 + 1, startY + 10 + 1, 1F, true); + gui.addOrModifyItemRenderer(new ItemStack(ActuallyItems.itemCoffeeCup.get()), startX + 5 + 37, startY + 10 + 1, 1F, true); + gui.addOrModifyItemRenderer(new ItemStack(ActuallyItems.itemCoffee.get()), startX + 5 + 1, startY + 10 + 1, 1F, true); } @Override diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/entity/RenderWorm.java b/src/main/java/de/ellpeck/actuallyadditions/mod/entity/RenderWorm.java index 844373fbf..9df1341af 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/entity/RenderWorm.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/entity/RenderWorm.java @@ -10,7 +10,7 @@ package de.ellpeck.actuallyadditions.mod.entity; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.util.AssetUtil; import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.entity.Render; @@ -27,7 +27,7 @@ public class RenderWorm extends Render { private static ItemStack stack = ItemStack.EMPTY; public static void fixItemStack() { - stack = new ItemStack(InitItems.itemWorm.get()); + stack = new ItemStack(ActuallyItems.itemWorm.get()); } protected RenderWorm(RenderManager renderManager) { diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/event/CommonEvents.java b/src/main/java/de/ellpeck/actuallyadditions/mod/event/CommonEvents.java index 819466323..bea2dfb23 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/event/CommonEvents.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/event/CommonEvents.java @@ -15,7 +15,7 @@ import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues; import de.ellpeck.actuallyadditions.mod.data.PlayerData; import de.ellpeck.actuallyadditions.mod.data.WorldData; import de.ellpeck.actuallyadditions.mod.inventory.ContainerBag; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemBag; import de.ellpeck.actuallyadditions.mod.items.ItemDrill; import de.ellpeck.actuallyadditions.mod.network.PacketHandlerHelper; @@ -163,7 +163,7 @@ public class CommonEvents { //checkAchievements(event.crafting, event.player, InitAchievements.Type.CRAFTING); if (ConfigBoolValues.GIVE_BOOKLET_ON_FIRST_CRAFT.isEnabled()) { - if (!event.getPlayer().world.isRemote && StackUtil.isValid(event.getCrafting()) && event.getCrafting().getItem() != InitItems.itemBooklet.get()) { + if (!event.getPlayer().world.isRemote && StackUtil.isValid(event.getCrafting()) && event.getCrafting().getItem() != ActuallyItems.itemBooklet.get()) { String name = event.getCrafting().getItem().getRegistryName().toString(); if (name != null && name.toLowerCase(Locale.ROOT).contains(ActuallyAdditions.MODID)) { @@ -172,7 +172,7 @@ public class CommonEvents { save.bookGottenAlready = true; WorldData.get(event.getPlayer().getEntityWorld()).markDirty(); - ItemEntity entityItem = new ItemEntity(event.getPlayer().world, event.getPlayer().getPosX(), event.getPlayer().getPosY(), event.getPlayer().getPosZ(), new ItemStack(InitItems.itemBooklet.get())); + ItemEntity entityItem = new ItemEntity(event.getPlayer().world, event.getPlayer().getPosX(), event.getPlayer().getPosY(), event.getPlayer().getPosZ(), new ItemStack(ActuallyItems.itemBooklet.get())); entityItem.setPickupDelay(0); event.getPlayer().world.addEntity(entityItem); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/gen/village/component/VillageComponentEngineerHouse.java b/src/main/java/de/ellpeck/actuallyadditions/mod/gen/village/component/VillageComponentEngineerHouse.java index 99ea18de6..5c50d5f2e 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/gen/village/component/VillageComponentEngineerHouse.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/gen/village/component/VillageComponentEngineerHouse.java @@ -20,14 +20,14 @@ import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheMiscBlocks; import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues; import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.gen.village.InitVillager; -import de.ellpeck.actuallyadditions.mod.items.InitItems; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot; import de.ellpeck.actuallyadditions.mod.tile.*; import net.minecraft.block.Block; -import net.minecraft.init.Blocks; -import net.minecraft.init.Items; +import net.minecraft.block.Blocks; +import net.minecraft.entity.merchant.villager.VillagerProfession; import net.minecraft.item.ItemStack; +import net.minecraft.item.Items; import net.minecraft.server.MinecraftServer; import net.minecraft.tileentity.TileEntity; import net.minecraft.util.Direction; @@ -36,15 +36,10 @@ import net.minecraft.util.ResourceLocation; import net.minecraft.util.Rotation; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; -import net.minecraft.world.gen.structure.StructureBoundingBox; -import net.minecraft.world.gen.structure.StructureComponent; -import net.minecraft.world.gen.structure.StructureVillagePieces; -import net.minecraft.world.gen.structure.template.PlacementSettings; -import net.minecraft.world.gen.structure.template.Template; -import net.minecraft.world.gen.structure.template.TemplateManager; -import net.minecraftforge.fluids.FluidRegistry; +import net.minecraft.world.gen.feature.template.PlacementSettings; +import net.minecraft.world.gen.feature.template.Template; +import net.minecraft.world.gen.feature.template.TemplateManager; import net.minecraftforge.fluids.FluidStack; -import net.minecraftforge.fml.common.registry.VillagerRegistry.VillagerProfession; import java.util.List; import java.util.Random; @@ -112,7 +107,7 @@ public class VillageComponentEngineerHouse extends StructureVillagePieces.House1 if (compost instanceof TileEntityCompost) { TileEntityCompost tile = (TileEntityCompost) compost; tile.stopFromDropping = true; - tile.inv.setStackInSlot(0, new ItemStack(InitItems.itemFertilizer, 10)); + tile.inv.setStackInSlot(0, new ItemStack(ActuallyItems.itemFertilizer, 10)); } } @@ -137,7 +132,7 @@ public class VillageComponentEngineerHouse extends StructureVillagePieces.House1 TileEntityCanolaPress tile = (TileEntityCanolaPress) press; tile.stopFromDropping = true; tile.storage.setEnergyStored(world.rand.nextInt(tile.storage.getMaxEnergyStored() / 3)); - tile.inv.setStackInSlot(0, new ItemStack(InitItems.itemMisc, world.rand.nextInt(60) + 1, TheMiscItems.CANOLA.ordinal())); + tile.inv.setStackInSlot(0, new ItemStack(ActuallyItems.itemCanola.get(), world.rand.nextInt(60) + 1)); } TileEntity crusher = this.getTileAtPos(world, 2, 1, 6, sbb); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCanolaPress.java b/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCanolaPress.java index 8ab2b1fd8..176cab736 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCanolaPress.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCanolaPress.java @@ -11,7 +11,7 @@ package de.ellpeck.actuallyadditions.mod.inventory; import de.ellpeck.actuallyadditions.mod.inventory.slot.SlotItemHandlerUnconditioned; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.tile.TileEntityCanolaPress; import de.ellpeck.actuallyadditions.mod.util.StackUtil; import net.minecraft.entity.player.PlayerEntity; @@ -63,7 +63,7 @@ public class ContainerCanolaPress extends Container { //Other Slots in Inventory excluded if (slot >= inventoryStart) { //Shift from Inventory - if (newStack.getItem() == InitItems.itemCanola.get()) { + if (newStack.getItem() == ActuallyItems.itemCanola.get()) { if (!this.mergeItemStack(newStack, 0, 1, false)) { return StackUtil.getEmpty(); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCoffeeMachine.java b/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCoffeeMachine.java index 539951c55..311bc91b1 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCoffeeMachine.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/inventory/ContainerCoffeeMachine.java @@ -13,7 +13,7 @@ package de.ellpeck.actuallyadditions.mod.inventory; import de.ellpeck.actuallyadditions.api.ActuallyTags; import de.ellpeck.actuallyadditions.mod.inventory.slot.SlotItemHandlerUnconditioned; import de.ellpeck.actuallyadditions.mod.inventory.slot.SlotOutput; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemCoffee; import de.ellpeck.actuallyadditions.mod.tile.TileEntityCoffeeMachine; import de.ellpeck.actuallyadditions.mod.util.StackUtil; @@ -81,7 +81,7 @@ public class ContainerCoffeeMachine extends Container { //Other Slots in Inventory excluded else if (slot >= inventoryStart) { //Shift from Inventory - if (newStack.getItem() == InitItems.itemCoffeeCup.get()) { + if (newStack.getItem() == ActuallyItems.itemCoffeeCup.get()) { if (!this.mergeItemStack(newStack, TileEntityCoffeeMachine.SLOT_INPUT, TileEntityCoffeeMachine.SLOT_INPUT + 1, false)) { return StackUtil.getEmpty(); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ActuallyItems.java similarity index 77% rename from src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java rename to src/main/java/de/ellpeck/actuallyadditions/mod/items/ActuallyItems.java index 2ed0ccf29..b5e81fa2c 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ActuallyItems.java @@ -16,24 +16,49 @@ import de.ellpeck.actuallyadditions.mod.blocks.ActuallyBlocks; import de.ellpeck.actuallyadditions.mod.items.base.*; import de.ellpeck.actuallyadditions.mod.items.lens.ItemLens; import de.ellpeck.actuallyadditions.mod.items.metalists.TheFoods; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; import de.ellpeck.actuallyadditions.mod.material.ArmorMaterials; import de.ellpeck.actuallyadditions.mod.material.ToolMaterials; +import net.minecraft.inventory.EquipmentSlotType; import net.minecraft.item.Item; import net.minecraft.item.ItemTier; import net.minecraftforge.fml.RegistryObject; import net.minecraftforge.registries.DeferredRegister; import net.minecraftforge.registries.ForgeRegistries; -public final class InitItems { +public final class ActuallyItems { public static final DeferredRegister ITEMS = DeferredRegister.create(ForgeRegistries.ITEMS, ActuallyAdditions.MODID); // REMOVE ME @Deprecated public static final RegistryObject itemMisc = ITEMS.register("item_misc", ItemBase::new); + + // MISC ITEMS public static final RegistryObject itemCanola = ITEMS.register("canola", ItemBase::new); public static final RegistryObject itemCoffeeCup = ITEMS.register("coffee_cup", ItemBase::new); public static final RegistryObject itemPaperCone = ITEMS.register("paper_cone", ItemBase::new); + public static final RegistryObject itemMashedFood = ITEMS.register("mashed_food", ItemBase::new); + public static final RegistryObject itemKnifeBlade = ITEMS.register("knife_blade", ItemBase::new); + public static final RegistryObject itemKnifeHandle = ITEMS.register("knife_handle", ItemBase::new); + public static final RegistryObject itemDough = ITEMS.register("dough", ItemBase::new); + public static final RegistryObject itemBlackQuartz = ITEMS.register("black_quartz", ItemBase::new); + public static final RegistryObject itemRing = ITEMS.register("ring", ItemBase::new); + public static final RegistryObject itemCoil = ITEMS.register("coil", ItemBase::new); + public static final RegistryObject itemCoilAdvanced = ITEMS.register("coil_advanced", ItemBase::new); + public static final RegistryObject itemRiceDough = ITEMS.register("rice_dough", ItemBase::new); + public static final RegistryObject itemTinyCoal = ITEMS.register("tiny_coal", ItemBase::new); + public static final RegistryObject itemTinyChar = ITEMS.register("tiny_charcoal", ItemBase::new); + public static final RegistryObject itemRiceSlime = ITEMS.register("rice_slime", ItemBase::new); + public static final RegistryObject itemCup = ITEMS.register("cup", ItemBase::new); + public static final RegistryObject itemBatWing = ITEMS.register("bat_wing", ItemBase::new); + public static final RegistryObject itemDrillCore = ITEMS.register("drill_core", ItemBase::new); + public static final RegistryObject itemBlackDye = ITEMS.register("black_dye", ItemBase::new); + public static final RegistryObject itemLens = ITEMS.register("lens", ItemBase::new); + public static final RegistryObject itemEnderStar = ITEMS.register("ender_star", ItemBase::new); + public static final RegistryObject itemSpawnerShard = ITEMS.register("spawner_shard", ItemBase::new); + public static final RegistryObject itemBiomass = ITEMS.register("biomass", ItemBase::new); + public static final RegistryObject itemBiocoal = ITEMS.register("biocoal", ItemBase::new); + public static final RegistryObject itemCrystallizedCanolaSeed = ITEMS.register("crystallized_canola_seed", ItemBase::new); + public static final RegistryObject itemEmpoweredCanolaSeed = ITEMS.register("empowered_canola_seed", ItemBase::new); // SHARDS public static final RegistryObject RESTONIA_CRYSTAL_SHARD = ITEMS.register("item_restonia_crystal_shard", ItemBase::new); @@ -60,7 +85,7 @@ public final class InitItems { // BLACK QUARTZ public static final RegistryObject BLACK_QUARTZ = ITEMS.register("black_quartz", ItemBase::new); - + public static final RegistryObject itemEngineerGogglesAdvanced = ITEMS.register("item_engineer_goggles_advanced", () -> new ItemEngineerGoggles(true)); public static final RegistryObject itemEngineerGoggles = ITEMS.register("item_engineer_goggles", () -> new ItemEngineerGoggles(false)); public static final RegistryObject itemLaserUpgradeRange = ITEMS.register("item_laser_upgrade_range", ItemBase::new); @@ -91,20 +116,20 @@ public final class InitItems { public static final RegistryObject itemTeleStaff = ITEMS.register("item_tele_staff", ItemTeleStaff::new); public static final RegistryObject itemWingsOfTheBats = ITEMS.register("item_wings_of_the_bats", ItemWingsOfTheBats::new); public static final RegistryObject itemDrill = ITEMS.register("item_drill", ItemDrill::new); - public static final RegistryObject itemBattery = ITEMS.register("item_battery", new ItemBattery(200000, 1000)); - public static final RegistryObject itemBatteryDouble = ITEMS.register("item_battery_double", new ItemBattery(350000, 5000)); - public static final RegistryObject itemBatteryTriple = ITEMS.register("item_battery_triple", new ItemBattery(600000, 10000)); - public static final RegistryObject itemBatteryQuadruple = ITEMS.register("item_battery_quadruple", new ItemBattery(1000000, 30000)); - public static final RegistryObject itemBatteryQuintuple = ITEMS.register("item_battery_quintuple", new ItemBattery(2000000, 100000)); - public static final RegistryObject itemDrillUpgradeSpeed = ITEMS.register("item_drill_upgrade_speed", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SPEED)); - public static final RegistryObject itemDrillUpgradeSpeedII = ITEMS.register("item_drill_upgrade_speed_ii", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SPEED_II)); - public static final RegistryObject itemDrillUpgradeSpeedIII = ITEMS.register("item_drill_upgrade_speed_iii", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SPEED_III)); - public static final RegistryObject itemDrillUpgradeSilkTouch = ITEMS.register("item_drill_upgrade_silk_touch", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SILK_TOUCH)); - public static final RegistryObject itemDrillUpgradeFortune = ITEMS.register("item_drill_upgrade_fortune", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.FORTUNE)); - public static final RegistryObject itemDrillUpgradeFortuneII = ITEMS.register("item_drill_upgrade_fortune_ii", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.FORTUNE_II)); - public static final RegistryObject itemDrillUpgradeThreeByThree = ITEMS.register("item_drill_upgrade_three_by_three", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.THREE_BY_THREE)); - public static final RegistryObject itemDrillUpgradeFiveByFive = ITEMS.register("item_drill_upgrade_five_by_five", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.FIVE_BY_FIVE)); - public static final RegistryObject itemDrillUpgradeBlockPlacing = ITEMS.register("item_drill_upgrade_block_placing", new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.PLACER)); + public static final RegistryObject itemBattery = ITEMS.register("item_battery", () -> new ItemBattery(200000, 1000)); + public static final RegistryObject itemBatteryDouble = ITEMS.register("item_battery_double", () -> new ItemBattery(350000, 5000)); + public static final RegistryObject itemBatteryTriple = ITEMS.register("item_battery_triple", () -> new ItemBattery(600000, 10000)); + public static final RegistryObject itemBatteryQuadruple = ITEMS.register("item_battery_quadruple", () -> new ItemBattery(1000000, 30000)); + public static final RegistryObject itemBatteryQuintuple = ITEMS.register("item_battery_quintuple", () -> new ItemBattery(2000000, 100000)); + public static final RegistryObject itemDrillUpgradeSpeed = ITEMS.register("item_drill_upgrade_speed", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SPEED)); + public static final RegistryObject itemDrillUpgradeSpeedII = ITEMS.register("item_drill_upgrade_speed_ii", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SPEED_II)); + public static final RegistryObject itemDrillUpgradeSpeedIII = ITEMS.register("item_drill_upgrade_speed_iii", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SPEED_III)); + public static final RegistryObject itemDrillUpgradeSilkTouch = ITEMS.register("item_drill_upgrade_silk_touch", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.SILK_TOUCH)); + public static final RegistryObject itemDrillUpgradeFortune = ITEMS.register("item_drill_upgrade_fortune", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.FORTUNE)); + public static final RegistryObject itemDrillUpgradeFortuneII = ITEMS.register("item_drill_upgrade_fortune_ii", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.FORTUNE_II)); + public static final RegistryObject itemDrillUpgradeThreeByThree = ITEMS.register("item_drill_upgrade_three_by_three", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.THREE_BY_THREE)); + public static final RegistryObject itemDrillUpgradeFiveByFive = ITEMS.register("item_drill_upgrade_five_by_five", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.FIVE_BY_FIVE)); + public static final RegistryObject itemDrillUpgradeBlockPlacing = ITEMS.register("item_drill_upgrade_block_placing", () -> new ItemDrillUpgrade(ItemDrillUpgrade.UpgradeType.PLACER)); public static final RegistryObject itemFertilizer = ITEMS.register("item_fertilizer", ItemFertilizer::new); public static final RegistryObject itemCoffee = ITEMS.register("item_coffee", ItemCoffee::new); public static final RegistryObject itemPhantomConnector = ITEMS.register("item_phantom_connector", ItemPhantomConnector::new); @@ -115,22 +140,26 @@ public final class InitItems { public static final RegistryObject itemCrafterOnAStick = ITEMS.register("item_crafter_on_a_stick", ItemCrafterOnAStick::new); public static final RegistryObject itemDust = ITEMS.register("item_dust", ItemDust::new); public static final RegistryObject itemSolidifiedExperience = ITEMS.register("item_solidified_experience", ItemSolidifiedExperience::new); - public static final RegistryObject itemLeafBlower = ITEMS.register("item_leaf_blower", new ItemLeafBlower(false)); - public static final RegistryObject itemLeafBlowerAdvanced = ITEMS.register("item_leaf_blower_advanced", new ItemLeafBlower(true)); - public static final RegistryObject itemPotionRing = ITEMS.register("item_potion_ring", new ItemPotionRing(false)); - public static final RegistryObject itemPotionRingAdvanced = ITEMS.register("item_potion_ring_advanced", new ItemPotionRing(true)); + public static final RegistryObject itemLeafBlower = ITEMS.register("item_leaf_blower", () -> new ItemLeafBlower(false)); + public static final RegistryObject itemLeafBlowerAdvanced = ITEMS.register("item_leaf_blower_advanced", () -> new ItemLeafBlower(true)); + + // TODO [port] unflatten + public static final RegistryObject itemPotionRing = ITEMS.register("item_potion_ring", () -> new ItemPotionRing(false)); + public static final RegistryObject itemPotionRingAdvanced = ITEMS.register("item_potion_ring_advanced", () -> new ItemPotionRing(true)); + public static final RegistryObject itemHairyBall = ITEMS.register("item_hairy_ball", ItemHairyBall::new); public static final RegistryObject itemCoffeeBean = ITEMS.register("item_coffee_beans", ItemCoffeeBean::new); - public static final RegistryObject itemRiceSeed = ITEMS.register("", new ItemSeed("item_rice_seed", "seedRice", ActuallyBlocks.blockRice, itemFoods, TheFoods.RICE.ordinal())); - public static final RegistryObject itemCanolaSeed = ITEMS.register("", new ItemFoodSeed("item_canola_seed", "seedCanola", ActuallyBlocks.blockCanola, itemMisc, TheMiscItems.CANOLA.ordinal(), 1, 0.01F, 10).setPotionEffect(new PotionEffect(MobEffects.NAUSEA, 1000, 0), 0.2F)); - public static final RegistryObject itemFlaxSeed = ITEMS.register("", new ItemSeed("item_flax_seed", "seedFlax", ActuallyBlocks.blockFlax, Items.STRING, 0)); - public static final RegistryObject itemCoffeeSeed = ITEMS.register("", new ItemSeed("item_coffee_seed", "seedCoffeeBeans", ActuallyBlocks.blockCoffee, itemCoffeeBean, 0)); + + public static final RegistryObject itemRiceSeed = ITEMS.register("item_rice_seed", () -> new ItemSeed("seedRice", ActuallyBlocks.blockRice.get(), itemFoods.get(), TheFoods.RICE.ordinal())); + public static final RegistryObject itemCanolaSeed = ITEMS.register("item_canola_seed", () -> new ItemFoodSeed("seedCanola", ActuallyBlocks.blockCanola, itemMisc, 0, 1, 0.01F, 10).setPotionEffect(new PotionEffect(MobEffects.NAUSEA, 1000, 0), 0.2F)); + public static final RegistryObject itemFlaxSeed = ITEMS.register("item_flax_seed", () -> new ItemSeed("seedFlax", ActuallyBlocks.blockFlax, Items.STRING, 0)); + public static final RegistryObject itemCoffeeSeed = ITEMS.register("item_coffee_seed", () -> new ItemSeed("seedCoffeeBeans", ActuallyBlocks.blockCoffee, itemCoffeeBean, 0)); // TOOLS & ARMOR - public static final RegistryObject itemHelmQuartz = ITEMS.register("item_helm_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, 0)); - public static final RegistryObject itemChestQuartz = ITEMS.register("item_chest_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, 1)); - public static final RegistryObject itemPantsQuartz = ITEMS.register("item_pants_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, 2)); - public static final RegistryObject itemBootsQuartz = ITEMS.register("item_boots_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, 3)); + public static final RegistryObject itemHelmQuartz = ITEMS.register("item_helm_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestQuartz = ITEMS.register("item_chest_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsQuartz = ITEMS.register("item_pants_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsQuartz = ITEMS.register("item_boots_quartz", () -> new ItemArmorAA(ArmorMaterials.QUARTZ, EquipmentSlotType.FEET)); public static final RegistryObject itemPickaxeQuartz = ITEMS.register("item_pickaxe_quartz", () -> new ItemPickaxeAA(ToolMaterials.QUARTZ)); public static final RegistryObject itemAxeQuartz = ITEMS.register("item_axe_quartz", () -> new ItemAxeAA(ToolMaterials.QUARTZ)); @@ -149,10 +178,10 @@ public final class InitItems { public static final RegistryObject itemShovelCrystalRed = ITEMS.register("item_shovel_crystal_restonia", () -> new ItemShovelAA(ToolMaterials.RESTONIA)); public static final RegistryObject itemSwordCrystalRed = ITEMS.register("item_sword_crystal_restonia", () -> new ItemSwordAA(ToolMaterials.RESTONIA)); public static final RegistryObject itemHoeCrystalRed = ITEMS.register("item_hoe_crystal_restonia", () -> new ItemHoeAA(ToolMaterials.RESTONIA)); - public static final RegistryObject itemHelmCrystalRed = ITEMS.register("item_helm_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, 0)); - public static final RegistryObject itemChestCrystalRed = ITEMS.register("item_chest_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, 1)); - public static final RegistryObject itemPantsCrystalRed = ITEMS.register("item_pants_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, 2)); - public static final RegistryObject itemBootsCrystalRed = ITEMS.register("item_boots_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, 3)); + public static final RegistryObject itemHelmCrystalRed = ITEMS.register("item_helm_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestCrystalRed = ITEMS.register("item_chest_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsCrystalRed = ITEMS.register("item_pants_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsCrystalRed = ITEMS.register("item_boots_crystal_red", () -> new ItemArmorAA(ArmorMaterials.RESTONIA, EquipmentSlotType.FEET)); public static final RegistryObject itemPaxelCrystalRed = ITEMS.register("item_paxel_crystal_red", () -> new ItemAllToolAA(ToolMaterials.RESTONIA)); public static final RegistryObject itemPickaxeCrystalBlue = ITEMS.register("item_pickaxe_crystal_blue", () -> new ItemPickaxeAA(ToolMaterials.PALIS)); @@ -160,10 +189,10 @@ public final class InitItems { public static final RegistryObject itemShovelCrystalBlue = ITEMS.register("item_shovel_crystal_blue", () -> new ItemShovelAA(ToolMaterials.PALIS)); public static final RegistryObject itemSwordCrystalBlue = ITEMS.register("item_sword_crystal_blue", () -> new ItemSwordAA(ToolMaterials.PALIS)); public static final RegistryObject itemHoeCrystalBlue = ITEMS.register("item_hoe_crystal_blue", () -> new ItemHoeAA(ToolMaterials.PALIS)); - public static final RegistryObject itemHelmCrystalBlue = ITEMS.register("item_helm_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, 0)); - public static final RegistryObject itemChestCrystalBlue = ITEMS.register("item_chest_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, 1)); - public static final RegistryObject itemPantsCrystalBlue = ITEMS.register("item_pants_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, 2)); - public static final RegistryObject itemBootsCrystalBlue = ITEMS.register("item_boots_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, 3)); + public static final RegistryObject itemHelmCrystalBlue = ITEMS.register("item_helm_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestCrystalBlue = ITEMS.register("item_chest_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsCrystalBlue = ITEMS.register("item_pants_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsCrystalBlue = ITEMS.register("item_boots_crystal_blue", () -> new ItemArmorAA(ArmorMaterials.PALIS, EquipmentSlotType.FEET)); public static final RegistryObject itemPaxelCrystalBlue = ITEMS.register("item_paxel_crystal_blue", () -> new ItemAllToolAA(ToolMaterials.PALIS)); public static final RegistryObject itemPickaxeCrystalLightBlue = ITEMS.register("item_pickaxe_crystal_light_blue", () -> new ItemPickaxeAA(ToolMaterials.DIAMATINE)); @@ -171,10 +200,10 @@ public final class InitItems { public static final RegistryObject itemShovelCrystalLightBlue = ITEMS.register("item_shovel_crystal_light_blue", () -> new ItemShovelAA(ToolMaterials.DIAMATINE)); public static final RegistryObject itemSwordCrystalLightBlue = ITEMS.register("item_sword_crystal_light_blue", () -> new ItemSwordAA(ToolMaterials.DIAMATINE)); public static final RegistryObject itemHoeCrystalLightBlue = ITEMS.register("item_hoe_crystal_light_blue", () -> new ItemHoeAA(ToolMaterials.DIAMATINE)); - public static final RegistryObject itemHelmCrystalLightBlue = ITEMS.register("item_helm_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 0)); - public static final RegistryObject itemChestCrystalLightBlue = ITEMS.register("item_chest_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 1)); - public static final RegistryObject itemPantsCrystalLightBlue = ITEMS.register("item_pants_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 2)); - public static final RegistryObject itemBootsCrystalLightBlue = ITEMS.register("item_boots_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 3)); + public static final RegistryObject itemHelmCrystalLightBlue = ITEMS.register("item_helm_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestCrystalLightBlue = ITEMS.register("item_chest_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsCrystalLightBlue = ITEMS.register("item_pants_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsCrystalLightBlue = ITEMS.register("item_boots_crystal_light_blue", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.FEET)); public static final RegistryObject itemPaxelCrystalLightBlue = ITEMS.register("item_paxel_crystal_light_blue", () -> new ItemAllToolAA(ToolMaterials.DIAMATINE)); public static final RegistryObject itemPickaxeCrystalBlack = ITEMS.register("item_pickaxe_crystal_black", () -> new ItemPickaxeAA(ToolMaterials.VOID)); @@ -182,10 +211,10 @@ public final class InitItems { public static final RegistryObject itemShovelCrystalBlack = ITEMS.register("item_shovel_crystal_black", () -> new ItemShovelAA(ToolMaterials.VOID)); public static final RegistryObject itemSwordCrystalBlack = ITEMS.register("item_sword_crystal_black", () -> new ItemSwordAA(ToolMaterials.VOID)); public static final RegistryObject itemHoeCrystalBlack = ITEMS.register("item_hoe_crystal_black", () -> new ItemHoeAA(ToolMaterials.VOID)); - public static final RegistryObject itemHelmCrystalBlack = ITEMS.register("item_helm_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, 0)); - public static final RegistryObject itemChestCrystalBlack = ITEMS.register("item_chest_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, 1)); - public static final RegistryObject itemPantsCrystalBlack = ITEMS.register("item_pants_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, 2)); - public static final RegistryObject itemBootsCrystalBlack = ITEMS.register("item_boots_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, 3)); + public static final RegistryObject itemHelmCrystalBlack = ITEMS.register("item_helm_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestCrystalBlack = ITEMS.register("item_chest_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsCrystalBlack = ITEMS.register("item_pants_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsCrystalBlack = ITEMS.register("item_boots_crystal_black", () -> new ItemArmorAA(ArmorMaterials.VOID, EquipmentSlotType.FEET)); public static final RegistryObject itemPaxelCrystalBlack = ITEMS.register("item_paxel_crystal_black", () -> new ItemAllToolAA(ToolMaterials.VOID)); public static final RegistryObject itemPickaxeCrystalGreen = ITEMS.register("item_pickaxe_crystal_green", () -> new ItemPickaxeAA(ToolMaterials.EMERADIC)); @@ -193,10 +222,10 @@ public final class InitItems { public static final RegistryObject itemShovelCrystalGreen = ITEMS.register("item_shovel_crystal_green", () -> new ItemShovelAA(ToolMaterials.EMERADIC)); public static final RegistryObject itemSwordCrystalGreen = ITEMS.register("item_sword_crystal_green", () -> new ItemSwordAA(ToolMaterials.EMERADIC)); public static final RegistryObject itemHoeCrystalGreen = ITEMS.register("item_hoe_crystal_green", () -> new ItemHoeAA(ToolMaterials.EMERADIC)); - public static final RegistryObject itemHelmCrystalGreen = ITEMS.register("item_helm_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 0)); - public static final RegistryObject itemChestCrystalGreen = ITEMS.register("item_chest_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 1)); - public static final RegistryObject itemPantsCrystalGreen = ITEMS.register("item_pants_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 2)); - public static final RegistryObject itemBootsCrystalGreen = ITEMS.register("item_boots_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, 3)); + public static final RegistryObject itemHelmCrystalGreen = ITEMS.register("item_helm_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestCrystalGreen = ITEMS.register("item_chest_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsCrystalGreen = ITEMS.register("item_pants_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsCrystalGreen = ITEMS.register("item_boots_crystal_green", () -> new ItemArmorAA(ArmorMaterials.DIAMATINE, EquipmentSlotType.FEET)); public static final RegistryObject itemPaxelCrystalGreen = ITEMS.register("item_paxel_crystal_green", () -> new ItemAllToolAA(ToolMaterials.EMERADIC)); public static final RegistryObject itemPickaxeCrystalWhite = ITEMS.register("item_pickaxe_crystal_white", () -> new ItemPickaxeAA(ToolMaterials.ENORI)); @@ -204,10 +233,10 @@ public final class InitItems { public static final RegistryObject itemShovelCrystalWhite = ITEMS.register("item_shovel_crystal_white", () -> new ItemShovelAA(ToolMaterials.ENORI)); public static final RegistryObject itemSwordCrystalWhite = ITEMS.register("item_sword_crystal_white", () -> new ItemSwordAA(ToolMaterials.ENORI)); public static final RegistryObject itemHoeCrystalWhite = ITEMS.register("item_hoe_crystal_white", () -> new ItemHoeAA(ToolMaterials.ENORI)); - public static final RegistryObject itemHelmCrystalWhite = ITEMS.register("item_helm_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, 0)); - public static final RegistryObject itemChestCrystalWhite = ITEMS.register("item_chest_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, 1)); - public static final RegistryObject itemPantsCrystalWhite = ITEMS.register("item_pants_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, 2)); - public static final RegistryObject itemBootsCrystalWhite = ITEMS.register("item_boots_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, 3)); + public static final RegistryObject itemHelmCrystalWhite = ITEMS.register("item_helm_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, EquipmentSlotType.HEAD)); + public static final RegistryObject itemChestCrystalWhite = ITEMS.register("item_chest_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, EquipmentSlotType.CHEST)); + public static final RegistryObject itemPantsCrystalWhite = ITEMS.register("item_pants_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, EquipmentSlotType.LEGS)); + public static final RegistryObject itemBootsCrystalWhite = ITEMS.register("item_boots_crystal_white", () -> new ItemArmorAA(ArmorMaterials.ENORI, EquipmentSlotType.FEET)); public static final RegistryObject itemPaxelCrystalWhite = ITEMS.register("item_paxel_crystal_white", () -> new ItemAllToolAA(ToolMaterials.ENORI)); public static Item.Properties defaultProps() { diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBag.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBag.java index bb21b8610..72283d1ca 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBag.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBag.java @@ -35,7 +35,7 @@ public class ItemBag extends ItemBase { public final boolean isVoid; public ItemBag(boolean isVoid) { - super(InitItems.defaultProps().maxStackSize(1)); + super(ActuallyItems.defaultProps().maxStackSize(1)); this.isVoid = isVoid; } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBattery.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBattery.java index 6cf1f59bd..455e49266 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBattery.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBattery.java @@ -31,8 +31,8 @@ import java.util.List; public class ItemBattery extends ItemEnergy { - public ItemBattery(String name, int capacity, int transfer) { - super(capacity, transfer, name); + public ItemBattery(int capacity, int transfer) { + super(capacity, transfer); this.setMaxStackSize(1); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBooklet.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBooklet.java index 3c74c04cd..c6c7b889b 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBooklet.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemBooklet.java @@ -46,7 +46,7 @@ public class ItemBooklet extends ItemBase implements IHudDisplay { public static IBookletPage forcedPage; public ItemBooklet() { - super(InitItems.defaultProps().maxStackSize(1)); + super(ActuallyItems.defaultProps().maxStackSize(1)); } @Override @@ -108,7 +108,7 @@ public class ItemBooklet extends ItemBase implements IHudDisplay { AssetUtil.renderStackToGui(StackUtil.isValid(page.getChapter().getDisplayItemStack()) ? page.getChapter().getDisplayItemStack() - : new ItemStack(InitItems.itemBooklet.get()), resolution.getScaledWidth() / 2 - 10, height + 41, 1F); + : new ItemStack(ActuallyItems.itemBooklet.get()), resolution.getScaledWidth() / 2 - 10, height + 41, 1F); minecraft.fontRenderer.drawStringWithShadow(TextFormatting.YELLOW + "" + TextFormatting.ITALIC + strg1, resolution.getScaledWidth() / 2 - minecraft.fontRenderer.getStringWidth(strg1) / 2, height + 20, StringUtil.DECIMAL_COLOR_WHITE); minecraft.fontRenderer.drawStringWithShadow(TextFormatting.YELLOW + "" + TextFormatting.ITALIC + strg2, resolution.getScaledWidth() / 2 - minecraft.fontRenderer.getStringWidth(strg2) / 2, height + 30, StringUtil.DECIMAL_COLOR_WHITE); minecraft.fontRenderer.drawStringWithShadow(TextFormatting.GOLD + strg3, resolution.getScaledWidth() / 2 - minecraft.fontRenderer.getStringWidth(strg3) / 2, height + 60, StringUtil.DECIMAL_COLOR_WHITE); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffee.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffee.java index 4ba050834..ed363ac31 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffee.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffee.java @@ -14,7 +14,6 @@ import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; import de.ellpeck.actuallyadditions.api.recipe.CoffeeIngredient; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.items.base.ItemFoodBase; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; import de.ellpeck.actuallyadditions.mod.util.ItemUtil; import de.ellpeck.actuallyadditions.mod.util.StringUtil; import net.minecraft.client.util.ITooltipFlag; @@ -39,7 +38,7 @@ import java.util.List; public class ItemCoffee extends ItemFoodBase { - public ItemCoffee(String name) { + public ItemCoffee() { super(8, 5.0F, false, name); this.setMaxDamage(3); this.setAlwaysEdible(); @@ -92,7 +91,7 @@ public class ItemCoffee extends ItemFoodBase { applyPotionEffectsFromStack(stack, player); theStack.setItemDamage(theStack.getItemDamage() + 1); if (theStack.getMaxDamage() - theStack.getItemDamage() < 0) { - return new ItemStack(InitItems.itemMisc, 1, TheMiscItems.CUP.ordinal()); + return new ItemStack(ActuallyItems.itemCoffeeCup.get()); } else { return theStack; } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffeeBean.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffeeBean.java index 90601ec3f..a0bfbf7c6 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffeeBean.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCoffeeBean.java @@ -16,7 +16,7 @@ import net.minecraft.item.ItemStack; public class ItemCoffeeBean extends ItemFoodBase { - public ItemCoffeeBean(String name) { + public ItemCoffeeBean() { super(1, 1F, false, name); this.setMaxDamage(0); } @@ -25,4 +25,4 @@ public class ItemCoffeeBean extends ItemFoodBase { public EnumRarity getRarity(ItemStack stack) { return EnumRarity.RARE; } -} \ No newline at end of file +} diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrafterOnAStick.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrafterOnAStick.java index e79e2d0fa..037a234cf 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrafterOnAStick.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrafterOnAStick.java @@ -23,7 +23,7 @@ import net.minecraft.world.World; public class ItemCrafterOnAStick extends ItemBase { - public ItemCrafterOnAStick(String name) { + public ItemCrafterOnAStick() { super(name); this.setMaxStackSize(1); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java index dfa7bf6a2..bde6ac480 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java @@ -25,7 +25,7 @@ import net.minecraftforge.common.IRarity; public class ItemCrystalShard extends ItemBase implements IColorProvidingItem { - public ItemCrystalShard(String name) { + public ItemCrystalShard() { super(name); this.setHasSubtypes(true); this.setMaxDamage(0); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrill.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrill.java index 74da41a3b..d789fbae6 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrill.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrill.java @@ -53,7 +53,7 @@ public class ItemDrill extends ItemEnergy { public static final int HARVEST_LEVEL = 4; private static final int ENERGY_USE = 100; - public ItemDrill(String name) { + public ItemDrill() { super(250000, 1000, name); this.setMaxDamage(0); this.setHasSubtypes(true); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrillUpgrade.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrillUpgrade.java index eae87ab4a..443c1c38e 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrillUpgrade.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDrillUpgrade.java @@ -23,10 +23,9 @@ public class ItemDrillUpgrade extends ItemBase { public final UpgradeType type; - public ItemDrillUpgrade(UpgradeType type, String unlocName) { - super(unlocName); + public ItemDrillUpgrade(UpgradeType type) { + super(ActuallyItems.defaultProps().maxStackSize(1)); this.type = type; - this.setMaxStackSize(1); } public static int getSlotToPlaceFrom(ItemStack stack) { diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java index e284f30f7..109afa26d 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java @@ -26,7 +26,7 @@ public class ItemDust extends ItemBase implements IColorProvidingItem { public static final TheDusts[] ALL_DUSTS = TheDusts.values(); - public ItemDust(String name) { + public ItemDust() { super(name); this.setHasSubtypes(true); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemEngineerGoggles.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemEngineerGoggles.java index 71c596cec..2106d987a 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemEngineerGoggles.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemEngineerGoggles.java @@ -37,7 +37,7 @@ public class ItemEngineerGoggles extends ItemArmorAA implements IGoggles { private final boolean displayMobs; public ItemEngineerGoggles(boolean displayMobs) { - super(ArmorMaterials.GOGGLES, EquipmentSlotType.HEAD, InitItems.defaultProps().setNoRepair().maxDamage(0)); + super(ArmorMaterials.GOGGLES, EquipmentSlotType.HEAD, ActuallyItems.defaultProps().setNoRepair().maxDamage(0)); this.displayMobs = displayMobs; MinecraftForge.EVENT_BUS.register(this); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFertilizer.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFertilizer.java index 3f643724f..7b9d39b3d 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFertilizer.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFertilizer.java @@ -17,15 +17,15 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.EnumRarity; import net.minecraft.item.ItemDye; import net.minecraft.item.ItemStack; -import net.minecraft.util.EnumActionResult; import net.minecraft.util.Direction; +import net.minecraft.util.EnumActionResult; import net.minecraft.util.Hand; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; public class ItemFertilizer extends ItemBase { - public ItemFertilizer(String name) { + public ItemFertilizer() { super(name); BlockDispenser.DISPENSE_BEHAVIOR_REGISTRY.putObject(this, new DispenserHandlerFertilize()); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFilter.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFilter.java index 0a7ea5a79..00104b64a 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFilter.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFilter.java @@ -10,53 +10,50 @@ package de.ellpeck.actuallyadditions.mod.items; -import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.inventory.ContainerFilter; -import de.ellpeck.actuallyadditions.mod.inventory.GuiHandler; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA; import de.ellpeck.actuallyadditions.mod.util.StackUtil; import net.minecraft.client.util.ITooltipFlag; import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.item.EnumRarity; +import net.minecraft.entity.player.ServerPlayerEntity; +import net.minecraft.inventory.container.SimpleNamedContainerProvider; import net.minecraft.item.ItemStack; import net.minecraft.util.ActionResult; -import net.minecraft.util.EnumActionResult; import net.minecraft.util.Hand; +import net.minecraft.util.text.ITextComponent; +import net.minecraft.util.text.StringTextComponent; import net.minecraft.world.World; +import net.minecraftforge.fml.network.NetworkHooks; +import javax.annotation.Nullable; import java.util.List; public class ItemFilter extends ItemBase { - public ItemFilter(String name) { - super(name); - this.setMaxStackSize(1); - } - - @Override - public EnumRarity getRarity(ItemStack stack) { - return EnumRarity.UNCOMMON; + public ItemFilter() { + super(ActuallyItems.defaultProps().maxStackSize(1)); } @Override public ActionResult onItemRightClick(World world, PlayerEntity player, Hand hand) { if (!world.isRemote && hand == Hand.MAIN_HAND) { - player.openGui(ActuallyAdditions.INSTANCE, GuiHandler.GuiTypes.FILTER.ordinal(), world, (int) player.posX, (int) player.posY, (int) player.posZ); + NetworkHooks.openGui((ServerPlayerEntity) player, new SimpleNamedContainerProvider((windowId, inv, playerEnt) -> new ContainerFilter(windowId, inv), StringTextComponent.EMPTY)); + // player.openGui(ActuallyAdditions.INSTANCE, GuiHandler.GuiTypes.FILTER.ordinal(), world, (int) player.posX, (int) player.posY, (int) player.posZ); } - return new ActionResult<>(EnumActionResult.PASS, player.getHeldItem(hand)); + return ActionResult.resultPass(player.getHeldItem(hand)); } @Override - public void addInformation(ItemStack stack, World playerIn, List tooltip, ITooltipFlag advanced) { - super.addInformation(stack, playerIn, tooltip, advanced); + public void addInformation(ItemStack stack, @Nullable World worldIn, List tooltip, ITooltipFlag flagIn) { + super.addInformation(stack, worldIn, tooltip, flagIn); ItemStackHandlerAA inv = new ItemStackHandlerAA(ContainerFilter.SLOT_AMOUNT); ItemDrill.loadSlotsFromNBT(inv, stack); for (int i = 0; i < inv.getSlots(); i++) { ItemStack slot = inv.getStackInSlot(i); if (StackUtil.isValid(slot)) { - tooltip.add(slot.getItem().getItemStackDisplayName(slot)); + tooltip.add(slot.getItem().getDisplayName(slot)); } } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFoods.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFoods.java index 0cb124533..d85e0ac19 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFoods.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemFoods.java @@ -31,7 +31,7 @@ public class ItemFoods extends ItemFoodBase { public static final TheFoods[] ALL_FOODS = TheFoods.values(); - public ItemFoods(String name) { + public ItemFoods() { super(0, 0.0F, false, name); this.setHasSubtypes(true); this.setMaxDamage(0); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemGrowthRing.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemGrowthRing.java index 5d9ded51a..add32dbc4 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemGrowthRing.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemGrowthRing.java @@ -29,7 +29,7 @@ import java.util.List; public class ItemGrowthRing extends ItemEnergy { - public ItemGrowthRing(String name) { + public ItemGrowthRing() { super(1000000, 2000, name); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemHairyBall.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemHairyBall.java index ca6dd9a8e..02203658c 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemHairyBall.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemHairyBall.java @@ -17,7 +17,6 @@ import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.passive.EntityOcelot; import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.init.SoundEvents; import net.minecraft.item.EnumRarity; import net.minecraft.item.ItemStack; import net.minecraft.util.*; @@ -33,7 +32,7 @@ public class ItemHairyBall extends ItemBase { private final UUID KittyVanCatUUID = UUID.fromString("681d4e20-10ef-40c9-a0a5-ba2f1995ef44"); - public ItemHairyBall(String name) { + public ItemHairyBall() { super(name); MinecraftForge.EVENT_BUS.register(this); @@ -45,7 +44,7 @@ public class ItemHairyBall extends ItemBase { if (ConfigBoolValues.DO_CAT_DROPS.isEnabled() && event.getEntityLiving() != null && event.getEntityLiving().world != null && !event.getEntityLiving().world.isRemote) { if (event.getEntityLiving() instanceof EntityOcelot && ((EntityOcelot) event.getEntityLiving()).isTamed() || event.getEntityLiving() instanceof PlayerEntity && event.getEntityLiving().getUniqueID().equals(this.KittyVanCatUUID)) { if (event.getEntityLiving().world.rand.nextInt(ConfigIntValues.FUR_CHANCE.getValue()) == 0) { - EntityItem item = new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX + 0.5, event.getEntityLiving().posY + 0.5, event.getEntityLiving().posZ + 0.5, new ItemStack(InitItems.itemHairyBall)); + EntityItem item = new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX + 0.5, event.getEntityLiving().posY + 0.5, event.getEntityLiving().posZ + 0.5, new ItemStack(ActuallyItems.itemHairyBall)); event.getEntityLiving().world.spawnEntity(item); } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java index e607e7abc..fa40f9cbd 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java @@ -33,7 +33,7 @@ public class ItemJams extends ItemFoodBase implements IColorProvidingItem { public static final TheJams[] ALL_JAMS = TheJams.values(); - public ItemJams(String name) { + public ItemJams() { super(0, 0.0F, false, name); this.setHasSubtypes(true); this.setMaxDamage(0); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemKnife.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemKnife.java index 110315ef6..64b545cff 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemKnife.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemKnife.java @@ -11,7 +11,6 @@ package de.ellpeck.actuallyadditions.mod.items; import com.google.common.collect.Multimap; - import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import net.minecraft.entity.SharedMonsterAttributes; import net.minecraft.entity.ai.attributes.AttributeModifier; @@ -21,7 +20,7 @@ import net.minecraft.item.ItemStack; public class ItemKnife extends ItemBase { - public ItemKnife(String name) { + public ItemKnife() { super(name); this.setMaxDamage(100); this.setMaxStackSize(1); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLaserWrench.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLaserWrench.java index d103a5260..5f08195bb 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLaserWrench.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLaserWrench.java @@ -20,8 +20,8 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.EnumRarity; import net.minecraft.item.ItemStack; import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.EnumActionResult; import net.minecraft.util.Direction; +import net.minecraft.util.EnumActionResult; import net.minecraft.util.Hand; import net.minecraft.util.math.BlockPos; import net.minecraft.util.text.TextComponentTranslation; @@ -32,7 +32,7 @@ import java.util.List; public class ItemLaserWrench extends ItemBase { - public ItemLaserWrench(String name) { + public ItemLaserWrench() { super(name); this.setMaxStackSize(1); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLeafBlower.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLeafBlower.java index c8889ea88..f5621b8ce 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLeafBlower.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemLeafBlower.java @@ -14,6 +14,8 @@ import de.ellpeck.actuallyadditions.api.misc.IDisplayStandItem; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import net.minecraft.block.Block; import net.minecraft.block.BlockBush; +import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.init.SoundEvents; @@ -37,10 +39,9 @@ public class ItemLeafBlower extends ItemBase implements IDisplayStandItem { private final boolean isAdvanced; - public ItemLeafBlower(boolean isAdvanced, String name) { - super(name); + public ItemLeafBlower(boolean isAdvanced) { + super(ActuallyItems.defaultProps().maxStackSize(1)); this.isAdvanced = isAdvanced; - this.setMaxStackSize(1); } @Override diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMagnetRing.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMagnetRing.java index 46d3ce65a..a54e65331 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMagnetRing.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMagnetRing.java @@ -27,7 +27,7 @@ import java.util.List; public class ItemMagnetRing extends ItemEnergy { - public ItemMagnetRing(String name) { + public ItemMagnetRing() { super(200000, 1000, name); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMisc.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMisc.java index 1cc4aacca..d6637d16e 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMisc.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemMisc.java @@ -10,120 +10,105 @@ package de.ellpeck.actuallyadditions.mod.items; -import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; -import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; -import de.ellpeck.actuallyadditions.mod.util.StringUtil; -import net.minecraft.block.Block; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.entity.item.EntityItem; -import net.minecraft.item.EnumRarity; -import net.minecraft.item.ItemStack; -import net.minecraft.util.NonNullList; -import net.minecraft.util.ResourceLocation; -import net.minecraft.util.math.BlockPos; -import net.minecraftforge.common.IRarity; -import net.minecraftforge.fluids.Fluid; -import net.minecraftforge.fluids.IFluidBlock; public class ItemMisc extends ItemBase { - public static final TheMiscItems[] ALL_MISC_ITEMS = TheMiscItems.values(); - - public ItemMisc(String name) { - super(name); - this.setHasSubtypes(true); - } - - @Override - public int getMetadata(int damage) { - return damage; - } - - @Override - public String getTranslationKey(ItemStack stack) { - return stack.getItemDamage() >= ALL_MISC_ITEMS.length - ? StringUtil.BUGGED_ITEM_NAME - : this.getTranslationKey() + "_" + ALL_MISC_ITEMS[stack.getItemDamage()].name; - } - - @Override - public IRarity getForgeRarity(ItemStack stack) { - return stack.getItemDamage() >= ALL_MISC_ITEMS.length - ? EnumRarity.COMMON - : ALL_MISC_ITEMS[stack.getItemDamage()].rarity; - } - - @Override - @OnlyIn(Dist.CLIENT) - public void getSubItems(CreativeTabs tab, NonNullList list) { - if (this.isInCreativeTab(tab)) { - for (int j = 0; j < ALL_MISC_ITEMS.length; j++) { - if (j != TheMiscItems.YOUTUBE_ICON.ordinal()) { - list.add(new ItemStack(this, 1, j)); - } - } - } - } - - @Override - protected void registerRendering() { - for (int i = 0; i < ALL_MISC_ITEMS.length; i++) { - String name = this.getRegistryName() + "_" + ALL_MISC_ITEMS[i].name; - ActuallyAdditions.PROXY.addRenderRegister(new ItemStack(this, 1, i), new ResourceLocation(name), "inventory"); - } - } - - @Override - public boolean onEntityItemUpdate(EntityItem entity) { - if (!entity.world.isRemote) { - ItemStack stack = entity.getItem(); - if (stack != null) { - boolean isEmpowered = stack.getItemDamage() == TheMiscItems.EMPOWERED_CANOLA_SEED.ordinal(); - if (stack.getItemDamage() == TheMiscItems.CRYSTALLIZED_CANOLA_SEED.ordinal() || isEmpowered) { - BlockPos pos = entity.getPosition(); - BlockState state = entity.world.getBlockState(pos); - Block block = state.getBlock(); - - if (block instanceof IFluidBlock && block.getMetaFromState(state) == 0) { - Fluid fluid = ((IFluidBlock) block).getFluid(); - if (fluid != null && fluid == (isEmpowered - ? InitFluids.fluidCrystalOil - : InitFluids.fluidRefinedCanolaOil)) { - entity.setDead(); - entity.world.setBlockState(pos, (isEmpowered - ? InitFluids.blockEmpoweredOil - : InitFluids.blockCrystalOil).getDefaultState()); - } - } - } - } - } - - return super.onEntityItemUpdate(entity); - } - - @Override - public boolean hasEffect(ItemStack stack) { - return stack.getItemDamage() == TheMiscItems.EMPOWERED_CANOLA_SEED.ordinal(); - } - - @Override - public int getItemBurnTime(ItemStack stack) { - int k = stack.getMetadata(); - - if (k == TheMiscItems.TINY_CHAR.ordinal()) { - return 200; - } - if (k == TheMiscItems.TINY_COAL.ordinal()) { - return 200; - } - if (k == TheMiscItems.BIOCOAL.ordinal()) { - return 800; - } - - return super.getItemBurnTime(stack); - } + // public static final TheMiscItems[] ALL_MISC_ITEMS = TheMiscItems.values(); + // + // public ItemMisc() { + // super(name); + // this.setHasSubtypes(true); + // } + // + // @Override + // public int getMetadata(int damage) { + // return damage; + // } + // + // @Override + // public String getTranslationKey(ItemStack stack) { + // return stack.getItemDamage() >= ALL_MISC_ITEMS.length + // ? StringUtil.BUGGED_ITEM_NAME + // : this.getTranslationKey() + "_" + ALL_MISC_ITEMS[stack.getItemDamage()].name; + // } + // + // @Override + // public IRarity getForgeRarity(ItemStack stack) { + // return stack.getItemDamage() >= ALL_MISC_ITEMS.length + // ? EnumRarity.COMMON + // : ALL_MISC_ITEMS[stack.getItemDamage()].rarity; + // } + // + // @Override + // @OnlyIn(Dist.CLIENT) + // public void getSubItems(CreativeTabs tab, NonNullList list) { + // if (this.isInCreativeTab(tab)) { + // for (int j = 0; j < ALL_MISC_ITEMS.length; j++) { + // if (j != TheMiscItems.YOUTUBE_ICON.ordinal()) { + // list.add(new ItemStack(this, 1, j)); + // } + // } + // } + // } + // + // @Override + // protected void registerRendering() { + // for (int i = 0; i < ALL_MISC_ITEMS.length; i++) { + // String name = this.getRegistryName() + "_" + ALL_MISC_ITEMS[i].name; + // ActuallyAdditions.PROXY.addRenderRegister(new ItemStack(this, 1, i), new ResourceLocation(name), "inventory"); + // } + // } + // + // @Override + // public boolean onEntityItemUpdate(EntityItem entity) { + // if (!entity.world.isRemote) { + // ItemStack stack = entity.getItem(); + // if (stack != null) { + // boolean isEmpowered = stack.getItemDamage() == TheMiscItems.EMPOWERED_CANOLA_SEED.ordinal(); + // if (stack.getItemDamage() == TheMiscItems.CRYSTALLIZED_CANOLA_SEED.ordinal() || isEmpowered) { + // BlockPos pos = entity.getPosition(); + // BlockState state = entity.world.getBlockState(pos); + // Block block = state.getBlock(); + // + // if (block instanceof IFluidBlock && block.getMetaFromState(state) == 0) { + // Fluid fluid = ((IFluidBlock) block).getFluid(); + // if (fluid != null && fluid == (isEmpowered + // ? InitFluids.fluidCrystalOil + // : InitFluids.fluidRefinedCanolaOil)) { + // entity.setDead(); + // entity.world.setBlockState(pos, (isEmpowered + // ? InitFluids.blockEmpoweredOil + // : InitFluids.blockCrystalOil).getDefaultState()); + // } + // } + // } + // } + // } + // + // return super.onEntityItemUpdate(entity); + // } + // + // @Override + // public boolean hasEffect(ItemStack stack) { + // return stack.getItemDamage() == TheMiscItems.EMPOWERED_CANOLA_SEED.ordinal(); + // } + // + // @Override + // public int getItemBurnTime(ItemStack stack) { + // int k = stack.getMetadata(); + // + // if (k == TheMiscItems.TINY_CHAR.ordinal()) { + // return 200; + // } + // if (k == TheMiscItems.TINY_COAL.ordinal()) { + // return 200; + // } + // if (k == TheMiscItems.BIOCOAL.ordinal()) { + // return 800; + // } + // + // return super.getItemBurnTime(stack); + // } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPhantomConnector.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPhantomConnector.java index 0e925236a..6ed53e607 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPhantomConnector.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPhantomConnector.java @@ -21,8 +21,8 @@ import net.minecraft.item.EnumRarity; import net.minecraft.item.ItemStack; import net.minecraft.nbt.CompoundNBT; import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.EnumActionResult; import net.minecraft.util.Direction; +import net.minecraft.util.EnumActionResult; import net.minecraft.util.Hand; import net.minecraft.util.math.BlockPos; import net.minecraft.util.text.TextComponentTranslation; @@ -35,7 +35,7 @@ import java.util.List; public class ItemPhantomConnector extends ItemBase { - public ItemPhantomConnector(String name) { + public ItemPhantomConnector() { super(name); this.setMaxStackSize(1); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPlayerProbe.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPlayerProbe.java index 522d9d66d..e69c48475 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPlayerProbe.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPlayerProbe.java @@ -22,8 +22,8 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.ItemStack; import net.minecraft.nbt.CompoundNBT; import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.EnumActionResult; import net.minecraft.util.Direction; +import net.minecraft.util.EnumActionResult; import net.minecraft.util.Hand; import net.minecraft.util.math.BlockPos; import net.minecraft.util.text.TextComponentTranslation; @@ -35,9 +35,8 @@ import java.util.UUID; public class ItemPlayerProbe extends ItemBase { - public ItemPlayerProbe(String name) { - super(name); - this.setMaxStackSize(1); + public ItemPlayerProbe() { + super(ActuallyItems.defaultProps().maxStackSize(1)); } @Override diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java index 210374371..32f8bebb0 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java @@ -34,6 +34,8 @@ import net.minecraft.util.NonNullList; import net.minecraft.util.math.AxisAlignedBB; import net.minecraft.util.math.MathHelper; import net.minecraft.world.World; +import net.minecraftforge.api.distmarker.Dist; +import net.minecraftforge.api.distmarker.OnlyIn; import javax.annotation.Nullable; import java.util.Collections; @@ -46,10 +48,8 @@ public class ItemPotionRing extends ItemBase implements IColorProvidingItem, IDi public static final int MAX_BLAZE = 800; private final boolean isAdvanced; - public ItemPotionRing(boolean isAdvanced, String name) { - super(name); - this.setHasSubtypes(true); - this.setMaxStackSize(1); + public ItemPotionRing(boolean isAdvanced) { + super(ActuallyItems.defaultProps().maxStackSize(1)); this.isAdvanced = isAdvanced; } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemResonantRice.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemResonantRice.java index f8a8af5b5..01909ea6a 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemResonantRice.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemResonantRice.java @@ -21,7 +21,7 @@ import net.minecraft.world.World; public class ItemResonantRice extends ItemBase { - public ItemResonantRice(String name) { + public ItemResonantRice() { super(name); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSolidifiedExperience.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSolidifiedExperience.java index e6c479829..0de7e8e29 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSolidifiedExperience.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSolidifiedExperience.java @@ -32,7 +32,7 @@ public class ItemSolidifiedExperience extends ItemBase { public static final int SOLID_XP_AMOUNT = 8; - public ItemSolidifiedExperience(String name) { + public ItemSolidifiedExperience() { super(name); MinecraftForge.EVENT_BUS.register(this); @@ -45,7 +45,7 @@ public class ItemSolidifiedExperience extends ItemBase { //Drop Solidified XP if (event.getEntityLiving() instanceof EntityCreature) { if (event.getEntityLiving().world.rand.nextInt(10) <= event.getLootingLevel() * 2) { - event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX, event.getEntityLiving().posY, event.getEntityLiving().posZ, new ItemStack(InitItems.itemSolidifiedExperience, event.getEntityLiving().world.rand.nextInt(2 + event.getLootingLevel()) + 1))); + event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX, event.getEntityLiving().posY, event.getEntityLiving().posZ, new ItemStack(ActuallyItems.itemSolidifiedExperience, event.getEntityLiving().world.rand.nextInt(2 + event.getLootingLevel()) + 1))); } } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSpawnerChanger.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSpawnerChanger.java index a9788a8f2..27e2aa8d1 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSpawnerChanger.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemSpawnerChanger.java @@ -15,6 +15,7 @@ import de.ellpeck.actuallyadditions.mod.config.values.ConfigStringListValues; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import de.ellpeck.actuallyadditions.mod.util.StackUtil; import de.ellpeck.actuallyadditions.mod.util.StringUtil; +import net.minecraft.block.BlockState; import net.minecraft.client.util.ITooltipFlag; import net.minecraft.entity.EntityList; import net.minecraft.entity.EntityLivingBase; @@ -36,7 +37,7 @@ import java.util.List; public class ItemSpawnerChanger extends ItemBase { - public ItemSpawnerChanger(String name) { + public ItemSpawnerChanger() { super(name); this.setMaxStackSize(1); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemTeleStaff.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemTeleStaff.java index 666975fb5..1902931e2 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemTeleStaff.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemTeleStaff.java @@ -27,7 +27,7 @@ import net.minecraft.world.World; public class ItemTeleStaff extends ItemEnergy { - public ItemTeleStaff(String name) { + public ItemTeleStaff() { super(250000, 1000, name); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterBowl.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterBowl.java index 6f18ba1df..897ab32d5 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterBowl.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterBowl.java @@ -15,14 +15,13 @@ import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; import de.ellpeck.actuallyadditions.mod.util.StackUtil; import de.ellpeck.actuallyadditions.mod.util.WorldUtil; import net.minecraft.block.Block; -import net.minecraft.block.BlockLiquid; +import net.minecraft.block.BlockState; +import net.minecraft.block.Blocks; import net.minecraft.block.material.Material; import net.minecraft.entity.Entity; -import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.init.Blocks; -import net.minecraft.init.Items; import net.minecraft.item.ItemStack; +import net.minecraft.item.Items; import net.minecraft.nbt.CompoundNBT; import net.minecraft.util.ActionResult; import net.minecraft.util.Hand; @@ -34,14 +33,12 @@ import net.minecraft.world.World; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.event.ForgeEventFactory; import net.minecraftforge.event.entity.player.PlayerInteractEvent; -import net.minecraftforge.fml.common.eventhandler.SubscribeEvent; +import net.minecraftforge.eventbus.api.SubscribeEvent; public class ItemWaterBowl extends ItemBase { - public ItemWaterBowl(String name) { - super(name); - this.setMaxStackSize(1); - + public ItemWaterBowl() { + super(ActuallyItems.defaultProps().maxStackSize(1)); MinecraftForge.EVENT_BUS.register(this); } @@ -50,25 +47,25 @@ public class ItemWaterBowl extends ItemBase { if (event.getWorld() != null) { if (ConfigBoolValues.WATER_BOWL.isEnabled()) { if (StackUtil.isValid(event.getItemStack()) && event.getItemStack().getItem() == Items.BOWL) { - RayTraceResult trace = WorldUtil.getNearestBlockWithDefaultReachDistance(event.getWorld(), event.getEntityPlayer(), true, false, false); - ActionResult result = ForgeEventFactory.onBucketUse(event.getEntityPlayer(), event.getWorld(), event.getItemStack(), trace); + RayTraceResult trace = WorldUtil.getNearestBlockWithDefaultReachDistance(event.getWorld(), event.getPlayer(), true, false, false); + ActionResult result = ForgeEventFactory.onBucketUse(event.getPlayer(), event.getWorld(), event.getItemStack(), trace); if (result == null && trace != null && trace.getBlockPos() != null) { - if (event.getEntityPlayer().canPlayerEdit(trace.getBlockPos().offset(trace.sideHit), trace.sideHit, event.getItemStack())) { + if (event.getPlayer().canPlayerEdit(trace.getBlockPos().offset(trace.sideHit), trace.sideHit, event.getItemStack())) { BlockState state = event.getWorld().getBlockState(trace.getBlockPos()); Block block = state.getBlock(); if ((block == Blocks.WATER || block == Blocks.FLOWING_WATER) && state.getValue(BlockLiquid.LEVEL) == 0) { - event.getEntityPlayer().playSound(SoundEvents.ITEM_BUCKET_FILL, 1.0F, 1.0F); + event.getPlayer().playSound(SoundEvents.ITEM_BUCKET_FILL, 1.0F, 1.0F); if (!event.getWorld().isRemote) { event.getWorld().setBlockState(trace.getBlockPos(), Blocks.AIR.getDefaultState(), 11); ItemStack reduced = StackUtil.shrink(event.getItemStack(), 1); - ItemStack bowl = new ItemStack(InitItems.itemWaterBowl); + ItemStack bowl = new ItemStack(ActuallyItems.itemWaterBowl); if (!StackUtil.isValid(reduced)) { - event.getEntityPlayer().setHeldItem(event.getHand(), bowl); - } else if (!event.getEntityPlayer().inventory.addItemStackToInventory(bowl.copy())) { - EntityItem entityItem = new EntityItem(event.getWorld(), event.getEntityPlayer().posX, event.getEntityPlayer().posY, event.getEntityPlayer().posZ, bowl.copy()); + event.getPlayer().setHeldItem(event.getHand(), bowl); + } else if (!event.getPlayer().inventory.addItemStackToInventory(bowl.copy())) { + EntityItem entityItem = new EntityItem(event.getWorld(), event.getPlayer().posX, event.getPlayer().posY, event.getPlayer().posZ, bowl.copy()); entityItem.setPickupDelay(0); event.getWorld().spawnEntity(entityItem); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterRemovalRing.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterRemovalRing.java index ed4f1b92b..cea0616e1 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterRemovalRing.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWaterRemovalRing.java @@ -24,7 +24,7 @@ import net.minecraft.world.World; public class ItemWaterRemovalRing extends ItemEnergy { - public ItemWaterRemovalRing(String name) { + public ItemWaterRemovalRing() { super(800000, 1000, name); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWingsOfTheBats.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWingsOfTheBats.java index da30aa08c..8506bad9c 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWingsOfTheBats.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWingsOfTheBats.java @@ -14,9 +14,9 @@ import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues; import de.ellpeck.actuallyadditions.mod.data.PlayerData; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; import de.ellpeck.actuallyadditions.mod.network.PacketHandlerHelper; import de.ellpeck.actuallyadditions.mod.util.StackUtil; +import net.minecraft.block.BlockState; import net.minecraft.entity.Entity; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.passive.EntityBat; @@ -37,7 +37,7 @@ public class ItemWingsOfTheBats extends ItemBase { public static final String THE_BAT_BAT = "the bat bat"; public static final int MAX_FLY_TIME = 800; - public ItemWingsOfTheBats(String name) { + public ItemWingsOfTheBats() { super(name); this.setMaxStackSize(1); @@ -109,7 +109,7 @@ public class ItemWingsOfTheBats extends ItemBase { } if (event.getEntityLiving().world.rand.nextInt(15) <= looting * 2) { - event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX, event.getEntityLiving().posY, event.getEntityLiving().posZ, new ItemStack(InitItems.itemMisc, event.getEntityLiving().world.rand.nextInt(2 + looting) + 1, TheMiscItems.BAT_WING.ordinal()))); + event.getDrops().add(new EntityItem(event.getEntityLiving().world, event.getEntityLiving().posX, event.getEntityLiving().posY, event.getEntityLiving().posZ, new ItemStack(ActuallyItems.itemBatWing.get(), event.getEntityLiving().world.rand.nextInt(2 + looting) + 1))); } } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWorm.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWorm.java index 4239497bf..faf344aa6 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWorm.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemWorm.java @@ -74,7 +74,7 @@ public class ItemWorm extends ItemBase { if (world.isAirBlock(pos.up())) { BlockState state = world.getBlockState(pos); if (state.getBlock() == Blocks.GRASS && world.rand.nextFloat() >= 0.95F) { - ItemStack stack = new ItemStack(InitItems.itemWorm.get(), world.rand.nextInt(2) + 1); + ItemStack stack = new ItemStack(ActuallyItems.itemWorm.get(), world.rand.nextInt(2) + 1); ItemEntity item = new ItemEntity(world, pos.getX() + 0.5, pos.getY() + 1, pos.getZ() + 0.5, stack); world.addEntity(item); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemArmorAA.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemArmorAA.java index 35a13fc76..140f288e5 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemArmorAA.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemArmorAA.java @@ -11,7 +11,7 @@ package de.ellpeck.actuallyadditions.mod.items.base; import de.ellpeck.actuallyadditions.api.misc.IDisableableItem; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.inventory.EquipmentSlotType; import net.minecraft.item.ArmorItem; import net.minecraft.item.IArmorMaterial; @@ -20,7 +20,7 @@ public class ItemArmorAA extends ArmorItem implements IDisableableItem { private final boolean disabled; public ItemArmorAA(IArmorMaterial material, EquipmentSlotType type) { - this(material, type, InitItems.defaultProps()); + this(material, type, ActuallyItems.defaultProps()); } public ItemArmorAA(IArmorMaterial material, EquipmentSlotType type, Properties properties) { diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemBase.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemBase.java index 4e40d5c7a..12a31cdf4 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemBase.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemBase.java @@ -10,7 +10,7 @@ package de.ellpeck.actuallyadditions.mod.items.base; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.item.Item; public class ItemBase extends Item { @@ -19,6 +19,6 @@ public class ItemBase extends Item { } public ItemBase() { - super(InitItems.defaultProps()); + super(ActuallyItems.defaultProps()); } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java index e00a23d64..096a84d52 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/base/ItemEnergy.java @@ -10,7 +10,7 @@ package de.ellpeck.actuallyadditions.mod.items.base; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.proxy.ClientProxy; import de.ellpeck.actuallyadditions.mod.tile.CustomEnergyStorage; import de.ellpeck.actuallyadditions.mod.util.AssetUtil; @@ -44,7 +44,7 @@ public abstract class ItemEnergy extends ItemBase { private final int transfer; public ItemEnergy(int maxPower, int transfer) { - super(InitItems.defaultProps().maxStackSize(1)); + super(ActuallyItems.defaultProps().maxStackSize(1)); this.maxPower = maxPower; this.transfer = transfer; } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/lens/ItemLens.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/lens/ItemLens.java index 58d51aee8..5a7b63f54 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/lens/ItemLens.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/lens/ItemLens.java @@ -12,7 +12,7 @@ package de.ellpeck.actuallyadditions.mod.items.lens; import de.ellpeck.actuallyadditions.api.lens.ILensItem; import de.ellpeck.actuallyadditions.api.lens.Lens; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; public class ItemLens extends ItemBase implements ILensItem { @@ -20,7 +20,7 @@ public class ItemLens extends ItemBase implements ILensItem { private final Lens type; public ItemLens(Lens type) { - super(InitItems.defaultProps().maxStackSize(1)); + super(ActuallyItems.defaultProps().maxStackSize(1)); this.type = type; } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java index c9c877881..7d9465470 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java @@ -33,7 +33,7 @@ public enum TheCrystals implements IStringSerializable { } @Override - public String getName() { + public String getString() { return this.name; } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheFoods.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheFoods.java index ef8729f07..fa15a1299 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheFoods.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheFoods.java @@ -10,7 +10,7 @@ package de.ellpeck.actuallyadditions.mod.items.metalists; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.util.StackUtil; import net.minecraft.item.ItemStack; import net.minecraft.item.Items; @@ -62,7 +62,7 @@ public enum TheFoods { SPAGHETTI.returnItem = new ItemStack(Items.BOWL); PUMPKIN_STEW.returnItem = new ItemStack(Items.BOWL); CARROT_JUICE.returnItem = new ItemStack(Items.GLASS_BOTTLE); - FRENCH_FRIES.returnItem = new ItemStack(InitItems.itemPaperCone.get()); - FISH_N_CHIPS.returnItem = new ItemStack(InitItems.itemPaperCone.get()); + FRENCH_FRIES.returnItem = new ItemStack(ActuallyItems.itemPaperCone.get()); + FISH_N_CHIPS.returnItem = new ItemStack(ActuallyItems.itemPaperCone.get()); } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheMiscItems.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheMiscItems.java deleted file mode 100644 index cb05601c9..000000000 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheMiscItems.java +++ /dev/null @@ -1,48 +0,0 @@ -/* - * This file ("TheMiscItems.java") is part of the Actually Additions mod for Minecraft. - * It is created and owned by Ellpeck and distributed - * under the Actually Additions License to be found at - * http://ellpeck.de/actaddlicense - * View the source code at https://github.com/Ellpeck/ActuallyAdditions - * - * © 2015-2017 Ellpeck - */ - -package de.ellpeck.actuallyadditions.mod.items.metalists; - -@Deprecated -public enum TheMiscItems { - - PAPER_CONE("paper_cone"), - MASHED_FOOD("mashed_food"), - KNIFE_BLADE("knife_blade"), - KNIFE_HANDLE("knife_handle"), - DOUGH("dough"), - QUARTZ("black_quartz"), - RING("ring"), - COIL("coil"), - COIL_ADVANCED("coil_advanced"), - RICE_DOUGH("rice_dough"), - TINY_COAL("tiny_coal"), - TINY_CHAR("tiny_charcoal"), - RICE_SLIME("rice_slime"), - CANOLA("canola"), - CUP("cup"), - BAT_WING("bat_wing"), - DRILL_CORE("drill_core"), - BLACK_DYE("black_dye"), - LENS("lens"), - ENDER_STAR("ender_star"), - SPAWNER_SHARD("spawner_shard"), - BIOMASS("biomass"), - BIOCOAL("biocoal"), - CRYSTALLIZED_CANOLA_SEED("crystallized_canola_seed"), - EMPOWERED_CANOLA_SEED("empowered_canola_seed"), - YOUTUBE_ICON("youtube_icon"); - - public final String name; - - TheMiscItems(String name) { - this.name = name; - } -} diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/jei/JEIActuallyAdditionsPlugin.java b/src/main/java/de/ellpeck/actuallyadditions/mod/jei/JEIActuallyAdditionsPlugin.java index d1a21ba7b..b17775f22 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/jei/JEIActuallyAdditionsPlugin.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/jei/JEIActuallyAdditionsPlugin.java @@ -20,8 +20,7 @@ import de.ellpeck.actuallyadditions.mod.blocks.ActuallyBlocks; import de.ellpeck.actuallyadditions.mod.inventory.gui.GuiCoffeeMachine; import de.ellpeck.actuallyadditions.mod.inventory.gui.GuiFurnaceDouble; import de.ellpeck.actuallyadditions.mod.inventory.gui.GuiGrinder; -import de.ellpeck.actuallyadditions.mod.items.InitItems; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.jei.booklet.BookletRecipeCategory; import de.ellpeck.actuallyadditions.mod.jei.booklet.BookletRecipeWrapper; import de.ellpeck.actuallyadditions.mod.jei.coffee.CoffeeMachineRecipeCategory; @@ -78,16 +77,16 @@ public class JEIActuallyAdditionsPlugin implements IModPlugin { blacklist.addIngredientToBlacklist(new ItemStack(ActuallyBlocks.blockCoffee.get())); blacklist.addIngredientToBlacklist(new ItemStack(ActuallyBlocks.blockWildPlant.get(), 1, Util.WILDCARD)); blacklist.addIngredientToBlacklist(new ItemStack(ActuallyBlocks.blockColoredLampOn.get(), 1, Util.WILDCARD)); - blacklist.addIngredientToBlacklist(new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.YOUTUBE_ICON.ordinal())); + // blacklist.addIngredientToBlacklist(new ItemStack(InitItems.itemMisc.get(), 1, TheMiscItems.YOUTUBE_ICON.ordinal())); - registry.addRecipeCatalyst(new ItemStack(InitItems.itemCrafterOnAStick.get()), VanillaRecipeCategoryUid.CRAFTING); + registry.addRecipeCatalyst(new ItemStack(ActuallyItems.itemCrafterOnAStick.get()), VanillaRecipeCategoryUid.CRAFTING); registry.addRecipeCatalyst(new ItemStack(ActuallyBlocks.blockFurnaceDouble.get()), VanillaRecipeCategoryUid.SMELTING); registry.addRecipeCatalyst(new ItemStack(ActuallyBlocks.blockGrinder.get()), CrusherRecipeCategory.NAME); registry.addRecipeCatalyst(new ItemStack(ActuallyBlocks.blockGrinderDouble.get()), CrusherRecipeCategory.NAME); registry.addRecipeCatalyst(new ItemStack(ActuallyBlocks.blockCoffeeMachine.get()), CoffeeMachineRecipeCategory.NAME); registry.addRecipeCatalyst(new ItemStack(ActuallyBlocks.blockAtomicReconstructor.get()), ReconstructorRecipeCategory.NAME); registry.addRecipeCatalyst(new ItemStack(ActuallyBlocks.blockEmpowerer.get()), EmpowererRecipeCategory.NAME); - registry.addRecipeCatalyst(new ItemStack(InitItems.itemBooklet.get()), BookletRecipeCategory.NAME); + registry.addRecipeCatalyst(new ItemStack(ActuallyItems.itemBooklet.get()), BookletRecipeCategory.NAME); // registry.addRecipeCatalyst(new ItemStack(InitBlocks.blockCompost.get()), CompostRecipeCategory.NAME); } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/jei/coffee/CoffeeMachineRecipeWrapper.java b/src/main/java/de/ellpeck/actuallyadditions/mod/jei/coffee/CoffeeMachineRecipeWrapper.java index b65643158..a8ff548cc 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/jei/coffee/CoffeeMachineRecipeWrapper.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/jei/coffee/CoffeeMachineRecipeWrapper.java @@ -17,8 +17,7 @@ import de.ellpeck.actuallyadditions.api.recipe.CoffeeIngredient; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.blocks.ActuallyBlocks; import de.ellpeck.actuallyadditions.mod.booklet.misc.BookletUtils; -import de.ellpeck.actuallyadditions.mod.items.InitItems; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton; import de.ellpeck.actuallyadditions.mod.tile.TileEntityCoffeeMachine; import de.ellpeck.actuallyadditions.mod.util.StringUtil; @@ -34,12 +33,12 @@ public class CoffeeMachineRecipeWrapper extends RecipeWrapperWithButton { public final CoffeeIngredient ingredient; public final ItemStack theOutput; - public final ItemStack cup = new ItemStack(InitItems.itemMisc, 1, TheMiscItems.CUP.ordinal()); + public final ItemStack cup = new ItemStack(ActuallyItems.itemCoffeeCup.get()); public CoffeeMachineRecipeWrapper(CoffeeIngredient ingredient) { this.ingredient = ingredient; - this.theOutput = new ItemStack(InitItems.itemCoffee); + this.theOutput = new ItemStack(ActuallyItems.itemCoffee); ActuallyAdditionsAPI.methodHandler.addEffectToStack(this.theOutput, this.ingredient); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/material/ArmorMaterials.java b/src/main/java/de/ellpeck/actuallyadditions/mod/material/ArmorMaterials.java index 86c8bc53c..1227080e7 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/material/ArmorMaterials.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/material/ArmorMaterials.java @@ -1,7 +1,7 @@ package de.ellpeck.actuallyadditions.mod.material; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.inventory.EquipmentSlotType; import net.minecraft.item.IArmorMaterial; import net.minecraft.item.crafting.Ingredient; @@ -22,15 +22,15 @@ public enum ArmorMaterials implements IArmorMaterial { // EMERALD("emerald_armor_material", 30, new int[] { 5, 8, 9, 4 }, 15, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 2, 0f, () -> Ingredient.fromItems(Items.EMERALD)), // OBSIDIAN("obsidian_armor_material", 28, new int[] { 1, 3, 4, 3 }, 10, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 1, 0f, () -> Ingredient.fromItems(Items.OBSIDIAN)), - QUARTZ("quartz_armor_material", 15, new int[]{3, 5, 6, 3}, 8, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 1, 0f, () -> Ingredient.fromItems(InitItems.BLACK_QUARTZ.get())), - RESTONIA("restonia_armor_material", 18, new int[]{3, 6, 7, 3}, 9, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(InitItems.RESTONIA_CRYSTAL.get())), - PALIS("palis_armor_material", 10, new int[]{3, 6, 7, 3}, 10, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(InitItems.PALIS_CRYSTAL.get())), - DIAMATINE("diamatine_armor_material", 36, new int[]{4, 7, 8, 4}, 12, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 3, 0f, () -> Ingredient.fromItems(InitItems.DIAMATINE_CRYSTAL.get())), - VOID("void_armor_material", 23, new int[]{1, 3, 4, 1}, 13, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(InitItems.VOID_CRYSTAL.get())), - EMERADIC("emeradic_armor_material", 32, new int[]{6, 9, 9, 4}, 18, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 3, 0f, () -> Ingredient.fromItems(InitItems.EMERADIC_CRYSTAL.get())), - ENORI("enori_armor_material", 24, new int[]{3, 6, 6, 3}, 11, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(InitItems.ENORI_CRYSTAL.get())), + QUARTZ("quartz_armor_material", 15, new int[]{3, 5, 6, 3}, 8, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 1, 0f, () -> Ingredient.fromItems(ActuallyItems.BLACK_QUARTZ.get())), + RESTONIA("restonia_armor_material", 18, new int[]{3, 6, 7, 3}, 9, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(ActuallyItems.RESTONIA_CRYSTAL.get())), + PALIS("palis_armor_material", 10, new int[]{3, 6, 7, 3}, 10, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(ActuallyItems.PALIS_CRYSTAL.get())), + DIAMATINE("diamatine_armor_material", 36, new int[]{4, 7, 8, 4}, 12, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 3, 0f, () -> Ingredient.fromItems(ActuallyItems.DIAMATINE_CRYSTAL.get())), + VOID("void_armor_material", 23, new int[]{1, 3, 4, 1}, 13, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(ActuallyItems.VOID_CRYSTAL.get())), + EMERADIC("emeradic_armor_material", 32, new int[]{6, 9, 9, 4}, 18, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 3, 0f, () -> Ingredient.fromItems(ActuallyItems.EMERADIC_CRYSTAL.get())), + ENORI("enori_armor_material", 24, new int[]{3, 6, 6, 3}, 11, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.fromItems(ActuallyItems.ENORI_CRYSTAL.get())), GOGGLES("goggles_armor_material", 0, new int[]{0, 0, 0, 0}, 0, SoundEvents.ITEM_ARMOR_EQUIP_GENERIC, 0, 0f, () -> Ingredient.EMPTY); - + // HMMM Tasty stolen code from MC, how lovely. private static final int[] MAX_DAMAGE_ARRAY = new int[]{13, 15, 16, 11}; private final String name; diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/material/ToolMaterials.java b/src/main/java/de/ellpeck/actuallyadditions/mod/material/ToolMaterials.java index 84bfa2e3b..835a94ae5 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/material/ToolMaterials.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/material/ToolMaterials.java @@ -1,6 +1,6 @@ package de.ellpeck.actuallyadditions.mod.material; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.item.IItemTier; import net.minecraft.item.crafting.Ingredient; import net.minecraft.util.LazyValue; @@ -13,13 +13,13 @@ import java.util.function.Supplier; * todo: review to ensure all values act as intended */ public enum ToolMaterials implements IItemTier { - QUARTZ(2, 280, 6.5f, 2.0f, 10, () -> Ingredient.fromItems(InitItems.BLACK_QUARTZ.get())), - RESTONIA(2, 300, 7.0f, 2.25f, 12, () -> Ingredient.fromItems(InitItems.RESTONIA_CRYSTAL.get())), - PALIS(2, 300, 7.0f, 2.25f, 12, () -> Ingredient.fromItems(InitItems.PALIS_CRYSTAL.get())), - DIAMATINE(3, 1600, 9.0f, 4.0f, 14, () -> Ingredient.fromItems(InitItems.DIAMATINE_CRYSTAL.get())), - VOID(2, 280, 6.0f, 2.0f, 8, () -> Ingredient.fromItems(InitItems.VOID_CRYSTAL.get())), - EMERADIC(4, 2200, 9.5f, 5.55f, 18, () -> Ingredient.fromItems(InitItems.EMERADIC_CRYSTAL.get())), - ENORI(2, 280, 6.25f, 6.25f, 15, () -> Ingredient.fromItems(InitItems.ENORI_CRYSTAL.get())); + QUARTZ(2, 280, 6.5f, 2.0f, 10, () -> Ingredient.fromItems(ActuallyItems.BLACK_QUARTZ.get())), + RESTONIA(2, 300, 7.0f, 2.25f, 12, () -> Ingredient.fromItems(ActuallyItems.RESTONIA_CRYSTAL.get())), + PALIS(2, 300, 7.0f, 2.25f, 12, () -> Ingredient.fromItems(ActuallyItems.PALIS_CRYSTAL.get())), + DIAMATINE(3, 1600, 9.0f, 4.0f, 14, () -> Ingredient.fromItems(ActuallyItems.DIAMATINE_CRYSTAL.get())), + VOID(2, 280, 6.0f, 2.0f, 8, () -> Ingredient.fromItems(ActuallyItems.VOID_CRYSTAL.get())), + EMERADIC(4, 2200, 9.5f, 5.55f, 18, () -> Ingredient.fromItems(ActuallyItems.EMERADIC_CRYSTAL.get())), + ENORI(2, 280, 6.25f, 6.25f, 15, () -> Ingredient.fromItems(ActuallyItems.ENORI_CRYSTAL.get())); private final int harvestLevel; private final int maxUses; diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/misc/BannerHelper.java b/src/main/java/de/ellpeck/actuallyadditions/mod/misc/BannerHelper.java index 9fa680368..76272f012 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/misc/BannerHelper.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/misc/BannerHelper.java @@ -11,7 +11,7 @@ package de.ellpeck.actuallyadditions.mod.misc; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.item.ItemStack; import net.minecraft.tileentity.BannerPattern; import net.minecraftforge.common.util.EnumHelper; @@ -21,10 +21,10 @@ import java.util.Locale; public final class BannerHelper { public static void init() { - addCraftingPattern("drill", new ItemStack(InitItems.itemDrill.get(), 1, 3)); - addCraftingPattern("leaf_blo", new ItemStack(InitItems.itemLeafBlower.get())); - addCraftingPattern("phan_con", new ItemStack(InitItems.itemPhantomConnector.get())); - addCraftingPattern("book", new ItemStack(InitItems.itemBooklet.get())); + addCraftingPattern("drill", new ItemStack(ActuallyItems.itemDrill.get(), 1, 3)); + addCraftingPattern("leaf_blo", new ItemStack(ActuallyItems.itemLeafBlower.get())); + addCraftingPattern("phan_con", new ItemStack(ActuallyItems.itemPhantomConnector.get())); + addCraftingPattern("book", new ItemStack(ActuallyItems.itemBooklet.get())); } /** diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/ore/InitOreDict.java b/src/main/java/de/ellpeck/actuallyadditions/mod/ore/InitOreDict.java index e342a299d..6b4e15b85 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/ore/InitOreDict.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/ore/InitOreDict.java @@ -11,12 +11,6 @@ package de.ellpeck.actuallyadditions.mod.ore; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; -import de.ellpeck.actuallyadditions.mod.blocks.ActuallyBlocks; -import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheMiscBlocks; -import de.ellpeck.actuallyadditions.mod.items.InitItems; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheDusts; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheFoods; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; import net.minecraft.block.Block; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; @@ -33,34 +27,34 @@ public final class InitOreDict { addOre(Items.COAL, "coal"); //Ores for Pulverizers etc. - addOre(InitItems.itemDust.get(), TheDusts.IRON.ordinal(), "dustIron"); - addOre(InitItems.itemDust.get(), TheDusts.GOLD.ordinal(), "dustGold"); - addOre(InitItems.itemDust.get(), TheDusts.DIAMOND.ordinal(), "dustDiamond"); - addOre(InitItems.itemDust.get(), TheDusts.EMERALD.ordinal(), "dustEmerald"); - addOre(InitItems.itemDust.get(), TheDusts.LAPIS.ordinal(), "dustLapis"); - addOre(InitItems.itemDust.get(), TheDusts.QUARTZ.ordinal(), "dustQuartz"); - addOre(InitItems.itemDust.get(), TheDusts.QUARTZ.ordinal(), "dustNetherQuartz"); - addOre(InitItems.itemDust.get(), TheDusts.COAL.ordinal(), "dustCoal"); - addOre(InitItems.itemDust.get(), TheDusts.QUARTZ_BLACK.ordinal(), "dustQuartzBlack"); - addOre(ActuallyBlocks.blockMisc.get(), TheMiscBlocks.ORE_QUARTZ.ordinal(), "oreQuartzBlack"); - addOre(InitItems.itemMisc.get(), TheMiscItems.QUARTZ.ordinal(), "gemQuartzBlack"); - - //For Thermal Expansion Machine that "grows crops" - addOre(InitItems.itemCanolaSeed.get(), "seedCanola"); - addOre(InitItems.itemMisc.get(), TheMiscItems.CANOLA.ordinal(), "cropCanola"); - addOre(InitItems.itemRiceSeed.get(), "seedRice"); - addOre(InitItems.itemFoods.get(), TheFoods.RICE.ordinal(), "cropRice"); - addOre(InitItems.itemFlaxSeed.get(), "seedFlax"); - addOre(Items.STRING, "cropFlax"); - addOre(InitItems.itemCoffeeSeed.get(), "seedCoffee"); - addOre(InitItems.itemCoffeeBean.get(), "cropCoffee"); - - //For Crafting - addOre(InitItems.itemMisc.get(), TheMiscItems.RICE_SLIME.ordinal(), "slimeball"); - addOre(ActuallyBlocks.blockMisc.get(), TheMiscBlocks.CHARCOAL_BLOCK.ordinal(), "blockCharcoal"); - addOre(ActuallyBlocks.blockMisc.get(), TheMiscBlocks.QUARTZ.ordinal(), "blockQuartzBlack"); - addOre(InitItems.itemMisc.get(), TheMiscItems.BLACK_DYE.ordinal(), "dyeBlack"); - addOre(InitItems.itemMisc.get(), TheMiscItems.BLACK_DYE.ordinal(), "dye"); + // addOre(InitItems.itemDust.get(), TheDusts.IRON.ordinal(), "dustIron"); + // addOre(InitItems.itemDust.get(), TheDusts.GOLD.ordinal(), "dustGold"); + // addOre(InitItems.itemDust.get(), TheDusts.DIAMOND.ordinal(), "dustDiamond"); + // addOre(InitItems.itemDust.get(), TheDusts.EMERALD.ordinal(), "dustEmerald"); + // addOre(InitItems.itemDust.get(), TheDusts.LAPIS.ordinal(), "dustLapis"); + // addOre(InitItems.itemDust.get(), TheDusts.QUARTZ.ordinal(), "dustQuartz"); + // addOre(InitItems.itemDust.get(), TheDusts.QUARTZ.ordinal(), "dustNetherQuartz"); + // addOre(InitItems.itemDust.get(), TheDusts.COAL.ordinal(), "dustCoal"); + // addOre(InitItems.itemDust.get(), TheDusts.QUARTZ_BLACK.ordinal(), "dustQuartzBlack"); + // addOre(ActuallyBlocks.blockMisc.get(), TheMiscBlocks.ORE_QUARTZ.ordinal(), "oreQuartzBlack"); + // addOre(InitItems.itemMisc.get(), TheMiscItems.QUARTZ.ordinal(), "gemQuartzBlack"); + // + // //For Thermal Expansion Machine that "grows crops" + // addOre(InitItems.itemCanolaSeed.get(), "seedCanola"); + // addOre(InitItems.itemMisc.get(), TheMiscItems.CANOLA.ordinal(), "cropCanola"); + // addOre(InitItems.itemRiceSeed.get(), "seedRice"); + // addOre(InitItems.itemFoods.get(), TheFoods.RICE.ordinal(), "cropRice"); + // addOre(InitItems.itemFlaxSeed.get(), "seedFlax"); + // addOre(Items.STRING, "cropFlax"); + // addOre(InitItems.itemCoffeeSeed.get(), "seedCoffee"); + // addOre(InitItems.itemCoffeeBean.get(), "cropCoffee"); + // + // //For Crafting + // addOre(InitItems.itemMisc.get(), TheMiscItems.RICE_SLIME.ordinal(), "slimeball"); + // addOre(ActuallyBlocks.blockMisc.get(), TheMiscBlocks.CHARCOAL_BLOCK.ordinal(), "blockCharcoal"); + // addOre(ActuallyBlocks.blockMisc.get(), TheMiscBlocks.QUARTZ.ordinal(), "blockQuartzBlack"); + // addOre(InitItems.itemMisc.get(), TheMiscItems.BLACK_DYE.ordinal(), "dyeBlack"); + // addOre(InitItems.itemMisc.get(), TheMiscItems.BLACK_DYE.ordinal(), "dye"); } private static void addOre(Item item, int meta, String name) { diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/recipe/HairyBallHandler.java b/src/main/java/de/ellpeck/actuallyadditions/mod/recipe/HairyBallHandler.java index 5677d581c..7b3d23073 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/recipe/HairyBallHandler.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/recipe/HairyBallHandler.java @@ -11,7 +11,7 @@ package de.ellpeck.actuallyadditions.mod.recipe; import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import net.minecraft.init.Blocks; import net.minecraft.init.Items; import net.minecraft.item.ItemStack; @@ -42,7 +42,7 @@ public final class HairyBallHandler { ActuallyAdditionsAPI.addBallOfFurReturnItem(new ItemStack(Blocks.SAND), 50); ActuallyAdditionsAPI.addBallOfFurReturnItem(new ItemStack(Blocks.VINE), 30); ActuallyAdditionsAPI.addBallOfFurReturnItem(new ItemStack(Blocks.WEB), 4); - ActuallyAdditionsAPI.addBallOfFurReturnItem(new ItemStack(InitItems.itemSolidifiedExperience), 20); + ActuallyAdditionsAPI.addBallOfFurReturnItem(new ItemStack(ActuallyItems.itemSolidifiedExperience), 20); } } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/FilterSettings.java b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/FilterSettings.java index a5754dd41..40d49e52c 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/FilterSettings.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/FilterSettings.java @@ -18,7 +18,6 @@ import de.ellpeck.actuallyadditions.mod.util.StackUtil; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; import net.minecraft.nbt.CompoundNBT; -import net.minecraftforge.oredict.OreDictionary; import org.apache.commons.lang3.ArrayUtils; public class FilterSettings { diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCanolaPress.java b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCanolaPress.java index 03f25a6b1..a130399be 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCanolaPress.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCanolaPress.java @@ -12,7 +12,7 @@ package de.ellpeck.actuallyadditions.mod.tile; import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.inventory.ContainerCanolaPress; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA.IAcceptor; import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA.IRemover; import de.ellpeck.actuallyadditions.mod.util.StackUtil; @@ -132,7 +132,7 @@ public class TileEntityCanolaPress extends TileEntityInventoryBase implements IN } public static boolean isCanola(ItemStack stack) { - return stack.getItem() == InitItems.itemCanola.get(); + return stack.getItem() == ActuallyItems.itemCanola.get(); } @Override diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCoffeeMachine.java b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCoffeeMachine.java index 672d67fd9..0cfc5b670 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCoffeeMachine.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityCoffeeMachine.java @@ -13,9 +13,8 @@ package de.ellpeck.actuallyadditions.mod.tile; import de.ellpeck.actuallyadditions.api.ActuallyTags; import de.ellpeck.actuallyadditions.api.recipe.CoffeeIngredient; import de.ellpeck.actuallyadditions.mod.inventory.ContainerCoffeeMachine; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemCoffee; -import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems; import de.ellpeck.actuallyadditions.mod.misc.SoundHandler; import de.ellpeck.actuallyadditions.mod.network.gui.IButtonReactor; import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA.IAcceptor; @@ -152,7 +151,7 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements @Override public IAcceptor getAcceptor() { - return (slot, stack, automation) -> !automation || slot >= 3 && ItemCoffee.getIngredientFromStack(stack) != null || slot == SLOT_COFFEE_BEANS && ActuallyTags.Items.COFFEE_BEANS.contains(stack.getItem()) || slot == SLOT_INPUT && stack.getItem() == InitItems.itemCoffeeCup; + return (slot, stack, automation) -> !automation || slot >= 3 && ItemCoffee.getIngredientFromStack(stack) != null || slot == SLOT_COFFEE_BEANS && ActuallyTags.Items.COFFEE_BEANS.contains(stack.getItem()) || slot == SLOT_INPUT && stack.getItem() == ActuallyItems.itemCoffeeCup.get(); } @Override @@ -176,7 +175,7 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements } ItemStack input = this.inv.getStackInSlot(SLOT_INPUT); - if (StackUtil.isValid(input) && input.getItem() == InitItems.itemMisc && input.getDamage() == TheMiscItems.CUP.ordinal() && !StackUtil.isValid(this.inv.getStackInSlot(SLOT_OUTPUT)) && this.coffeeCacheAmount >= CACHE_USE && this.tank.getFluid().getFluid() == Fluids.WATER && this.tank.getFluidAmount() >= WATER_USE) { + if (StackUtil.isValid(input) && input.getItem() == ActuallyItems.itemCoffeeCup.get() && !StackUtil.isValid(this.inv.getStackInSlot(SLOT_OUTPUT)) && this.coffeeCacheAmount >= CACHE_USE && this.tank.getFluid().getFluid() == Fluids.WATER && this.tank.getFluidAmount() >= WATER_USE) { if (this.storage.getEnergyStored() >= ENERGY_USED) { if (this.brewTime % 30 == 0) { this.world.playSound(null, this.getPos().getX(), this.getPos().getY(), this.getPos().getZ(), SoundHandler.coffeeMachine, SoundCategory.BLOCKS, 0.1F, 1.0F); @@ -186,7 +185,7 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements this.storage.extractEnergyInternal(ENERGY_USED, false); if (this.brewTime >= TIME_USED) { this.brewTime = 0; - ItemStack output = new ItemStack(InitItems.itemCoffee); + ItemStack output = new ItemStack(ActuallyItems.itemCoffee.get()); for (int i = 3; i < this.inv.getSlots(); i++) { if (StackUtil.isValid(this.inv.getStackInSlot(i))) { CoffeeIngredient ingredient = ItemCoffee.getIngredientFromStack(this.inv.getStackInSlot(i)); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityLaserRelay.java b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityLaserRelay.java index d50e388b4..c93346265 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityLaserRelay.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityLaserRelay.java @@ -14,7 +14,7 @@ import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI; import de.ellpeck.actuallyadditions.api.laser.IConnectionPair; import de.ellpeck.actuallyadditions.api.laser.LaserType; import de.ellpeck.actuallyadditions.api.laser.Network; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.misc.apiimpl.ConnectionPair; import de.ellpeck.actuallyadditions.mod.util.StackUtil; import io.netty.util.internal.ConcurrentSet; @@ -168,7 +168,7 @@ public abstract class TileEntityLaserRelay extends TileEntityInventoryBase { public int getMaxRange() { ItemStack upgrade = this.inv.getStackInSlot(0); - if (StackUtil.isValid(upgrade) && upgrade.getItem() == InitItems.itemLaserUpgradeRange.get()) { + if (StackUtil.isValid(upgrade) && upgrade.getItem() == ActuallyItems.itemLaserUpgradeRange.get()) { return MAX_DISTANCE_RANGED; } else { return MAX_DISTANCE; diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityXPSolidifier.java b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityXPSolidifier.java index 5ca5acee7..91553601d 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityXPSolidifier.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/tile/TileEntityXPSolidifier.java @@ -12,7 +12,7 @@ package de.ellpeck.actuallyadditions.mod.tile; import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; import de.ellpeck.actuallyadditions.mod.inventory.ContainerXPSolidifier; -import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.ActuallyItems; import de.ellpeck.actuallyadditions.mod.items.ItemSolidifiedExperience; import de.ellpeck.actuallyadditions.mod.network.gui.IButtonReactor; import de.ellpeck.actuallyadditions.mod.util.ItemStackHandlerAA.IAcceptor; @@ -132,7 +132,7 @@ public class TileEntityXPSolidifier extends TileEntityInventoryBase implements I ItemStack stack = this.inv.getStackInSlot(0); if (stack.isEmpty()) { int toSet = Math.min(this.amount, 64); - this.inv.setStackInSlot(0, new ItemStack(InitItems.itemSolidifiedExperience.get(), toSet)); + this.inv.setStackInSlot(0, new ItemStack(ActuallyItems.itemSolidifiedExperience.get(), toSet)); this.amount -= toSet; this.markDirty(); } else if (stack.getCount() < 64) { @@ -182,7 +182,7 @@ public class TileEntityXPSolidifier extends TileEntityInventoryBase implements I @Override public IAcceptor getAcceptor() { - return (slot, stack, automation) -> slot == 1 && stack.getItem() == InitItems.itemSolidifiedExperience.get(); + return (slot, stack, automation) -> slot == 1 && stack.getItem() == ActuallyItems.itemSolidifiedExperience.get(); } @Override