premium banner
A library mod for Farmer's Delight to create add-ons easily with a few lines of code.

Description

Delight Lib

A utility library for Farmer's Delight add-on developers that makes it a lot easier to create food items, knives, crates and bags, cabinets, and manage recipes. This means developers can make their own add-ons much quicker and only worry about the textures and models.

Getting Started | Create your own Farmer's Delight add-on for beginners

Watch Me on YouTube Watch Me on Twitch Support Me Button Donate Button

✨ Features:

Delight Lib allows the creation of these items and blocks for Farmer's Delight using just a few lines of code:

  • Food Items
  • Placeable food items
  • Cabinets
  • Crates and bags
  • Knives
  • Crops

🛠️ Code Examples

Below are minimal examples showing the library syntax. Read the documentation for full tutorials on building a complete add-on from scratch.

Creative Tab

Initialize your add-on and create a creative tab with a custom item icon:

var DelightLib = DelightAddon.create("Mod Name", bus)
            .withCreativeTab("Mod Name", () -> new ItemStack(Items.BREAD));

Knives

Register a knife:

addon.knife("obsidian_knife", Tiers.DIAMOND).build();

Food Items

Register a food item:

addon.food("fried_egg").nutrition(4).saturation(0.4f).fast().build();

Cooking Pot Recipes

Register a cooking pot recipe with custom ingredients:

addon.cookingRecipe("beef_stew")
    .addIngredient("minecraft:cooked_beef")
    .addIngredient("minecraft:carrot")
    .addIngredient("minecraft:potato")
    .result("mymod:beef_stew")
    .experience(1.0f)
    .cookingTime(200)
    .recipeBookTab("meals")
  .build();

Cabinets

Register a cabinet:

addon.cabinet("pine_cabinet").build();

Crops

Register a full crop system:

addon.crop("garlic").build();