Skip to content

Commit

Permalink
Fixed drill dyeing recipes, Closes #1459
Browse files Browse the repository at this point in the history
  • Loading branch information
Flanks255 committed Dec 7, 2024
1 parent e9979ba commit db9095e
Show file tree
Hide file tree
Showing 24 changed files with 134 additions and 73 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# 1.3.12+mc1.21.1
* Fixed the Drill dye recipes not functioning.
* Fixed the name of the first drill speed augment.

# 1.3.11+mc1.21.1
* Fixed Farmer not playing well with non-vanilla farmland.
* Added the ability to change the farmers work area with a compass.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// 1.21.1 2024-11-07T15:26:09.7156836 Item Recipes
// 1.21.1 2024-12-06T21:14:51.7296768 Item Recipes
14bd5bc2ee3e84b6f3a3181c0e0efd40df5f1d84 data/actuallyadditions/recipe/advanced_coil.json
955aad6c1def123a6adbaeabb13faa6eedce847f data/actuallyadditions/recipe/advanced_leaf_blower.json
97e7ba64f5054b030f4e49615dc4212a28ca9be1 data/actuallyadditions/recipe/basic_coil.json
Expand Down Expand Up @@ -49,22 +49,22 @@ aa04cb95f6c723f631b968afbd0037192e0a46aa data/actuallyadditions/recipe/decompres
263394a8ccab3e239b870b78bf4d1dca959f6c08 data/actuallyadditions/recipe/decompress/void_crystal_shard.json
5c9c0603f78ceb6de7e55a398fed6d30e44936c9 data/actuallyadditions/recipe/diamond_aiot.json
d449363a6a4b89c8a718d98cde294cc648a9b485 data/actuallyadditions/recipe/double_battery.json
836d06df12ebb1b4506ebd3b95f4d488a62ec0c4 data/actuallyadditions/recipe/drill_coloring/dye_drill_black.json
fb1f5a571b19ef49a899d5776b626118342108b3 data/actuallyadditions/recipe/drill_coloring/dye_drill_blue.json
84d5c995ee33352d69ee5c2aa83c3968affbcebb data/actuallyadditions/recipe/drill_coloring/dye_drill_brown.json
e58498cdfe8fe51b04292864f62711af67b44d35 data/actuallyadditions/recipe/drill_coloring/dye_drill_cyan.json
ce971f33b9e8be10e43fc7e7be91a0573ff45f73 data/actuallyadditions/recipe/drill_coloring/dye_drill_gray.json
fa6c5ffc9f742799ac639a3138ce8bb5b548b4c2 data/actuallyadditions/recipe/drill_coloring/dye_drill_green.json
087149df86c0332d9f321c1c092db0ad33c967dd data/actuallyadditions/recipe/drill_coloring/dye_drill_light_blue.json
11821c443c3fcea44d4527ddc8f8a51133853133 data/actuallyadditions/recipe/drill_coloring/dye_drill_light_gray.json
7df9ef361d0b366860bbf92424cf0d0bf79035f9 data/actuallyadditions/recipe/drill_coloring/dye_drill_lime.json
698cf24c334d5bb05f447a4fdf8f1e5546e20b1f data/actuallyadditions/recipe/drill_coloring/dye_drill_magenta.json
e447436880c0370d9a0158a7ee47cc6a95a0dd0f data/actuallyadditions/recipe/drill_coloring/dye_drill_orange.json
022958646fc11a838f9083ecd553f7a051020a06 data/actuallyadditions/recipe/drill_coloring/dye_drill_pink.json
78490dfd929a5bbd4ece14ec098f98ca8e7cc854 data/actuallyadditions/recipe/drill_coloring/dye_drill_purple.json
5e1a4f23d9d596bed5f2aebca574002918a5fb97 data/actuallyadditions/recipe/drill_coloring/dye_drill_red.json
91e28015934f2e49144760cb4c454b9593d1b85e data/actuallyadditions/recipe/drill_coloring/dye_drill_white.json
1122df15841403bfb97f6e020090abb1e9494796 data/actuallyadditions/recipe/drill_coloring/dye_drill_yellow.json
2632116b27a8f0c5697ffc12a540520ff4817c00 data/actuallyadditions/recipe/drill_coloring/dye_drill_black.json
1c6242d3910f3afe4e270113c8a402823da6b0cb data/actuallyadditions/recipe/drill_coloring/dye_drill_blue.json
eb357e471110e905e5f7d0531dcac3dcb01ad4ff data/actuallyadditions/recipe/drill_coloring/dye_drill_brown.json
ac1a0baad5a287c1e655ada7ce98cc6aaecc83f9 data/actuallyadditions/recipe/drill_coloring/dye_drill_cyan.json
e6219d74254bea00addcdf08f1a644f847968a6e data/actuallyadditions/recipe/drill_coloring/dye_drill_gray.json
6d0c945fa07d8f8842a9099f2ff608e224b085a7 data/actuallyadditions/recipe/drill_coloring/dye_drill_green.json
a6cef0e184cff8f11084778dc0a72d05485f3fbc data/actuallyadditions/recipe/drill_coloring/dye_drill_light_blue.json
79f98f436372c3f85a35fbd3d7a3de42a8117d1f data/actuallyadditions/recipe/drill_coloring/dye_drill_light_gray.json
5f843e257dd0e03d73656d8d1733b63aab750124 data/actuallyadditions/recipe/drill_coloring/dye_drill_lime.json
525a514e7d376f3d0819dc95955ba3276b74c5d9 data/actuallyadditions/recipe/drill_coloring/dye_drill_magenta.json
cd022566bfd3bf7abd37c81e63223bbbd4b8c83d data/actuallyadditions/recipe/drill_coloring/dye_drill_orange.json
b9f81ade143cdd026cb61ee0bc72c712152c599d data/actuallyadditions/recipe/drill_coloring/dye_drill_pink.json
991e75b85e40ac7ee488c4680294f566a0a6bcd2 data/actuallyadditions/recipe/drill_coloring/dye_drill_purple.json
6d10bb7fee0bfc22662ecbe7a9e8946dabb2ab40 data/actuallyadditions/recipe/drill_coloring/dye_drill_red.json
755eddac6c3de13163f24ddb268717d174c6c2a2 data/actuallyadditions/recipe/drill_coloring/dye_drill_white.json
2c3431723d0a68b86ab19e290ae87331b968189c data/actuallyadditions/recipe/drill_coloring/dye_drill_yellow.json
3226a302f425ab52edb0c6008c7a4eb10cb2fd18 data/actuallyadditions/recipe/drill_core.json
8df3f7b20c8c46ed492b314aa4322b6a00178417 data/actuallyadditions/recipe/drill_light_blue.json
f146fe12be4b36cd125d85ea25e26d5288198f72 data/actuallyadditions/recipe/drill_pattern.json
Expand Down Expand Up @@ -131,7 +131,7 @@ b5bcd0457a68e28d37312f1a1e94a106d3b6f038 data/actuallyadditions/recipe/ring_of_g
f31206c1d67ddc93e41d13f24d54e8d6b5913348 data/actuallyadditions/recipe/single_battery.json
9504d2a8e3cb536cf865e8385a013743a0d615d0 data/actuallyadditions/recipe/stone_aiot.json
bd83fca2a318f4b513a38310e4b3d26f87ab9439 data/actuallyadditions/recipe/tagged_slime_block.json
7e657b2d9a1aeea7fc93f8be27b4a32f814f21e4 data/actuallyadditions/recipe/tagged_sticky_piston.json
685c36302163f912fd6979181f9c07fdc21e317a data/actuallyadditions/recipe/tagged_sticky_piston.json
b40274260097d19ae4f925e31982d8bfad3acd84 data/actuallyadditions/recipe/teleport_staff.json
b0e94b90682d5224dd995c15b26d6df50fd78dd6 data/actuallyadditions/recipe/tiny_to_charcoal.json
a60310bd6c5ec1368137372aed468e673cd1fd00 data/actuallyadditions/recipe/tiny_to_coal.json
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/black"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/blue"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/brown"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/cyan"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/gray"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/green"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/light_blue"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/light_gray"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/lime"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/magenta"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/orange"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/pink"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/purple"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/red"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/white"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@
"category": "misc",
"ingredients": [
{
"tag": "actuallyadditions:drills"
"type": "actuallyadditions:target_nbt",
"base": {
"tag": "actuallyadditions:drills"
}
},
{
"tag": "c:dyes/yellow"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"item": "minecraft:piston"
},
"R": {
"tag": "c:slimeballs"
"tag": "c:slime_balls"
}
},
"pattern": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import de.ellpeck.actuallyadditions.mod.config.conditions.BoolConfigCondition;
import de.ellpeck.actuallyadditions.mod.crafting.RecipeKeepDataShaped;
import de.ellpeck.actuallyadditions.mod.crafting.RecipeKeepDataShapeless;
import de.ellpeck.actuallyadditions.mod.crafting.TargetNBTIngredient;
import de.ellpeck.actuallyadditions.mod.crafting.TargetComponentIngredient;
import de.ellpeck.actuallyadditions.mod.items.ActuallyItems;
import de.ellpeck.actuallyadditions.mod.util.NoAdvRecipeOutput;
import de.ellpeck.actuallyadditions.mod.util.RecipeInjector;
Expand Down Expand Up @@ -46,6 +46,7 @@ public ItemRecipeGenerator(PackOutput packOutput, CompletableFuture<HolderLookup
super(packOutput, lookupProvider);
}

@Nonnull
@Override
public String getName() {
return "Item " + super.getName();
Expand Down Expand Up @@ -162,9 +163,8 @@ protected void buildRecipes(@Nonnull RecipeOutput output, HolderLookup.Provider

//Killer Lens
ItemStack enchantedBook = new ItemStack(Items.ENCHANTED_BOOK);
if (enchantmentLookup != null) {
enchantedBook.enchant(enchantmentLookup.getOrThrow(Enchantments.SHARPNESS), 5);
}
enchantedBook.enchant(enchantmentLookup.getOrThrow(Enchantments.SHARPNESS), 5);

Recipe.shapeless(ActuallyItems.LENS_OF_THE_KILLER.get())
.requires(Items.DIAMOND_SWORD)
.requires(ActuallyItems.LENS_OF_CERTAIN_DEATH.get())
Expand Down Expand Up @@ -409,7 +409,7 @@ protected void buildRecipes(@Nonnull RecipeOutput output, HolderLookup.Provider
.pattern(" R ")
.pattern("ICI")
.pattern("III")
.define('R', TargetNBTIngredient.of(ActuallyItems.SINGLE_BATTERY.get()))
.define('R', TargetComponentIngredient.of(ActuallyItems.SINGLE_BATTERY.get()))
.define('I', ActuallyItems.ENORI_CRYSTAL.get())
.define('C', ActuallyItems.ADVANCED_COIL.get())
.save(new RecipeInjector<ShapedRecipe>(recipeOutput, RecipeKeepDataShaped::new));
Expand All @@ -419,7 +419,7 @@ protected void buildRecipes(@Nonnull RecipeOutput output, HolderLookup.Provider
.pattern(" R ")
.pattern("ICI")
.pattern("III")
.define('R', TargetNBTIngredient.of(ActuallyItems.DOUBLE_BATTERY.get()))
.define('R', TargetComponentIngredient.of(ActuallyItems.DOUBLE_BATTERY.get()))
.define('I', ActuallyItems.EMPOWERED_ENORI_CRYSTAL.get())
.define('C', ActuallyItems.ADVANCED_COIL.get())
.save(new RecipeInjector<ShapedRecipe>(recipeOutput, RecipeKeepDataShaped::new));
Expand All @@ -429,7 +429,7 @@ protected void buildRecipes(@Nonnull RecipeOutput output, HolderLookup.Provider
.pattern(" R ")
.pattern("ICI")
.pattern("III")
.define('R', TargetNBTIngredient.of(ActuallyItems.TRIPLE_BATTERY.get()))
.define('R', TargetComponentIngredient.of(ActuallyItems.TRIPLE_BATTERY.get()))
.define('I', ActuallyItems.EMPOWERED_ENORI_CRYSTAL.get())
.define('C', ActuallyItems.ADVANCED_COIL.get())
.save(new RecipeInjector<ShapedRecipe>(recipeOutput, RecipeKeepDataShaped::new));
Expand All @@ -439,7 +439,7 @@ protected void buildRecipes(@Nonnull RecipeOutput output, HolderLookup.Provider
.pattern(" R ")
.pattern("ICI")
.pattern("III")
.define('R', TargetNBTIngredient.of(ActuallyItems.QUADRUPLE_BATTERY.get()))
.define('R', TargetComponentIngredient.of(ActuallyItems.QUADRUPLE_BATTERY.get()))
.define('I', ActuallyItems.EMPOWERED_DIAMATINE_CRYSTAL.get())
.define('C', ActuallyItems.ADVANCED_COIL.get())
.save(new RecipeInjector<ShapedRecipe>(recipeOutput, RecipeKeepDataShaped::new));
Expand Down Expand Up @@ -533,14 +533,14 @@ protected void buildRecipes(@Nonnull RecipeOutput output, HolderLookup.Provider
// Sticky Piston from tagged slime balls
Recipe.shaped(Items.STICKY_PISTON)
.pattern("R", "P")
.define('R', Tags.Items.SLIMEBALLS)
.define('R', Tags.Items.SLIME_BALLS)
.define('P', Items.PISTON)
.save(recipeOutput, ActuallyAdditions.modLoc("tagged_sticky_piston"));

// Slime block from tagged balls
Recipe.shaped(Items.SLIME_BLOCK)
.pattern("RRR", "RRR", "RRR")
.define('R', Tags.Items.SLIMEBALLS)
.define('R', Tags.Items.SLIME_BALLS)
.save(recipeOutput, ActuallyAdditions.modLoc("tagged_slime_block"));

//Shards
Expand Down Expand Up @@ -650,7 +650,7 @@ protected void generateAOIT(RecipeOutput consumer) {

private static void dyeDrill(DeferredItem<? extends Item> result, TagKey<Item> dyeItem, RecipeOutput recipeOutput) {
Recipe.shapeless(result.get())
.requires(Ingredient.of(ActuallyTags.Items.DRILLS)) //TargetNBTIngredient
.requires(TargetComponentIngredient.of(ActuallyTags.Items.DRILLS))
.requires(dyeItem)
.save(new RecipeInjector<ShapelessRecipe>(recipeOutput, RecipeKeepDataShapeless::new), ActuallyAdditions.modLoc("drill_coloring/dye_" + BuiltInRegistries.ITEM.getKey(result.get()).getPath()));
}
Expand Down Expand Up @@ -807,7 +807,7 @@ public void save(@Nonnull RecipeOutput consumer, @Nonnull ResourceLocation locat
}
}

private static class Shaped extends ShapedRecipeBuilder {
public static class Shaped extends ShapedRecipeBuilder {
public Shaped(ItemLike resultIn) {
this(resultIn, 1);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ public static class Types {
public static class Ingredients {
public static final DeferredRegister<IngredientType<?>> INGREDIENTS = DeferredRegister.create(NeoForgeRegistries.Keys.INGREDIENT_TYPES, ActuallyAdditions.MODID);

public static final Supplier<IngredientType<TargetNBTIngredient>> TARGET_NBT = INGREDIENTS.register("target_nbt", () -> new IngredientType<>(TargetNBTIngredient.CODEC));
//TODO change name from nbt in 1.22
public static final Supplier<IngredientType<TargetComponentIngredient>> TARGET_NBT = INGREDIENTS.register("target_nbt", () -> new IngredientType<>(TargetComponentIngredient.CODEC));
}
}
Loading

0 comments on commit db9095e

Please sign in to comment.