diff --git a/CHANGELOG.md b/CHANGELOG.md index d8a2ef53d..dc78ea5a3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -34,6 +34,8 @@ * Tridents can now be crafted * The Industrial Miner can now mine up to the minimum world limit (previously only until y=0) * (API) Added SlimefunItemSpawnEvent and ItemSpawnReason +* Added "Amethyst Block -> 4 Amethyst Shards" recipe to the Grind Stone +* Added an option to the IndustrialMiner to configure if they can mine deepslate ores #### Changes diff --git a/pom.xml b/pom.xml index 629a97cb5..12799d20f 100644 --- a/pom.xml +++ b/pom.xml @@ -355,7 +355,7 @@ com.github.seeseemelk MockBukkit-v1.16 - 1.3.2 + 1.5.0 test @@ -442,7 +442,7 @@ me.clip placeholderapi - 2.10.9 + 2.10.10 provided diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/core/services/github/ContributionsConnector.java b/src/main/java/io/github/thebusybiscuit/slimefun4/core/services/github/ContributionsConnector.java index 7e5b166e1..df7a9915c 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/core/services/github/ContributionsConnector.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/core/services/github/ContributionsConnector.java @@ -75,6 +75,7 @@ class ContributionsConnector extends GitHubConnector { aliases.put("ramdon-person", "ramdon_person"); aliases.put("NCBPFluffyBear", "FluffyBear_"); aliases.put("martinbrom", "OneTime97"); + aliases.put("LilBC", "Lil_BC"); } /** @@ -134,4 +135,4 @@ class ContributionsConnector extends GitHubConnector { } } } -} \ No newline at end of file +} diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/GrindStone.java b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/GrindStone.java index 11563d6cb..4be2a24d7 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/GrindStone.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/GrindStone.java @@ -6,6 +6,7 @@ import java.util.stream.Collectors; import javax.annotation.Nonnull; import javax.annotation.ParametersAreNonnullByDefault; +import io.github.thebusybiscuit.slimefun4.api.MinecraftVersion; import org.bukkit.Material; import org.bukkit.Sound; import org.bukkit.block.Block; @@ -80,6 +81,11 @@ public class GrindStone extends MultiBlockMachine { recipes.add(new ItemStack(Material.QUARTZ_BLOCK)); recipes.add(new ItemStack(Material.QUARTZ, 4)); + if (SlimefunPlugin.getMinecraftVersion().isAtLeast(MinecraftVersion.MINECRAFT_1_17)) { + recipes.add(new ItemStack(Material.AMETHYST_BLOCK)); + recipes.add(new ItemStack(Material.AMETHYST_SHARD, 4)); + } + recipes.add(SlimefunItems.MAGIC_LUMP_2); recipes.add(new SlimefunItemStack(SlimefunItems.MAGIC_LUMP_1, 4)); diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/miner/IndustrialMiner.java b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/miner/IndustrialMiner.java index dec2ebd5f..189fb4cf1 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/miner/IndustrialMiner.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/implementation/items/multiblocks/miner/IndustrialMiner.java @@ -52,6 +52,7 @@ public class IndustrialMiner extends MultiBlockMachine { protected final List fuelTypes = new ArrayList<>(); private final ItemSetting canMineAncientDebris = new ItemSetting<>(this, "can-mine-ancient-debris", false); + private final ItemSetting canMineDeepslateOres = new ItemSetting<>(this, "can-mine-deepslate-ores", true); private final boolean silkTouch; private final int range; @@ -64,6 +65,7 @@ public class IndustrialMiner extends MultiBlockMachine { registerDefaultFuelTypes(); addItemSetting(canMineAncientDebris); + addItemSetting(canMineDeepslateOres); } /** @@ -159,12 +161,12 @@ public class IndustrialMiner extends MultiBlockMachine { } @Override - public String getLabelLocalPath() { + public @Nonnull String getLabelLocalPath() { return "guide.tooltips.recipes.generator"; } @Override - public List getDisplayRecipes() { + public @Nonnull List getDisplayRecipes() { List list = new ArrayList<>(); for (MachineFuel fuel : fuelTypes) { @@ -217,14 +219,16 @@ public class IndustrialMiner extends MultiBlockMachine { * @return Whether this {@link IndustrialMiner} is capable of mining this {@link Material} */ public boolean canMine(@Nonnull Material type) { - if (SlimefunTag.INDUSTRIAL_MINER_ORES.isTagged(type)) { - return true; - } else if (SlimefunPlugin.getMinecraftVersion().isAtLeast(MinecraftVersion.MINECRAFT_1_16)) { - return type == Material.ANCIENT_DEBRIS && canMineAncientDebris.getValue(); - + MinecraftVersion version = SlimefunPlugin.getMinecraftVersion(); + if (version.isAtLeast(MinecraftVersion.MINECRAFT_1_16) && type == Material.ANCIENT_DEBRIS) { + return canMineAncientDebris.getValue(); } - return false; + if (version.isAtLeast(MinecraftVersion.MINECRAFT_1_17) && SlimefunTag.DEEPSLATE_ORES.isTagged(type)) { + return canMineDeepslateOres.getValue(); + } + + return SlimefunTag.INDUSTRIAL_MINER_ORES.isTagged(type); } }