From 5e327c9c325e6ea2ec02186382dc653371a4b043 Mon Sep 17 00:00:00 2001 From: Eugene <59817721+SKZGx@users.noreply.github.com> Date: Sun, 9 Jun 2024 10:21:50 +0300 Subject: [PATCH] fix texture --- .../ukrainian_dlight/item/ModFoodComponents.java | 7 +++++++ .../ukrainian_dlight/item/ModItems.java | 4 +++- .../assets/ukrainian-delight/lang/en_us.json | 5 ----- .../assets/ukrainian-delight/lang/uk_ua.json | 5 ----- .../icon.png | Bin .../assets/ukrainian_delight/lang/en_us.json | 5 +++++ .../ukrainian_delight/models/item/varenyk.json | 6 ++++++ .../ukrainian_delight/textures/item/varenyk.png | Bin 0 -> 1886 bytes src/main/resources/fabric.mod.json | 2 +- 9 files changed, 22 insertions(+), 12 deletions(-) create mode 100644 src/main/java/com/megatrex4/ukrainian_dlight/item/ModFoodComponents.java delete mode 100644 src/main/resources/assets/ukrainian-delight/lang/en_us.json delete mode 100644 src/main/resources/assets/ukrainian-delight/lang/uk_ua.json rename src/main/resources/assets/{ukrainian-delight => ukrainian_delight}/icon.png (100%) create mode 100644 src/main/resources/assets/ukrainian_delight/lang/en_us.json create mode 100644 src/main/resources/assets/ukrainian_delight/models/item/varenyk.json create mode 100644 src/main/resources/assets/ukrainian_delight/textures/item/varenyk.png diff --git a/src/main/java/com/megatrex4/ukrainian_dlight/item/ModFoodComponents.java b/src/main/java/com/megatrex4/ukrainian_dlight/item/ModFoodComponents.java new file mode 100644 index 0000000..3437a25 --- /dev/null +++ b/src/main/java/com/megatrex4/ukrainian_dlight/item/ModFoodComponents.java @@ -0,0 +1,7 @@ +package com.megatrex4.ukrainian_dlight.item; + +import net.minecraft.item.FoodComponent; + +public class ModFoodComponents { + public static final FoodComponent VARENYK = new FoodComponent.Builder().hunger(3).saturationModifier(0.25f).snack().build(); +} diff --git a/src/main/java/com/megatrex4/ukrainian_dlight/item/ModItems.java b/src/main/java/com/megatrex4/ukrainian_dlight/item/ModItems.java index 8a2f46c..09bf029 100644 --- a/src/main/java/com/megatrex4/ukrainian_dlight/item/ModItems.java +++ b/src/main/java/com/megatrex4/ukrainian_dlight/item/ModItems.java @@ -2,6 +2,8 @@ import com.megatrex4.ukrainian_dlight.UkrainianDelight; import net.fabricmc.fabric.api.item.v1.FabricItemSettings; +import net.minecraft.item.FoodComponent; +import net.minecraft.item.FoodComponents; import net.minecraft.item.Item; import net.minecraft.registry.Registries; import net.minecraft.registry.Registry; @@ -9,7 +11,7 @@ public class ModItems { - public static final Item VARENYK = registerItem("Varenyk", new Item(new FabricItemSettings())); + public static final Item VARENYK = registerItem("Varenyk", new Item(new FabricItemSettings().food(ModFoodComponents.VARENYK))); public static Item registerItem(String name, Item item){ return Registry.register(Registries.ITEM, new Identifier(UkrainianDelight.MOD_ID, name.toLowerCase()), item); diff --git a/src/main/resources/assets/ukrainian-delight/lang/en_us.json b/src/main/resources/assets/ukrainian-delight/lang/en_us.json deleted file mode 100644 index edaf92a..0000000 --- a/src/main/resources/assets/ukrainian-delight/lang/en_us.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "item.ukrainian_delight.varenyk": "Varenyk", - - "itemgroup.ukrainian_delight": "Ukrainian Delight" -} \ No newline at end of file diff --git a/src/main/resources/assets/ukrainian-delight/lang/uk_ua.json b/src/main/resources/assets/ukrainian-delight/lang/uk_ua.json deleted file mode 100644 index ba7f1d0..0000000 --- a/src/main/resources/assets/ukrainian-delight/lang/uk_ua.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "item.ukrainian_delight.varenyk": "Вареник", - - "itemgroup.ukrainian_delight": "Українська насолода" -} \ No newline at end of file diff --git a/src/main/resources/assets/ukrainian-delight/icon.png b/src/main/resources/assets/ukrainian_delight/icon.png similarity index 100% rename from src/main/resources/assets/ukrainian-delight/icon.png rename to src/main/resources/assets/ukrainian_delight/icon.png diff --git a/src/main/resources/assets/ukrainian_delight/lang/en_us.json b/src/main/resources/assets/ukrainian_delight/lang/en_us.json new file mode 100644 index 0000000..bdd94e3 --- /dev/null +++ b/src/main/resources/assets/ukrainian_delight/lang/en_us.json @@ -0,0 +1,5 @@ +{ + "itemgroup.ukrainian_delight": "Ukrainian Delight", + + "item.ukrainian_delight.varenyk": "Varenyk" +} \ No newline at end of file diff --git a/src/main/resources/assets/ukrainian_delight/models/item/varenyk.json b/src/main/resources/assets/ukrainian_delight/models/item/varenyk.json new file mode 100644 index 0000000..c296ddf --- /dev/null +++ b/src/main/resources/assets/ukrainian_delight/models/item/varenyk.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "ukrainian_delight:item/varenyk" + } +} diff --git a/src/main/resources/assets/ukrainian_delight/textures/item/varenyk.png b/src/main/resources/assets/ukrainian_delight/textures/item/varenyk.png new file mode 100644 index 0000000000000000000000000000000000000000..f74a0da6b4874deca2bcbd8f1b923396f3d0f402 GIT binary patch literal 1886 zcmbVNe{9rb819sjIa!1OhCs}kj*X42*WPuvYda1c>&eD;b8dreaKZK3Z(DPBZD~91 zjx8#SX9VIOLZ*ude=HDCh%N@QDS^cwfhnN3Wx+)godmNXL=B)4RP^ipazhM}Chhn2 z>+?PD`@HY_z1>+?yDlqpX(oaoSyh!>Jsjtocg9@!%(?Lw4~Iw8$`&0#9$jeOX~-LI zEK>!#$8VdMjoeep$7%vOw<}!hyF^J)FV&$em zwAo#URwx=k8H*JcNYaWr7zqi~XD?WHW`Kob`R&1qsAThBd} zFb3b8SchS#EI|Z=K}(RbC|WyVWf+DaZG_E+LjV-2l0FF0+6N6bR!O2pbWEx2;YqPQ?_9BvE zNiq&~E27jEz9-bi+UQwOSTiDT@b?9a0^6o&0UipL0(?6lRJk2PQ(1Lz&@!`D|mYRNRsL+z?Y1Js2H`z8^h_Zsau}hkX`Ek4E1ceJy%C`oZW6(V@|v z=xK;7FS|?oKZ0iSaI9y84m924+OW=5>+--F^cjlknZ-W{jSfTZ9dJCA;E#pS?PjZF z-QZ;bRB=uWCd?v9B3lAVg;FnY;FQBo;uKXP;0!5RanV6rMTRGN8ZgQIoFa6ZW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