diff --git a/build.gradle b/build.gradle index ac0f90e..03f3a9d 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ plugins { - id 'fabric-loom' version '1.7-SNAPSHOT' + id 'fabric-loom' version '1.8-SNAPSHOT' id 'com.modrinth.minotaur' version '2.+' id 'maven-publish' } @@ -30,8 +30,8 @@ dependencies { // Local dependencies modLocalRuntime "com.terraformersmc:modmenu:${project.modmenu}" - modLocalRuntime "maven.modrinth:lithium:${project.lithium}" - modLocalRuntime "vazkii.patchouli:Patchouli:${project.patchouli}" +// modLocalRuntime "maven.modrinth:lithium:${project.lithium}" +// modLocalRuntime "vazkii.patchouli:Patchouli:${project.patchouli}" // modLocalRuntime "me.shedaniel:RoughlyEnoughItems-fabric:${project.rei}" // modLocalRuntime "dev.emi:emi:${project.emi}" } diff --git a/gradle.properties b/gradle.properties index 6d31618..94328f8 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,20 +2,20 @@ org.gradle.jvmargs=-Xmx1G org.gradle.parallel=true # Required dependencies -minecraft=1.21.1 -mappings=1.21.1+build.3 -fabric_loader=0.16.7 -fabric_api=0.106.0+1.21.1 -owo_lib=0.12.15+1.21 +minecraft=1.21.3 +mappings=1.21.3+build.1 +fabric_loader=0.16.8 +fabric_api=0.107.0+1.21.3 +owo_lib=0.12.16+1.21.2 # Local dependencies -modmenu=11.0.3 +modmenu=12.0.0-beta.1 lithium=mc1.21.1-0.13.1 patchouli=1.21-87-FABRIC rei=16.0.783 emi=1.1.16+1.21.1+fabric # Project detail -mod_version=0.15.1+1.21.1 +mod_version=0.15.1+1.21.3 maven_group=io.github.realguyman archives_base_name=totally_lit diff --git a/src/main/java/io/github/realguyman/totally_lit/TotallyLit.java b/src/main/java/io/github/realguyman/totally_lit/TotallyLit.java index 8a0b0e7..329af9d 100644 --- a/src/main/java/io/github/realguyman/totally_lit/TotallyLit.java +++ b/src/main/java/io/github/realguyman/totally_lit/TotallyLit.java @@ -26,7 +26,6 @@ import net.minecraft.sound.SoundEvents; import net.minecraft.util.ActionResult; import net.minecraft.util.Hand; -import net.minecraft.util.TypedActionResult; import net.minecraft.util.hit.BlockHitResult; import net.minecraft.util.hit.HitResult; import net.minecraft.util.math.BlockPos; @@ -207,7 +206,7 @@ private ActionResult igniteUnlitItemInHand( return ActionResult.PASS; } - private TypedActionResult igniteUnlitItemInHandFromRaycast( + private ActionResult igniteUnlitItemInHandFromRaycast( PlayerEntity player, World world, Hand hand, @@ -219,7 +218,7 @@ private TypedActionResult igniteUnlitItemInHandFromRaycast( final ItemStack stack = player.getStackInHand(hand); if (!world.getFluidState(pos).isIn(igniterFluids)) { - return TypedActionResult.pass(stack); + return ActionResult.PASS; } for (Map.Entry entry : map.entrySet()) { @@ -231,15 +230,15 @@ private TypedActionResult igniteUnlitItemInHandFromRaycast( } if (!player.giveItemStack(new ItemStack(lit))) { - return TypedActionResult.fail(stack); + return ActionResult.FAIL; } stack.decrement(1); world.playSound(null, player.getBlockPos(), SoundEvents.ITEM_FIRECHARGE_USE, SoundCategory.BLOCKS, 0.125F, world.getRandom().nextFloat() * 0.5F + 0.125F); - return TypedActionResult.success(stack, true); + return ActionResult.SUCCESS; } - return TypedActionResult.pass(stack); + return ActionResult.PASS; } private ActionResult igniteUnlitBlock( diff --git a/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockEntityMixin.java b/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockEntityMixin.java index 9491878..55d7270 100644 --- a/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockEntityMixin.java +++ b/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockEntityMixin.java @@ -3,21 +3,23 @@ import io.github.realguyman.totally_lit.TotallyLit; import io.github.realguyman.totally_lit.access.CampfireBlockEntityAccess; import io.github.realguyman.totally_lit.registry.TagRegistry; -import java.util.List; import net.minecraft.block.BlockState; import net.minecraft.block.CampfireBlock; import net.minecraft.block.entity.CampfireBlockEntity; import net.minecraft.entity.passive.VillagerEntity; import net.minecraft.nbt.NbtCompound; import net.minecraft.predicate.entity.EntityPredicates; +import net.minecraft.recipe.CampfireCookingRecipe; +import net.minecraft.recipe.ServerRecipeManager; +import net.minecraft.recipe.input.SingleStackRecipeInput; import net.minecraft.registry.RegistryWrapper; +import net.minecraft.server.world.ServerWorld; import net.minecraft.sound.SoundCategory; import net.minecraft.sound.SoundEvents; import net.minecraft.state.property.Properties; import net.minecraft.util.TypeFilter; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Box; -import net.minecraft.world.World; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Unique; import org.spongepowered.asm.mixin.injection.At; @@ -50,7 +52,7 @@ private void writeTicksBurntForToNbt(NbtCompound nbt, RegistryWrapper.WrapperLoo } @Inject(method = "litServerTick", at = @At("RETURN")) - private static void trackTicksBurntFor(World world, BlockPos pos, BlockState state, CampfireBlockEntity campfire, CallbackInfo ci) { + private static void trackTicksBurntFor(ServerWorld world, BlockPos pos, BlockState state, CampfireBlockEntity campfire, ServerRecipeManager.MatchGetter recipeMatchGetter, CallbackInfo ci) { var nearbyVillagers = world.getEntitiesByType( TypeFilter.instanceOf(VillagerEntity.class), new Box(pos).expand(32), diff --git a/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockMixin.java b/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockMixin.java index 2ba2cf5..3d8976b 100644 --- a/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockMixin.java +++ b/src/main/java/io/github/realguyman/totally_lit/mixin/campfire/CampfireBlockMixin.java @@ -6,18 +6,16 @@ import net.minecraft.block.BlockState; import net.minecraft.block.BlockWithEntity; import net.minecraft.block.CampfireBlock; -import net.minecraft.enchantment.Enchantment; import net.minecraft.enchantment.EnchantmentHelper; import net.minecraft.enchantment.Enchantments; import net.minecraft.entity.EquipmentSlot; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.item.ItemStack; -import net.minecraft.registry.tag.TagKey; import net.minecraft.sound.SoundCategory; import net.minecraft.sound.SoundEvents; import net.minecraft.stat.Stats; +import net.minecraft.util.ActionResult; import net.minecraft.util.Hand; -import net.minecraft.util.ItemActionResult; import net.minecraft.util.hit.BlockHitResult; import net.minecraft.util.math.BlockPos; import net.minecraft.world.World; @@ -38,7 +36,7 @@ private BlockState litStateWhenPlaced(BlockState original) { } @Inject(method = "onUseWithItem", at = @At("HEAD"), cancellable = true) - private void ignite(ItemStack stack, BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit, CallbackInfoReturnable cir) { + private void ignite(ItemStack stack, BlockState state, World world, BlockPos pos, PlayerEntity player, Hand hand, BlockHitResult hit, CallbackInfoReturnable cir) { final boolean canBeIgnited = CampfireBlock.canBeLit(state); final boolean stackHasFireAspect = EnchantmentHelper.getEnchantments(stack).getEnchantments().contains(Enchantments.FIRE_ASPECT); @@ -47,12 +45,12 @@ private void ignite(ItemStack stack, BlockState state, World world, BlockPos pos } if (!world.setBlockState(pos, state.with(CampfireBlock.LIT, true))) { - cir.setReturnValue(ItemActionResult.FAIL); + cir.setReturnValue(ActionResult.FAIL); } stack.damage(1, player, EquipmentSlot.values()[hand.ordinal()]); world.playSound(null, pos, SoundEvents.ITEM_FIRECHARGE_USE, SoundCategory.BLOCKS, 0.125F, world.getRandom().nextFloat() * 0.5F + 0.125F); player.incrementStat(Stats.INTERACT_WITH_CAMPFIRE); - cir.setReturnValue(ItemActionResult.SUCCESS); + cir.setReturnValue(ActionResult.SUCCESS); } } diff --git a/src/main/java/io/github/realguyman/totally_lit/registry/BlockRegistry.java b/src/main/java/io/github/realguyman/totally_lit/registry/BlockRegistry.java index 22de3d1..2fc97ed 100644 --- a/src/main/java/io/github/realguyman/totally_lit/registry/BlockRegistry.java +++ b/src/main/java/io/github/realguyman/totally_lit/registry/BlockRegistry.java @@ -10,6 +10,8 @@ import net.minecraft.block.LanternBlock; import net.minecraft.registry.Registries; import net.minecraft.registry.Registry; +import net.minecraft.registry.RegistryKey; +import net.minecraft.registry.RegistryKeys; import net.minecraft.util.Identifier; public class BlockRegistry { @@ -29,15 +31,94 @@ private static Block add(String path, Block block) { } static { - GLOWSTONE_TORCH = add("glowstone_torch", new NoParticleTorchBlock(Settings.copy(Blocks.TORCH))); - GLOWSTONE_WALL_TORCH = add("glowstone_wall_torch", new NoParticleWallTorchBlock(Settings.copy(Blocks.TORCH).dropsLike(GLOWSTONE_TORCH))); - GLOWSTONE_LANTERN = add("glowstone_lantern", new LanternBlock(Settings.copy(Blocks.LANTERN))); - UNLIT_JACK_O_LANTERN = add("unlit_jack_o_lantern", new CarvedPumpkinBlock(Settings.copy(Blocks.JACK_O_LANTERN).luminance(state -> 0))); - UNLIT_LANTERN = add("unlit_lantern", new LanternBlock(Settings.copy(Blocks.LANTERN).luminance(state -> 0))); - UNLIT_SOUL_LANTERN = add("unlit_soul_lantern", new LanternBlock(Settings.copy(UNLIT_LANTERN))); - UNLIT_SOUL_TORCH = add("unlit_soul_torch", new NoParticleTorchBlock(Settings.copy(Blocks.TORCH).luminance(state -> 0))); - UNLIT_SOUL_WALL_TORCH = add("unlit_soul_wall_torch", new NoParticleWallTorchBlock(Settings.copy(Blocks.WALL_TORCH).luminance(state -> 0).dropsLike(UNLIT_SOUL_TORCH))); - UNLIT_TORCH = add("unlit_torch", new NoParticleTorchBlock(Settings.copy(Blocks.TORCH).luminance(state -> 0))); - UNLIT_WALL_TORCH = add("unlit_wall_torch", new NoParticleWallTorchBlock(Settings.copy(Blocks.WALL_TORCH).luminance(state -> 0).dropsLike(UNLIT_TORCH))); + GLOWSTONE_TORCH = add( + "glowstone_torch", + new NoParticleTorchBlock( + Settings.copy(Blocks.TORCH) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "glowstone_torch"))) + ) + ); + + GLOWSTONE_WALL_TORCH = add( + "glowstone_wall_torch", + new NoParticleWallTorchBlock( + Settings.copy(Blocks.TORCH) + .lootTable(GLOWSTONE_TORCH.getLootTableKey()) + .overrideTranslationKey(GLOWSTONE_TORCH.getTranslationKey()) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "glowstone_wall_torch"))) + ) + ); + + GLOWSTONE_LANTERN = add( + "glowstone_lantern", + new LanternBlock( + Settings.copy(Blocks.LANTERN) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "glowstone_lantern"))) + ) + ); + + UNLIT_JACK_O_LANTERN = add( + "unlit_jack_o_lantern", + new CarvedPumpkinBlock( + Settings.copy(Blocks.JACK_O_LANTERN) + .luminance(state -> 0) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_jack_o_lantern"))) + ) + ); + + UNLIT_LANTERN = add( + "unlit_lantern", + new LanternBlock( + Settings.copy(Blocks.LANTERN) + .luminance(state -> 0) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_lantern"))) + ) + ); + + UNLIT_SOUL_LANTERN = add( + "unlit_soul_lantern", + new LanternBlock( + Settings.copy(UNLIT_LANTERN) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_soul_lantern"))) + ) + ); + + UNLIT_SOUL_TORCH = add( + "unlit_soul_torch", + new NoParticleTorchBlock( + Settings.copy(Blocks.TORCH) + .luminance(state -> 0) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_soul_torch"))) + ) + ); + + UNLIT_SOUL_WALL_TORCH = add( + "unlit_soul_wall_torch", + new NoParticleWallTorchBlock( + Settings.copy(Blocks.WALL_TORCH) + .luminance(state -> 0) + .lootTable(UNLIT_SOUL_TORCH.getLootTableKey()) + .overrideTranslationKey(UNLIT_SOUL_TORCH.getTranslationKey()) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_soul_wall_torch"))) + ) + ); + + UNLIT_TORCH = add("unlit_torch", + new NoParticleTorchBlock( + Settings.copy(Blocks.TORCH) + .luminance(state -> 0) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_torch"))) + ) + ); + + UNLIT_WALL_TORCH = add("unlit_wall_torch", + new NoParticleWallTorchBlock( + Settings.copy(Blocks.WALL_TORCH) + .luminance(state -> 0) + .lootTable(UNLIT_TORCH.getLootTableKey()) + .overrideTranslationKey(UNLIT_TORCH.getTranslationKey()) + .registryKey(RegistryKey.of(RegistryKeys.BLOCK, Identifier.of(TotallyLit.MOD_ID, "unlit_wall_torch"))) + ) + ); } } diff --git a/src/main/java/io/github/realguyman/totally_lit/registry/ItemRegistry.java b/src/main/java/io/github/realguyman/totally_lit/registry/ItemRegistry.java index 8c1eb69..81c49c2 100644 --- a/src/main/java/io/github/realguyman/totally_lit/registry/ItemRegistry.java +++ b/src/main/java/io/github/realguyman/totally_lit/registry/ItemRegistry.java @@ -1,20 +1,71 @@ package io.github.realguyman.totally_lit.registry; import io.github.realguyman.totally_lit.TotallyLit; -import net.minecraft.item.*; +import net.minecraft.item.BlockItem; +import net.minecraft.item.Item; +import net.minecraft.item.VerticallyAttachableBlockItem; import net.minecraft.registry.Registries; import net.minecraft.registry.Registry; +import net.minecraft.registry.RegistryKey; +import net.minecraft.registry.RegistryKeys; import net.minecraft.util.Identifier; import net.minecraft.util.math.Direction; public class ItemRegistry { - public static final Item GLOWSTONE_TORCH = new VerticallyAttachableBlockItem(BlockRegistry.GLOWSTONE_TORCH, BlockRegistry.GLOWSTONE_WALL_TORCH, new Item.Settings(), Direction.DOWN); - public static final Item GLOWSTONE_LANTERN = new BlockItem(BlockRegistry.GLOWSTONE_LANTERN, new Item.Settings()); - public static final Item UNLIT_JACK_O_LANTERN = new BlockItem(BlockRegistry.UNLIT_JACK_O_LANTERN, new Item.Settings()); - public static final Item UNLIT_LANTERN = new BlockItem(BlockRegistry.UNLIT_LANTERN, new Item.Settings()); - public static final Item UNLIT_SOUL_LANTERN = new BlockItem(BlockRegistry.UNLIT_SOUL_LANTERN, new Item.Settings()); - public static final Item UNLIT_SOUL_TORCH = new VerticallyAttachableBlockItem(BlockRegistry.UNLIT_SOUL_TORCH, BlockRegistry.UNLIT_SOUL_WALL_TORCH, new Item.Settings(), Direction.DOWN); - public static final Item UNLIT_TORCH = new VerticallyAttachableBlockItem(BlockRegistry.UNLIT_TORCH, BlockRegistry.UNLIT_WALL_TORCH, new Item.Settings(), Direction.DOWN); + public static final Item GLOWSTONE_TORCH = new VerticallyAttachableBlockItem( + BlockRegistry.GLOWSTONE_TORCH, + BlockRegistry.GLOWSTONE_WALL_TORCH, + Direction.DOWN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "glowstone_torch"))) + ); + + public static final Item GLOWSTONE_LANTERN = new BlockItem( + BlockRegistry.GLOWSTONE_LANTERN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "glowstone_lantern"))) + ); + + public static final Item UNLIT_JACK_O_LANTERN = new BlockItem( + BlockRegistry.UNLIT_JACK_O_LANTERN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "unlit_jack_o_lantern"))) + ); + + public static final Item UNLIT_LANTERN = new BlockItem( + BlockRegistry.UNLIT_LANTERN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "unlit_lantern"))) + ); + + public static final Item UNLIT_SOUL_LANTERN = new BlockItem( + BlockRegistry.UNLIT_SOUL_LANTERN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "unlit_soul_lantern"))) + ); + + public static final Item UNLIT_SOUL_TORCH = new VerticallyAttachableBlockItem( + BlockRegistry.UNLIT_SOUL_TORCH, + BlockRegistry.UNLIT_SOUL_WALL_TORCH, + Direction.DOWN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "unlit_soul_torch"))) + ); + + public static final Item UNLIT_TORCH = new VerticallyAttachableBlockItem( + BlockRegistry.UNLIT_TORCH, + BlockRegistry.UNLIT_WALL_TORCH, + Direction.DOWN, + new Item.Settings() + .useBlockPrefixedTranslationKey() + .registryKey(RegistryKey.of(RegistryKeys.ITEM, Identifier.of(TotallyLit.MOD_ID, "unlit_torch"))) + ); private static Item add(String path, Item item) { return Registry.register(Registries.ITEM, Identifier.of(TotallyLit.MOD_ID, path), item); diff --git a/src/main/resources/data/minecraft/recipe/soul_torch.json b/src/main/resources/data/minecraft/recipe/soul_torch.json index 14de158..2578e42 100644 --- a/src/main/resources/data/minecraft/recipe/soul_torch.json +++ b/src/main/resources/data/minecraft/recipe/soul_torch.json @@ -1,28 +1,16 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "totally_lit:unlit_soul_torch" - }, [ - { - "item": "minecraft:torch" - }, - { - "item": "minecraft:soul_torch" - }, - { - "item": "minecraft:lava_bucket" - }, - { - "item": "minecraft:magma_block" - }, - { - "item": "minecraft:lantern" - }, - { - "item": "minecraft:soul_lantern" - } + "totally_lit:unlit_soul_torch" + ], + [ + "minecraft:torch", + "minecraft:soul_torch", + "minecraft:lava_bucket", + "minecraft:magma_block", + "minecraft:lantern", + "minecraft:soul_lantern" ] ], "result": { diff --git a/src/main/resources/data/minecraft/recipe/torch.json b/src/main/resources/data/minecraft/recipe/torch.json index f4bd151..9ac6d6f 100644 --- a/src/main/resources/data/minecraft/recipe/torch.json +++ b/src/main/resources/data/minecraft/recipe/torch.json @@ -1,28 +1,14 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "totally_lit:unlit_torch" - }, + "totally_lit:unlit_torch", [ - { - "item": "minecraft:torch" - }, - { - "item": "minecraft:soul_torch" - }, - { - "item": "minecraft:lava_bucket" - }, - { - "item": "minecraft:magma_block" - }, - { - "item": "minecraft:lantern" - }, - { - "item": "minecraft:soul_lantern" - } + "minecraft:torch", + "minecraft:soul_torch", + "minecraft:lava_bucket", + "minecraft:magma_block", + "minecraft:lantern", + "minecraft:soul_lantern" ] ], "result": { diff --git a/src/main/resources/data/totally_lit/recipe/glowstone_lantern.json b/src/main/resources/data/totally_lit/recipe/glowstone_lantern.json index db48ac8..8beb3a9 100644 --- a/src/main/resources/data/totally_lit/recipe/glowstone_lantern.json +++ b/src/main/resources/data/totally_lit/recipe/glowstone_lantern.json @@ -6,16 +6,8 @@ "iii" ], "key": { - "i": [ - { - "item": "minecraft:iron_nugget" - } - ], - "u": [ - { - "item": "totally_lit:glowstone_torch" - } - ] + "i": "minecraft:iron_nugget", + "u": "totally_lit:glowstone_torch" }, "result": { "id": "totally_lit:glowstone_lantern" diff --git a/src/main/resources/data/totally_lit/recipe/glowstone_torch.json b/src/main/resources/data/totally_lit/recipe/glowstone_torch.json index 2fa286e..dd7c989 100644 --- a/src/main/resources/data/totally_lit/recipe/glowstone_torch.json +++ b/src/main/resources/data/totally_lit/recipe/glowstone_torch.json @@ -5,14 +5,8 @@ "|" ], "key": { - "#": [ - { - "item": "minecraft:glowstone_dust" - } - ], - "|": { - "item": "minecraft:stick" - } + "#": "minecraft:glowstone_dust", + "|": "minecraft:stick" }, "result": { "id": "totally_lit:glowstone_torch", diff --git a/src/main/resources/data/totally_lit/recipe/lantern_from_igniters.json b/src/main/resources/data/totally_lit/recipe/lantern_from_igniters.json index bd90643..1c49436 100644 --- a/src/main/resources/data/totally_lit/recipe/lantern_from_igniters.json +++ b/src/main/resources/data/totally_lit/recipe/lantern_from_igniters.json @@ -1,16 +1,10 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "totally_lit:unlit_lantern" - }, + "totally_lit:unlit_lantern", [ - { - "item": "minecraft:torch" - }, - { - "item": "minecraft:soul_torch" - } + "minecraft:torch", + "minecraft:soul_torch" ] ], "result": { diff --git a/src/main/resources/data/totally_lit/recipe/soul_lantern_from_igniters.json b/src/main/resources/data/totally_lit/recipe/soul_lantern_from_igniters.json index a206bda..0e74b1a 100644 --- a/src/main/resources/data/totally_lit/recipe/soul_lantern_from_igniters.json +++ b/src/main/resources/data/totally_lit/recipe/soul_lantern_from_igniters.json @@ -1,16 +1,10 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "totally_lit:unlit_soul_lantern" - }, + "totally_lit:unlit_soul_lantern", [ - { - "item": "minecraft:torch" - }, - { - "item": "minecraft:soul_torch" - } + "minecraft:torch", + "minecraft:soul_torch" ] ], "result": { diff --git a/src/main/resources/data/totally_lit/recipe/soul_torch_from_campfire.json b/src/main/resources/data/totally_lit/recipe/soul_torch_from_campfire.json index 2915d13..6f0a7b2 100644 --- a/src/main/resources/data/totally_lit/recipe/soul_torch_from_campfire.json +++ b/src/main/resources/data/totally_lit/recipe/soul_torch_from_campfire.json @@ -1,8 +1,6 @@ { "type": "minecraft:campfire_cooking", - "ingredient": { - "item": "totally_lit:unlit_soul_torch" - }, + "ingredient": "totally_lit:unlit_soul_torch", "result": { "id": "minecraft:soul_torch" }, diff --git a/src/main/resources/data/totally_lit/recipe/torch_from_campfire.json b/src/main/resources/data/totally_lit/recipe/torch_from_campfire.json index b19d3c7..ae92b73 100644 --- a/src/main/resources/data/totally_lit/recipe/torch_from_campfire.json +++ b/src/main/resources/data/totally_lit/recipe/torch_from_campfire.json @@ -1,8 +1,6 @@ { "type": "minecraft:campfire_cooking", - "ingredient": { - "item": "totally_lit:unlit_torch" - }, + "ingredient": "totally_lit:unlit_torch", "result": { "id": "minecraft:torch" }, diff --git a/src/main/resources/data/totally_lit/recipe/unlit_jack_o_lantern.json b/src/main/resources/data/totally_lit/recipe/unlit_jack_o_lantern.json index b17c4ec..7566c3a 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_jack_o_lantern.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_jack_o_lantern.json @@ -2,12 +2,8 @@ "type": "minecraft:crafting_shaped", "category": "building", "key": { - "A": { - "item": "minecraft:carved_pumpkin" - }, - "B": { - "item": "totally_lit:unlit_torch" - } + "A": "minecraft:carved_pumpkin", + "B": "totally_lit:unlit_torch" }, "pattern": [ "A", diff --git a/src/main/resources/data/totally_lit/recipe/unlit_lantern.json b/src/main/resources/data/totally_lit/recipe/unlit_lantern.json index add9b93..b9ecfb4 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_lantern.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_lantern.json @@ -6,16 +6,8 @@ "iii" ], "key": { - "i": [ - { - "item": "minecraft:iron_nugget" - } - ], - "u": [ - { - "item": "totally_lit:unlit_torch" - } - ] + "i": "minecraft:iron_nugget", + "u": "totally_lit:unlit_torch" }, "result": { "id": "totally_lit:unlit_lantern" diff --git a/src/main/resources/data/totally_lit/recipe/unlit_lantern_from_water_bucket.json b/src/main/resources/data/totally_lit/recipe/unlit_lantern_from_water_bucket.json index e6cf289..207dc30 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_lantern_from_water_bucket.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_lantern_from_water_bucket.json @@ -1,12 +1,8 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "minecraft:lantern" - }, - { - "item": "minecraft:water_bucket" - } + "minecraft:lantern", + "minecraft:water_bucket" ], "result": { "id": "totally_lit:unlit_lantern" diff --git a/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern.json b/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern.json index ee4cb6b..f946a18 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern.json @@ -6,16 +6,8 @@ "iii" ], "key": { - "i": [ - { - "item": "minecraft:iron_nugget" - } - ], - "u": [ - { - "item": "totally_lit:unlit_soul_torch" - } - ] + "i": "minecraft:iron_nugget", + "u": "totally_lit:unlit_soul_torch" }, "result": { "id": "totally_lit:unlit_soul_lantern" diff --git a/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern_from_water_bucket.json b/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern_from_water_bucket.json index 653cc04..247cfc1 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern_from_water_bucket.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_soul_lantern_from_water_bucket.json @@ -1,12 +1,8 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "minecraft:soul_lantern" - }, - { - "item": "minecraft:water_bucket" - } + "minecraft:soul_lantern", + "minecraft:water_bucket" ], "result": { "id": "totally_lit:unlit_soul_lantern" diff --git a/src/main/resources/data/totally_lit/recipe/unlit_soul_torch.json b/src/main/resources/data/totally_lit/recipe/unlit_soul_torch.json index 26caaaa..49b755a 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_soul_torch.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_soul_torch.json @@ -6,19 +6,9 @@ "S" ], "key": { - "#": [ - { - "tag": "c:coal" - } - ], - "|": { - "item": "minecraft:stick" - }, - "S": [ - { - "tag": "minecraft:soul_fire_base_blocks" - } - ] + "#": "#c:coal", + "|": "minecraft:stick", + "S": "#minecraft:soul_fire_base_blocks" }, "result": { "id": "totally_lit:unlit_soul_torch", diff --git a/src/main/resources/data/totally_lit/recipe/unlit_soul_torch_from_water_bucket.json b/src/main/resources/data/totally_lit/recipe/unlit_soul_torch_from_water_bucket.json index 8148a7c..7feb600 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_soul_torch_from_water_bucket.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_soul_torch_from_water_bucket.json @@ -1,12 +1,8 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "minecraft:soul_torch" - }, - { - "item": "minecraft:water_bucket" - } + "minecraft:soul_torch", + "minecraft:water_bucket" ], "result": { "id": "totally_lit:unlit_soul_torch" diff --git a/src/main/resources/data/totally_lit/recipe/unlit_torch.json b/src/main/resources/data/totally_lit/recipe/unlit_torch.json index 89037f2..2509168 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_torch.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_torch.json @@ -5,14 +5,8 @@ "|" ], "key": { - "#": [ - { - "tag": "c:coal" - } - ], - "|": { - "item": "minecraft:stick" - } + "#": "#c:coal", + "|": "minecraft:stick" }, "result": { "id": "totally_lit:unlit_torch", diff --git a/src/main/resources/data/totally_lit/recipe/unlit_torch_from_water_bucket.json b/src/main/resources/data/totally_lit/recipe/unlit_torch_from_water_bucket.json index 41205d0..f98635b 100644 --- a/src/main/resources/data/totally_lit/recipe/unlit_torch_from_water_bucket.json +++ b/src/main/resources/data/totally_lit/recipe/unlit_torch_from_water_bucket.json @@ -1,12 +1,8 @@ { "type": "minecraft:crafting_shapeless", "ingredients": [ - { - "item": "minecraft:torch" - }, - { - "item": "minecraft:water_bucket" - } + "minecraft:torch", + "minecraft:water_bucket" ], "result": { "id": "totally_lit:unlit_torch" diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index e0191f5..b542894 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -21,7 +21,7 @@ }, "depends": { "java": ">=21", - "minecraft": "1.21.1", + "minecraft": "1.21.3", "fabricloader": ">=0.15.0", "fabric-api": "*", "owo-lib": ">=0.12.0"