From 7c44126f9cc691db1d16c51ec42a2bd414036990 Mon Sep 17 00:00:00 2001 From: MCZME <13183052+mczme@user.noreply.gitee.com> Date: Fri, 13 Sep 2024 15:56:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=EF=BC=9A=E8=B1=86=EF=BC=8C?= =?UTF-8?q?=E8=B1=86=E8=8D=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../71e72dbdeb626cc835aaccd2ae47fd3d8794cd24 | 4 +- .../85f12f813aff948f91f5cd129c0ffa86bcb17361 | 4 +- .../9fb1092f32d4fcbf9e061ffd718d4ec689c6c95e | 9 ++-- .../resources/assets/lingshi/lang/zh_cn.json | 3 ++ .../assets/lingshi/models/item/bean.json | 6 +++ .../assets/lingshi/models/item/pod.json | 6 +++ .../advancement/recipes/misc/bean.json | 32 ++++++++++++ .../resources/data/lingshi/recipe/bean.json | 16 ++++++ .../lingshi/recipe/chopping_board/bean.json | 15 ++++++ .../recipe/chopping_board/sliced_beef.json | 2 +- .../recipe/chopping_board/sliced_pork.json | 2 +- .../mczme/lingshi/common/block/BeanBlock.java | 17 ++++++ .../lingshi/common/block/CabbageBlock.java | 1 + .../lingshi/common/block/PlateFoodBlock.java | 1 + .../mczme/lingshi/common/block/RiceBlock.java | 2 + .../lingshi/common/block/StewedNoodles.java | 1 + .../block/{ => baseblock}/FoodBlock.java | 2 +- .../block/{ => baseblock}/ModCropBlock.java | 2 +- .../lingshi/common/registry/ModBlocks.java | 3 ++ .../lingshi/common/registry/ModItems.java | 2 + .../java/mczme/lingshi/data/BlockStates.java | 2 +- .../java/mczme/lingshi/data/ItemModels.java | 2 + .../data/lang/ChineseLanguageProvider.java | 2 + .../recipe/ChoppingBoardRecipeDatagen.java | 1 + .../data/recipe/CraftingRecipeDataGen.java | 5 ++ .../assets/lingshi/blockstates/bean.json | 16 ++++++ .../assets/lingshi/models/block/bean_0.json | 7 +++ .../assets/lingshi/models/block/bean_1.json | 7 +++ .../assets/lingshi/models/block/bean_2.json | 7 +++ .../assets/lingshi/models/block/bean_3.json | 7 +++ .../lingshi/models/block/fried_fish.json | 2 +- .../assets/lingshi/textures/block/bean_0.png | Bin 0 -> 168 bytes .../assets/lingshi/textures/block/bean_1.png | Bin 0 -> 267 bytes .../assets/lingshi/textures/block/bean_2.png | Bin 0 -> 496 bytes .../assets/lingshi/textures/block/bean_3.png | Bin 0 -> 537 bytes .../lingshi/textures/block/fried_fish.png | Bin 582 -> 465 bytes .../assets/lingshi/textures/item/bean.png | Bin 0 -> 182 bytes .../lingshi/textures/item/fried_fish.png | Bin 385 -> 385 bytes .../assets/lingshi/textures/item/pod.png | Bin 0 -> 286 bytes .../data/lingshi/loot_table/blocks/bean.json | 49 ++++++++++++++++++ 40 files changed, 225 insertions(+), 12 deletions(-) create mode 100644 src/generated/resources/assets/lingshi/models/item/bean.json create mode 100644 src/generated/resources/assets/lingshi/models/item/pod.json create mode 100644 src/generated/resources/data/lingshi/advancement/recipes/misc/bean.json create mode 100644 src/generated/resources/data/lingshi/recipe/bean.json create mode 100644 src/generated/resources/data/lingshi/recipe/chopping_board/bean.json create mode 100644 src/main/java/mczme/lingshi/common/block/BeanBlock.java rename src/main/java/mczme/lingshi/common/block/{ => baseblock}/FoodBlock.java (98%) rename src/main/java/mczme/lingshi/common/block/{ => baseblock}/ModCropBlock.java (97%) create mode 100644 src/main/resources/assets/lingshi/blockstates/bean.json create mode 100644 src/main/resources/assets/lingshi/models/block/bean_0.json create mode 100644 src/main/resources/assets/lingshi/models/block/bean_1.json create mode 100644 src/main/resources/assets/lingshi/models/block/bean_2.json create mode 100644 src/main/resources/assets/lingshi/models/block/bean_3.json create mode 100644 src/main/resources/assets/lingshi/textures/block/bean_0.png create mode 100644 src/main/resources/assets/lingshi/textures/block/bean_1.png create mode 100644 src/main/resources/assets/lingshi/textures/block/bean_2.png create mode 100644 src/main/resources/assets/lingshi/textures/block/bean_3.png create mode 100644 src/main/resources/assets/lingshi/textures/item/bean.png create mode 100644 src/main/resources/assets/lingshi/textures/item/pod.png create mode 100644 src/main/resources/data/lingshi/loot_table/blocks/bean.json diff --git a/src/generated/resources/.cache/71e72dbdeb626cc835aaccd2ae47fd3d8794cd24 b/src/generated/resources/.cache/71e72dbdeb626cc835aaccd2ae47fd3d8794cd24 index ec39652..279df67 100644 --- a/src/generated/resources/.cache/71e72dbdeb626cc835aaccd2ae47fd3d8794cd24 +++ b/src/generated/resources/.cache/71e72dbdeb626cc835aaccd2ae47fd3d8794cd24 @@ -1,4 +1,5 @@ -// 1.21 2024-09-12T16:15:54.781192 Item Models: lingshi +// 1.21 2024-09-13T14:57:21.0680602 Item Models: lingshi +60ca0011c94253a1b7d4c3ca724eb58d73f18691 assets/lingshi/models/item/bean.json 14f86299910462582d98bcf699b35e34c615ee8e assets/lingshi/models/item/cabbage.json 0e18f939d46f6a164584f621fa97b024122785d9 assets/lingshi/models/item/cabbage_leaf.json 0bcbbc8c3377f7b20a37790cc33d36690c2044c7 assets/lingshi/models/item/cabbage_seed.json @@ -16,6 +17,7 @@ bb65673aded0d1674c4329547af6263f100a1e6b assets/lingshi/models/item/glass_jar.js 8889a4deb394774a900a518a3d4849db21da3370 assets/lingshi/models/item/noodles.json b767fc7952daf0eff3485fe4d8c06c5bba930c22 assets/lingshi/models/item/oil_bucket.json 8a787e79ccb05e02b90ea12cfed0a54b8fda4bf5 assets/lingshi/models/item/pig_feet.json +c5462fe0e65c55cb54c7245f1f4e2bbbafbdaf12 assets/lingshi/models/item/pod.json 9915c87a8e0b4628efc95f82b478e53d6d59e46f assets/lingshi/models/item/pork_feet_rice.json 496d711c2d4af0f851d40f859b102da69188089d assets/lingshi/models/item/rice.json abe8ae1523c26af167289fe958382b2477d96ea1 assets/lingshi/models/item/rice_of_ear.json diff --git a/src/generated/resources/.cache/85f12f813aff948f91f5cd129c0ffa86bcb17361 b/src/generated/resources/.cache/85f12f813aff948f91f5cd129c0ffa86bcb17361 index 5bd0df6..6bc1835 100644 --- a/src/generated/resources/.cache/85f12f813aff948f91f5cd129c0ffa86bcb17361 +++ b/src/generated/resources/.cache/85f12f813aff948f91f5cd129c0ffa86bcb17361 @@ -1,2 +1,2 @@ -// 1.21 2024-09-12T16:15:54.7871949 Languages: zh_cn for mod: lingshi -348c9b7804e49313430866cf2a4452af28e303b8 assets/lingshi/lang/zh_cn.json +// 1.21 2024-09-13T14:57:21.0710612 Languages: zh_cn for mod: lingshi +ce8c6009186af5edd4da6baae053ee5a9cd2fb5a assets/lingshi/lang/zh_cn.json diff --git a/src/generated/resources/.cache/9fb1092f32d4fcbf9e061ffd718d4ec689c6c95e b/src/generated/resources/.cache/9fb1092f32d4fcbf9e061ffd718d4ec689c6c95e index 0896d3c..81ff871 100644 --- a/src/generated/resources/.cache/9fb1092f32d4fcbf9e061ffd718d4ec689c6c95e +++ b/src/generated/resources/.cache/9fb1092f32d4fcbf9e061ffd718d4ec689c6c95e @@ -1,4 +1,4 @@ -// 1.21 2024-09-12T16:15:54.7831919 Recipes +// 1.21 2024-09-13T15:50:41.8886655 Recipes b8cb7428b718c0ca190af49165cd25554d27fa19 data/lingshi/advancement/recipes/cooking_pot/cooked_rice.json 7d0ef4cd02c38f4648e712a935f0ea32fb50aeff data/lingshi/advancement/recipes/cooking_pot/cooked_rice_1.json d918a2369d899974ffa38d6a363553af9e97fdee data/lingshi/advancement/recipes/cooking_pot/cooked_rice_2.json @@ -11,6 +11,7 @@ b324dfe8c51c5f2f94e08473d966192d14d40c5a data/lingshi/advancement/recipes/cookin 0486b842988b1d1ac0abb797a91d26077583679e data/lingshi/advancement/recipes/decorations/pot_lid.json 0a4b54bfda8aa98f1a26bbf1d8231c76ed12e770 data/lingshi/advancement/recipes/decorations/skillet.json 129f0de548d7a7b62ee9dcaeb54da65d7095a009 data/lingshi/advancement/recipes/decorations/stove.json +bb88842bdcc06e396f9884774adfe5f1291ac547 data/lingshi/advancement/recipes/misc/bean.json e4ccb4f32d90b93ef63a3f2a17e843c6a8b2322b data/lingshi/advancement/recipes/skillet/baked_potato.json c9b88b929d6f4b7d68c10c6a3915182cb096d363 data/lingshi/advancement/recipes/skillet/cooked_beef.json 0235c27183fa0a2f93fdf2a6726f2f9d1acc95b7 data/lingshi/advancement/recipes/skillet/cooked_chicken.json @@ -27,14 +28,16 @@ e241bb59f1e7d265a9afbd0f38efdc05d5b325eb data/lingshi/advancement/recipes/skille 47116fef6fadd5ebb9231aee1717b2830949e776 data/lingshi/advancement/recipes/skillet/stewed_noodles.json 0e940fa2ba82aed478ee367c4b998f0bc7ead5c3 data/lingshi/advancement/recipes/tools/iron_knife.json e511f76246f906a279fc1ec531922d8f70dfb68c data/lingshi/advancement/recipes/tools/spatula.json +c2ef322f776e7c9d28a7a5c300dae408b2c81b98 data/lingshi/recipe/bean.json bec1047337843fdd073fe87393c3b500ae11a1de data/lingshi/recipe/chopping_board.json +296eac908fe9bf9969c692bece480488e7d33676 data/lingshi/recipe/chopping_board/bean.json 85577ffce21473f6f122b7ef8a92eacaa2e5cfd2 data/lingshi/recipe/chopping_board/cabbage_leaf.json dbe74c08be4c49a28a0f8bf9dd1ec1825c557d55 data/lingshi/recipe/chopping_board/dough.json df6343e05449c8aded71e42701d18e37311ea0c9 data/lingshi/recipe/chopping_board/flour.json 771ae63028a23ade683357752f8152f0ebb2203b data/lingshi/recipe/chopping_board/noodles.json 3e41620c4ec5b19f87046dad7fe5c7ed6ede21c2 data/lingshi/recipe/chopping_board/rice.json -20eec978b731fd5911176390fca13d7107648c9e data/lingshi/recipe/chopping_board/sliced_beef.json -8abaaf136ecebe8470e08ffb36eece5b1bb28ca9 data/lingshi/recipe/chopping_board/sliced_pork.json +d5a3ea12f03dfc18cd8989daf7e626da171b5a88 data/lingshi/recipe/chopping_board/sliced_beef.json +0d173ef6637fabaa6aee42f311464c496c40b1ba data/lingshi/recipe/chopping_board/sliced_pork.json 2bca8f59bf6fc074377fc44b2331427a96aea5d4 data/lingshi/recipe/cooking_pot.json 2e23fcd215c647e72e989050fbfe466f419bed56 data/lingshi/recipe/cooking_pot/cooked_rice.json d0f1076aaf14e4191918a911196f1aeac7d7a59d data/lingshi/recipe/cooking_pot/cooked_rice_1.json diff --git a/src/generated/resources/assets/lingshi/lang/zh_cn.json b/src/generated/resources/assets/lingshi/lang/zh_cn.json index 74026db..232cfaa 100644 --- a/src/generated/resources/assets/lingshi/lang/zh_cn.json +++ b/src/generated/resources/assets/lingshi/lang/zh_cn.json @@ -1,4 +1,5 @@ { + "block.lingshi.bean": "豆", "block.lingshi.cabbage": "白菜种子", "block.lingshi.chopping_board": "砧板", "block.lingshi.cooking_pot": "烹饪锅", @@ -12,6 +13,7 @@ "block.lingshi.stewed_noodles": "煮面条", "block.lingshi.stove": "炉灶", "block.lingshi.tea_tree": "茶树", + "effect.lingshi.gratification_effect": "满足", "gui.lingshi.cooking_pot_menu": "烹饪锅", "gui.lingshi.skillet_menu": "平底锅", "item.lingshi.cabbage": "白菜", @@ -26,6 +28,7 @@ "item.lingshi.noodles": "面条", "item.lingshi.oil_bucket": "油桶", "item.lingshi.pig_feet": "猪蹄", + "item.lingshi.pod": "豆荚", "item.lingshi.pot_lid": "锅盖", "item.lingshi.rice_of_ear": "稻穗", "item.lingshi.sliced_beef": "切好的牛肉", diff --git a/src/generated/resources/assets/lingshi/models/item/bean.json b/src/generated/resources/assets/lingshi/models/item/bean.json new file mode 100644 index 0000000..e812e40 --- /dev/null +++ b/src/generated/resources/assets/lingshi/models/item/bean.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "lingshi:item/bean" + } +} \ No newline at end of file diff --git a/src/generated/resources/assets/lingshi/models/item/pod.json b/src/generated/resources/assets/lingshi/models/item/pod.json new file mode 100644 index 0000000..0e871cd --- /dev/null +++ b/src/generated/resources/assets/lingshi/models/item/pod.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "lingshi:item/pod" + } +} \ No newline at end of file diff --git a/src/generated/resources/data/lingshi/advancement/recipes/misc/bean.json b/src/generated/resources/data/lingshi/advancement/recipes/misc/bean.json new file mode 100644 index 0000000..4b90d84 --- /dev/null +++ b/src/generated/resources/data/lingshi/advancement/recipes/misc/bean.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_pod": { + "conditions": { + "items": [ + { + "items": "lingshi:pod" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "lingshi:bean" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_pod" + ] + ], + "rewards": { + "recipes": [ + "lingshi:bean" + ] + } +} \ No newline at end of file diff --git a/src/generated/resources/data/lingshi/recipe/bean.json b/src/generated/resources/data/lingshi/recipe/bean.json new file mode 100644 index 0000000..44a792a --- /dev/null +++ b/src/generated/resources/data/lingshi/recipe/bean.json @@ -0,0 +1,16 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "misc", + "key": { + "A": { + "item": "lingshi:pod" + } + }, + "pattern": [ + "A" + ], + "result": { + "count": 1, + "id": "lingshi:bean" + } +} \ No newline at end of file diff --git a/src/generated/resources/data/lingshi/recipe/chopping_board/bean.json b/src/generated/resources/data/lingshi/recipe/chopping_board/bean.json new file mode 100644 index 0000000..181c538 --- /dev/null +++ b/src/generated/resources/data/lingshi/recipe/chopping_board/bean.json @@ -0,0 +1,15 @@ +{ + "type": "lingshi:chopping_board", + "input": { + "item": "lingshi:pod" + }, + "result": [ + { + "count": 3, + "id": "lingshi:bean" + } + ], + "tool": { + "tag": "neoforge:knife" + } +} \ No newline at end of file diff --git a/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_beef.json b/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_beef.json index 8f0f5c4..9eee312 100644 --- a/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_beef.json +++ b/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_beef.json @@ -5,7 +5,7 @@ }, "result": [ { - "count": 1, + "count": 2, "id": "lingshi:sliced_beef" } ], diff --git a/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_pork.json b/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_pork.json index 8bdae3b..4e298bc 100644 --- a/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_pork.json +++ b/src/generated/resources/data/lingshi/recipe/chopping_board/sliced_pork.json @@ -5,7 +5,7 @@ }, "result": [ { - "count": 1, + "count": 2, "id": "lingshi:sliced_pork" } ], diff --git a/src/main/java/mczme/lingshi/common/block/BeanBlock.java b/src/main/java/mczme/lingshi/common/block/BeanBlock.java new file mode 100644 index 0000000..1f5aeb5 --- /dev/null +++ b/src/main/java/mczme/lingshi/common/block/BeanBlock.java @@ -0,0 +1,17 @@ +package mczme.lingshi.common.block; + +import mczme.lingshi.common.block.baseblock.ModCropBlock; +import mczme.lingshi.common.registry.ModItems; +import net.minecraft.world.level.ItemLike; +import org.jetbrains.annotations.NotNull; + +public class BeanBlock extends ModCropBlock { + public BeanBlock(Properties properties) { + super(properties); + } + + @Override + protected @NotNull ItemLike getBaseSeedId() { + return ModItems.BEAN.get(); + } +} diff --git a/src/main/java/mczme/lingshi/common/block/CabbageBlock.java b/src/main/java/mczme/lingshi/common/block/CabbageBlock.java index aec4110..6961e44 100644 --- a/src/main/java/mczme/lingshi/common/block/CabbageBlock.java +++ b/src/main/java/mczme/lingshi/common/block/CabbageBlock.java @@ -1,5 +1,6 @@ package mczme.lingshi.common.block; +import mczme.lingshi.common.block.baseblock.ModCropBlock; import mczme.lingshi.common.registry.ModItems; import net.minecraft.world.level.ItemLike; import org.jetbrains.annotations.NotNull; diff --git a/src/main/java/mczme/lingshi/common/block/PlateFoodBlock.java b/src/main/java/mczme/lingshi/common/block/PlateFoodBlock.java index 563d3ac..c84530d 100644 --- a/src/main/java/mczme/lingshi/common/block/PlateFoodBlock.java +++ b/src/main/java/mczme/lingshi/common/block/PlateFoodBlock.java @@ -1,5 +1,6 @@ package mczme.lingshi.common.block; +import mczme.lingshi.common.block.baseblock.FoodBlock; import net.minecraft.core.BlockPos; import net.minecraft.world.level.BlockGetter; import net.minecraft.world.level.block.Block; diff --git a/src/main/java/mczme/lingshi/common/block/RiceBlock.java b/src/main/java/mczme/lingshi/common/block/RiceBlock.java index 3747ff1..6eb7ea6 100644 --- a/src/main/java/mczme/lingshi/common/block/RiceBlock.java +++ b/src/main/java/mczme/lingshi/common/block/RiceBlock.java @@ -1,5 +1,7 @@ package mczme.lingshi.common.block; +import mczme.lingshi.common.block.baseblock.ModCropBlock; + public class RiceBlock extends ModCropBlock { public RiceBlock(Properties properties) { super(properties); diff --git a/src/main/java/mczme/lingshi/common/block/StewedNoodles.java b/src/main/java/mczme/lingshi/common/block/StewedNoodles.java index f7d2bf5..82f50c0 100644 --- a/src/main/java/mczme/lingshi/common/block/StewedNoodles.java +++ b/src/main/java/mczme/lingshi/common/block/StewedNoodles.java @@ -1,5 +1,6 @@ package mczme.lingshi.common.block; +import mczme.lingshi.common.block.baseblock.FoodBlock; import mczme.lingshi.common.registry.ModEffects; import mczme.lingshi.common.registry.ModItems; import net.minecraft.core.BlockPos; diff --git a/src/main/java/mczme/lingshi/common/block/FoodBlock.java b/src/main/java/mczme/lingshi/common/block/baseblock/FoodBlock.java similarity index 98% rename from src/main/java/mczme/lingshi/common/block/FoodBlock.java rename to src/main/java/mczme/lingshi/common/block/baseblock/FoodBlock.java index ab56957..145bf00 100644 --- a/src/main/java/mczme/lingshi/common/block/FoodBlock.java +++ b/src/main/java/mczme/lingshi/common/block/baseblock/FoodBlock.java @@ -1,4 +1,4 @@ -package mczme.lingshi.common.block; +package mczme.lingshi.common.block.baseblock; import mczme.lingshi.common.registry.ModEffects; import net.minecraft.core.BlockPos; diff --git a/src/main/java/mczme/lingshi/common/block/ModCropBlock.java b/src/main/java/mczme/lingshi/common/block/baseblock/ModCropBlock.java similarity index 97% rename from src/main/java/mczme/lingshi/common/block/ModCropBlock.java rename to src/main/java/mczme/lingshi/common/block/baseblock/ModCropBlock.java index 403ef45..702fe93 100644 --- a/src/main/java/mczme/lingshi/common/block/ModCropBlock.java +++ b/src/main/java/mczme/lingshi/common/block/baseblock/ModCropBlock.java @@ -1,4 +1,4 @@ -package mczme.lingshi.common.block; +package mczme.lingshi.common.block.baseblock; import mczme.lingshi.common.registry.ModItems; import net.minecraft.core.BlockPos; diff --git a/src/main/java/mczme/lingshi/common/registry/ModBlocks.java b/src/main/java/mczme/lingshi/common/registry/ModBlocks.java index 470f8d6..ef27d72 100644 --- a/src/main/java/mczme/lingshi/common/registry/ModBlocks.java +++ b/src/main/java/mczme/lingshi/common/registry/ModBlocks.java @@ -1,6 +1,7 @@ package mczme.lingshi.common.registry; import mczme.lingshi.common.block.*; +import mczme.lingshi.common.block.baseblock.FoodBlock; import mczme.lingshi.common.fluid.OilBlock; import mczme.lingshi.lingshi; import net.minecraft.world.level.block.Blocks; @@ -27,6 +28,8 @@ public class ModBlocks { BlockBehaviour.Properties.of().noCollission().mapColor(MapColor.PLANT).instabreak().sound(SoundType.CROP).pushReaction(PushReaction.DESTROY).randomTicks()); public static final Supplier CABBAGE = BLOCKS.registerBlock("cabbage", CabbageBlock::new, BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).noCollission().randomTicks().instabreak().sound(SoundType.CROP).pushReaction(PushReaction.DESTROY)); + public static final Supplier BEAN = BLOCKS.registerBlock("bean", BeanBlock::new, + BlockBehaviour.Properties.of().mapColor(MapColor.PLANT).noCollission().randomTicks().instabreak().sound(SoundType.CROP).pushReaction(PushReaction.DESTROY)); public static final Supplier TEA_TREE = BLOCKS.registerBlock("tea_tree", TeaTreeBlock::new, BlockBehaviour.Properties.of().randomTicks().mapColor(MapColor.PLANT).noCollission().instabreak().sound(SoundType.CROP).pushReaction(PushReaction.DESTROY)); diff --git a/src/main/java/mczme/lingshi/common/registry/ModItems.java b/src/main/java/mczme/lingshi/common/registry/ModItems.java index db79639..cce6a5f 100644 --- a/src/main/java/mczme/lingshi/common/registry/ModItems.java +++ b/src/main/java/mczme/lingshi/common/registry/ModItems.java @@ -24,6 +24,8 @@ public class ModItems { public static final Supplier RICE_SEEDLING = registerWithCreateTab("rice_seedling", () -> new BlockItem(ModBlocks.RICE_SEEDLING.get(), new Item.Properties())); public static final Supplier RICE_OF_EAR = registerWithCreateTab("rice_of_ear", () -> new Item(new Item.Properties())); public static final Supplier CABBAGE_SEED = registerWithCreateTab("cabbage_seed", () -> new BlockItem(ModBlocks.CABBAGE.get(), new Item.Properties())); + public static final Supplier BEAN = registerWithCreateTab("bean", () -> new BlockItem(ModBlocks.BEAN.get(), new Item.Properties())); + public static final Supplier POD = registerWithCreateTab("pod", () -> new Item(new Item.Properties())); public static final Supplier CABBAGE = registerWithCreateTab("cabbage", () -> new Item(new Item.Properties().food(new FoodProperties.Builder() .nutrition(3).saturationModifier(2.4f).build()))); public static final Supplier CABBAGE_LEAF = registerWithCreateTab("cabbage_leaf", () -> new Item(new Item.Properties().food(new FoodProperties.Builder() diff --git a/src/main/java/mczme/lingshi/data/BlockStates.java b/src/main/java/mczme/lingshi/data/BlockStates.java index a1e7da1..b931e3f 100644 --- a/src/main/java/mczme/lingshi/data/BlockStates.java +++ b/src/main/java/mczme/lingshi/data/BlockStates.java @@ -12,7 +12,7 @@ import net.neoforged.neoforge.client.model.generators.VariantBlockStateBuilder; import net.neoforged.neoforge.common.data.ExistingFileHelper; -import static mczme.lingshi.common.block.FoodBlock.AMOUNT; +import static mczme.lingshi.common.block.baseblock.FoodBlock.AMOUNT; public class BlockStates extends BlockStateProvider { diff --git a/src/main/java/mczme/lingshi/data/ItemModels.java b/src/main/java/mczme/lingshi/data/ItemModels.java index 3bcbc7c..4d1e8af 100644 --- a/src/main/java/mczme/lingshi/data/ItemModels.java +++ b/src/main/java/mczme/lingshi/data/ItemModels.java @@ -19,6 +19,8 @@ protected void registerModels() { basicItem(ModItems.CABBAGE_SEED.get()); basicItem(ModItems.CABBAGE.get()); basicItem(ModItems.CABBAGE_LEAF.get()); + basicItem(ModItems.BEAN.get()); + basicItem(ModItems.POD.get()); basicItem(ModItems.PORK_FEET_RICE.get()); basicItem(ModItems.SAUTEED_SEASONAL_VEGETABLE.get()); basicItem(ModItems.STEWED_NOODLES.get()); diff --git a/src/main/java/mczme/lingshi/data/lang/ChineseLanguageProvider.java b/src/main/java/mczme/lingshi/data/lang/ChineseLanguageProvider.java index 5d8ac6e..1f5e088 100644 --- a/src/main/java/mczme/lingshi/data/lang/ChineseLanguageProvider.java +++ b/src/main/java/mczme/lingshi/data/lang/ChineseLanguageProvider.java @@ -22,6 +22,8 @@ protected void addTranslations() { this.add(ModItems.CABBAGE_SEED.get(), "白菜种子"); this.add(ModItems.CABBAGE.get(), "白菜"); this.add(ModItems.CABBAGE_LEAF.get(), "白菜叶"); + this.add(ModItems.BEAN.get(), "豆"); + this.add(ModItems.POD.get(), "豆荚"); this.add(ModItems.TEA_TREE.get(), "茶树"); this.add(ModItems.TEA_LEAF.get(), "茶叶"); diff --git a/src/main/java/mczme/lingshi/data/recipe/ChoppingBoardRecipeDatagen.java b/src/main/java/mczme/lingshi/data/recipe/ChoppingBoardRecipeDatagen.java index ee94044..4faa80c 100644 --- a/src/main/java/mczme/lingshi/data/recipe/ChoppingBoardRecipeDatagen.java +++ b/src/main/java/mczme/lingshi/data/recipe/ChoppingBoardRecipeDatagen.java @@ -23,6 +23,7 @@ protected void buildRecipes(RecipeOutput output) { build(List.of(new ItemStack(ModItems.CABBAGE_LEAF.get(),3)),Ingredient.of(NeoforgeTags.KNIFE),Ingredient.of(ModItems.CABBAGE.get()),output,"cabbage_leaf"); build(List.of(new ItemStack(ModItems.SLICED_PORK.get(),2)),Ingredient.of(NeoforgeTags.KNIFE),Ingredient.of(Items.PORKCHOP),output,"sliced_pork"); build(List.of(new ItemStack(ModItems.SLICED_BEEF.get(),2)),Ingredient.of(NeoforgeTags.KNIFE),Ingredient.of(Items.BEEF),output,"sliced_beef"); + build(List.of(new ItemStack(ModItems.BEAN.get(),3)),Ingredient.of(NeoforgeTags.KNIFE),Ingredient.of(ModItems.POD.get()),output,"bean"); } diff --git a/src/main/java/mczme/lingshi/data/recipe/CraftingRecipeDataGen.java b/src/main/java/mczme/lingshi/data/recipe/CraftingRecipeDataGen.java index ea3b2e2..6c1e0e8 100644 --- a/src/main/java/mczme/lingshi/data/recipe/CraftingRecipeDataGen.java +++ b/src/main/java/mczme/lingshi/data/recipe/CraftingRecipeDataGen.java @@ -76,6 +76,11 @@ protected void buildRecipes(RecipeOutput output) { .define('A', ItemTags.WOODEN_SLABS) .unlockedBy("has_glass_panes", has(Tags.Items.GLASS_PANES)) .save(output); + ShapedRecipeBuilder.shaped(RecipeCategory.FOOD, ModItems.BEAN.get()) + .pattern("A") + .define('A', ModItems.POD.get()) + .unlockedBy("has_pod", has(ModItems.POD.get())) + .save(output); } } diff --git a/src/main/resources/assets/lingshi/blockstates/bean.json b/src/main/resources/assets/lingshi/blockstates/bean.json new file mode 100644 index 0000000..d37ee9b --- /dev/null +++ b/src/main/resources/assets/lingshi/blockstates/bean.json @@ -0,0 +1,16 @@ +{ + "variants": { + "age=0": { + "model": "lingshi:block/bean_0" + }, + "age=1": { + "model": "lingshi:block/bean_1" + }, + "age=2": { + "model": "lingshi:block/bean_2" + }, + "age=3": { + "model": "lingshi:block/bean_3" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/lingshi/models/block/bean_0.json b/src/main/resources/assets/lingshi/models/block/bean_0.json new file mode 100644 index 0000000..c1d46d5 --- /dev/null +++ b/src/main/resources/assets/lingshi/models/block/bean_0.json @@ -0,0 +1,7 @@ +{ + "parent": "lingshi:block/cabbage_crop", + "render_type": "minecraft:cutout", + "textures": { + "crop": "lingshi:block/bean_0" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/lingshi/models/block/bean_1.json b/src/main/resources/assets/lingshi/models/block/bean_1.json new file mode 100644 index 0000000..11e5d5b --- /dev/null +++ b/src/main/resources/assets/lingshi/models/block/bean_1.json @@ -0,0 +1,7 @@ +{ + "parent": "lingshi:block/cabbage_crop", + "render_type": "minecraft:cutout", + "textures": { + "crop": "lingshi:block/bean_1" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/lingshi/models/block/bean_2.json b/src/main/resources/assets/lingshi/models/block/bean_2.json new file mode 100644 index 0000000..4e7701d --- /dev/null +++ b/src/main/resources/assets/lingshi/models/block/bean_2.json @@ -0,0 +1,7 @@ +{ + "parent": "lingshi:block/cabbage_crop", + "render_type": "minecraft:cutout", + "textures": { + "crop": "lingshi:block/bean_2" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/lingshi/models/block/bean_3.json b/src/main/resources/assets/lingshi/models/block/bean_3.json new file mode 100644 index 0000000..485ee8b --- /dev/null +++ b/src/main/resources/assets/lingshi/models/block/bean_3.json @@ -0,0 +1,7 @@ +{ + "parent": "lingshi:block/cabbage_crop", + "render_type": "minecraft:cutout", + "textures": { + "crop": "lingshi:block/bean_3" + } +} \ No newline at end of file diff --git a/src/main/resources/assets/lingshi/models/block/fried_fish.json b/src/main/resources/assets/lingshi/models/block/fried_fish.json index f448e5e..50d00ce 100644 --- a/src/main/resources/assets/lingshi/models/block/fried_fish.json +++ b/src/main/resources/assets/lingshi/models/block/fried_fish.json @@ -67,7 +67,7 @@ } }, { - "from": [2, 1.2, 3], + "from": [2, 1.2, 2], "to": [14, 1.2, 14], "rotation": {"angle": 0, "axis": "y", "origin": [3, 1, 3]}, "faces": { diff --git a/src/main/resources/assets/lingshi/textures/block/bean_0.png b/src/main/resources/assets/lingshi/textures/block/bean_0.png new file mode 100644 index 0000000000000000000000000000000000000000..bb0060d07b031ec8c61e8543419cdc98dd31c47d GIT binary patch literal 168 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%``JOJ0Ar`&K2@q`iIXh4<_KCsY(YW_=lFcs}Uxs}czYhMlK1O)eyb RwgRnY@O1TaS?83{1OV^VK-T~O literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/lingshi/textures/block/bean_1.png b/src/main/resources/assets/lingshi/textures/block/bean_1.png new file mode 100644 index 0000000000000000000000000000000000000000..465a7234c725c7c4c97dff246fa7822765a6bb01 GIT binary patch literal 267 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`mpok@Lo9le6C_xj1yt64`}6)< z&X4&El#)!16N7&|ImW$1F;7>3mvQpifA%{+HYJ9?t#oT*d$Y>+JV?^QK4H_<|GYbo zOKjZ9x0=zwIbqvjlmCDIbw9k@AFk2%z@(wEvGL*a?eQ9ansdV?@5lc?*zm^6P3M=y zq_FCL^+k_a51)T8zXE>D>aL P?-)E?{an^LB{Ts5u>^WF literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/lingshi/textures/block/bean_2.png b/src/main/resources/assets/lingshi/textures/block/bean_2.png new file mode 100644 index 0000000000000000000000000000000000000000..ca9190518d42fbb8b0d9b1bba7df3eae59a318a7 GIT binary patch literal 496 zcmVLr$B`oI1n;*61NjFNg-0#(9s4u87hd2f-Vl>hE4^i zE*2t)QjiOn!6A}A$K}rj?=D`_*FkzDxg?X%_I=;;KHvMi?*sn>>AelfzSblNz+wXxrp-i;fZqD{)&5z{hRM`Y!}}dvs2uf zs)tWiIX)?#T8*VkvoUFmmOr z)T>Q~?jHbFV^P+Vw}at^W-wda@!IsQL2%c%26Vjk+?a<1>eVJ)!wYup^?WL&n$k5q m>ec2lH({iA6O!ItK7+r1kly%OD{)K!00004Qju8bky^9y~+@0}md9hC(L~gFy!m9qQ0Q zgd9W?Ovp|XvSGMc?4Z@>wmvM~aBju=cd+kk-@dP)=k`7?&;Nb?&-=iCU}RR8!LeRx zTlxruQy!04COc$5|X(oT>zqquxOExJbZpjEH{lV z{ayo(pY6uz?6KEL#|@Pq+7)Y+uOBMT44Tn@7gtzc zD%iV46JfbJo>aFlT_6x>!3q)}zq!lw{DN0>e_&fpgk@-=&sD5Oc>aQgWI97_Q@A*J zM!XtIa}%3!?#@X8Pyyjse>)w4ZXR8K;n4ik0l;3VMk#(U$jx zxn$S!0K+|2Sa1%MVHh6^a*f%(HkG}qprqIXKvVD&)=q>!fB$iHc0tF;1ertvYbSy) z5M+Px3rAL(o`2CL1Hc1NUH69WsZ{_juQT`pLF(W2;;krU|NAu0s;ck>g2Y#TkUT!6 zbs&^=;CXl)E)SEwxh1~2#`d?*RQi21_n4^2%lhOfCkJs}H?-3-IF8qA@N4YDeK(=5 z8il%Q^mF*V&eOZv_}cGUT4cIUM|*4fy)YyIPjgEn4KcNEDJp--*8B`-CkbYTIvqty iUp(jXIzuXz0^kl8-U*1)*l~^k0000xR6On{|asesL4~s}bzE6*cNJ8euntxZ~F%gLg8%ziBn~dZ3`AI&Bpyi5q`=2SR6b>KT$Avqu0Do92E#vn2IezXE*7`b<(E+wJ zHsbdANsl~bF7pG=)zF3+0H0q5DVG0|emBa8hxc$ayXo)-5VMsxxBJOXrD diff --git a/src/main/resources/assets/lingshi/textures/item/bean.png b/src/main/resources/assets/lingshi/textures/item/bean.png new file mode 100644 index 0000000000000000000000000000000000000000..ec82a70d37a0877599cbcecd29111d0399e53920 GIT binary patch literal 182 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`wVp1HAr`&K2@y*|wX1UgC<>gJ}$#9{ukx|M&mzFBRt5fwIac&m|`$B>X5{_wxVO zQpt#?8?+9kOZdF~f86@vCmkLh9*uK{pIwiCKI`A+u35$gr*;|NtNqa9IP;-O9D8EJ h>(@pfc4c)iGc-L831!&Uwi)OU22WQ%mvv4FO#t{~P;>wQ literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/lingshi/textures/item/fried_fish.png b/src/main/resources/assets/lingshi/textures/item/fried_fish.png index 40c81cd462887c76c47b6642a5b7e008b88d96f6..f2de92f698392f6a3b3b1274671c4e63b3122193 100644 GIT binary patch delta 349 zcmV-j0iyna1AzmOEq_la!*LkKKR@j|8%m0UG{3E+R?Doml9YC(Z0$(9%)!czySO+K zM+XP4#szT|W#yvn;H0c3Qu1$;$Y#IU>%j8w;wI&}y>HL^^!9n+U%xNy>tb^vC;-;x zCRD8zfAa#=d>mHdLjn+(-k@-Ei#HOb!yf`5y?+pu^g>i57nW}UZe596 zS8|`f!{%(|Xf4j8QQ>qw!Q1^Ka#lvC-9~V{p80q{^1 vvX^D;6WMA|jrPvgC<`B5)x#gQ{1@~BqfT^v7zCmb00000NkvXXu0mjf*3hPB delta 349 zcmV-j0iyna1AzmOEq^^oLID(ozbC%b3L>Z>!k$6|LS%wML=dh8DUOAU4GB5Av@{kq zHaOIpwN%s^1qCgULsO7o6hZW-5s8}5ybUH-VL6U+m2I1;EnQ zifXc;zvfX*7QB&Iofp7RJFG{?1i&}HP5$u-cPLD^Hvm9lIe#pP<*-OPD0Kl&O%+K8 z=4vZW?(7J6C`{*|k8Hlk;i`(ri8wV?0F*vWm0qop_~9OK!OCQe z)XhCpbBh328jPe*56}V=0PHW!(q*&JJ34^J6GU;@jq+AjsD|hdDb#j_-Hjxf;}Z%+ z9dm< diff --git a/src/main/resources/assets/lingshi/textures/item/pod.png b/src/main/resources/assets/lingshi/textures/item/pod.png new file mode 100644 index 0000000000000000000000000000000000000000..756294fb741244930f78b1083cc963d816136de8 GIT binary patch literal 286 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`Pd!~6Lo9le6C@@jTz~cCe@gZ} zyTg*M#@w2-)YtU=*gv6>)3t|ld6tR6+ki*)ZmEiG@%QrJPLO