Skip to content

Commit

Permalink
fix texture
Browse files Browse the repository at this point in the history
  • Loading branch information
MEGATREX4 committed Jun 9, 2024
1 parent 753f34f commit 5e327c9
Show file tree
Hide file tree
Showing 9 changed files with 22 additions and 12 deletions.
Original file line number Diff line number Diff line change
@@ -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();
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,16 @@

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;
import net.minecraft.util.Identifier;

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);
Expand Down
5 changes: 0 additions & 5 deletions src/main/resources/assets/ukrainian-delight/lang/en_us.json

This file was deleted.

5 changes: 0 additions & 5 deletions src/main/resources/assets/ukrainian-delight/lang/uk_ua.json

This file was deleted.

5 changes: 5 additions & 0 deletions src/main/resources/assets/ukrainian_delight/lang/en_us.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"itemgroup.ukrainian_delight": "Ukrainian Delight",

"item.ukrainian_delight.varenyk": "Varenyk"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"parent": "item/generated",
"textures": {
"layer0": "ukrainian_delight:item/varenyk"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion src/main/resources/fabric.mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"sources": "https://github.com/FabricMC/fabric-example-mod"
},
"license": "CC0-1.0",
"icon": "assets/ukrainian-delight/icon.png",
"icon": "assets/ukrainian_delight/icon.png",
"environment": "*",
"entrypoints": {
"main": [
Expand Down

0 comments on commit 5e327c9

Please sign in to comment.