Food API
🟡 Updated this year⚠️ Install Order · 2 steps
Install in this order, then this mod last — most mods fail to load without their framework and dependencies in place.
🖼️ Gallery (2 images)
🔍 Analysis
- 🏆 #21 of 50 food mods in this game by downloads
📋 About This Mod
<div align="center"> <img src="https://raw.githubusercontent.com/ArimoV2/Food_API/master/src/main/resources/assets/line_pink.png" width="100%"/> # 🍖 Food API ### A flexible hunger system library for NeoForge (https://img.shields.io/badge/MODRINTH-pink?style=for-the-badge&logo=modrinth&logoColor=white&labelColor=gray)](https://modrinth.com/user/Arimo) (https://img.shields.io/badge/GITHUB-pink?style=for-the-badge&logo=github&logoColor=white&labelColor=gray)](https://github.com/ArimoV2) <img src="https://raw.githubusercontent.com/ArimoV2/Food_API/master/src/main/resources/assets/line_pink.png" width="100%"/> </div> ## 📖 About **Food API** is a developer-focused library that removes the hardcoded limitations of Minecraft's vanilla hunger system. It exposes hunger capacity and drain speed as proper entity attributes, adds multi-row food bar rendering, and provides a clean provider-based system for replacing food icons — all with optional compatibility for popular HUD mods. <div align="center"> <img src="https://raw.githubusercontent.com/ArimoV2/Food_API/master/src/main/resources/assets/line_pink.png" width="100%"/> </div> ## ✨ Features ▶ **Dynamic hunger capacity** — max hunger is now an attribute, supports up to 2 rows (40 units). ▶ **Configurable drain speed** — control how fast hunger depletes via a multiplier attribute. ▶ **Multi-row food bar** — second row renders seamlessly above the first, fully synced with vanilla shake animation. ▶ **Icon provider system** — replace any food icon (empty, half, full, hunger, overlay, saturation) per-player, per-row, per-slot with a simple registration API. ▶ **Optional mod compat** — native support for (https://modrinth.com/mod/overflowing-bars) and (https://modrinth.com/mod/appleskin) when present. <div align="center"> <img src="https://raw.githubusercontent.com/ArimoV2/Food_API/master/src/main/resources/assets/line_pink.png" width="100%"/> </div> ## 🖼️ Screenshots <div align="center"> **Vanilla rendering** — single row, standard icons <img src="https://cdn.modrinth.com/data/gsm2zrxL/images/4f1ab8e03eedc1e9e5091e0bc2a0801900e134a9.png" width="600" style="border-radius:12px"/> <br/><br/> **With Overflowing Bars** — row counter, overlay icons stacked on top <img src="https://cdn.modrinth.com/data/gsm2zrxL/images/f31e731e85fda7ef4b9ff3fd8d2ab693f02666a1.png" width="600" style="border-radius:12px"/> </div> <div align="center"> <img src="https://raw.githubusercontent.com/ArimoV2/Food_API/master/src/main/resources/assets/line_pink.png" width="100%"/> </div> ## 📦 New Attributes Two new player attributes are registered automatically when Food API is loaded: | Attribute | ID | Default | Range | Description | |---|---|---|---|---| | Max Hunger | `food_api:max_hunger` | `20` | `1 – 40` | Maximum hunger capacity. 20 = one row, 40 = two rows. | | Hunger Rate | `food_api:hunger_rate` | `1.0` | `0.0 – 10.0` | Hunger drain speed multiplier. `0` = no drain, `2` = twice as fast. | Both attributes are **synced to the client** and can be modified via commands, other mods, or directly in code: ```java // Example: give a player double hunger capacity player.getAttribute(AttributeRegistries.MAX_HUNGER) .setBaseValue(40); // Example: slow hunger drain to half speed player.getAttribute(AttributeRegistries.HUNGER_RATE) .setBaseValue(0.5); ``` <div align="center"> <img src="https://raw.githubusercontent.com/ArimoV2/Food_API/master/src/main/resources/assets/line_pink.png" width="100%"/> </div> ## 🔧 API Usage ### Replacing food icons Register a provider with an ID and priority. Higher priority wins. Return `null` to fall through to the next provider. ```java FoodIconRegistry.register( ResourceLocation.fromNamespaceAndPath("mymod", "my_provider"), 10, // priority — higher = checked first (vanilla = 0) (player, iconIndex, row, type) -> { // iconIndex: 0 = rightmost icon, 9 = leftmost // row: 0 = bottom row, 1 = top row return switch (type) { case FULL -> ResourceLocation.fromNamespaceAndPath("mymod", "hud/my_food_full"); case HALF -> ResourceLocation.fromNamespaceAndPath("mymod", "hud/my_food_half"); case EMPTY -> ResourceLocation.fromNamespaceAndPath("mymod", "hud/my_food_empty"); default -> null; // let other providers or vanilla handle the rest }; } ); ``` ### Icon types | Type | Description | |---|---| | `EMPTY` | Background (empty slot) | | `HALF` | Half-filled icon | | `FULL` | Fully filled icon | | `EMPTY_HUNGER` | Background during Hunger effect | | `HALF_HUNGER` | Half icon during Hunger effect | | `FULL_HUNGER` | Full icon during Hunger effect | | `HALF_OVERLAY` | Half icon on top row *(Overflowing Bars only)* | | `FULL_OVERLAY` | Full icon on top row *(Overflowing Bars only)* | | `SATURATION` | Saturation overlay texture *(AppleSkin only)* | ### Registering at the right time Call `Foo

# 🍖 Food API
### A flexible hunger system library for NeoForge
[!(https://img.shields.io/badge/MODRINTH-pink?style=for-the-badge&logo=modrinth&logoColor=white&labelColor=gray)](https://modrinth.com/user/Arimo) [!(https://img.shields.io/badge/GITHUB-pink?style=for-the-badge&logo=github&logoColor=white&labelColor=gray)](https://github.com/ArimoV2)

## 📖 About
Food API is a developer-focused library that removes the hardcoded limitations of Minecraft's vanilla hunger system. It exposes hunger capacity and drain speed as proper entity attributes, adds multi-row food bar rendering, and provides a clean provider-based system for replacing food icons — all with optional compatibility for popular HUD mods.
## ✨ Features
▶ Dynamic hunger capacity — max hunger is now an attribute, supports up to 2 rows (40 units).
▶ Configurable drain speed — control how fast hunger depletes via a multiplier attribute.
▶ Multi-row food bar — second row renders seamlessly above the first, fully synced with vanilla shake animation.
▶ Icon provider system — replace any food icon (empty, half, full, hunger, overlay, saturation) per-player, per-row, per-slot with a simple registration API.
▶ Optional mod compat — native support for (https://modrinth.com/mod/overflowing-bars) and (https://modrinth.com/mod/appleskin) when present.
## 🖼️ Screenshots
Vanilla rendering — single row, standard icons

With Overflowing Bars — row counter, overlay icons stacked on top

## 📦 New Attributes
Two new player attributes are registered automatically when Food API is loaded:
| Attribute | ID | Default | Range | Description | |---|---|---|---|---| | Max Hunger | `food_api:max_hunger` | `20` | `1 – 40` | Maximum hunger capacity. 20 = one row, 40 = two rows. | | Hunger Rate | `food_api:hunger_rate` | `1. 0` | `0. 0 – 10. 0` | Hunger drain speed multiplier. `0` = no drain, `2` = twice as fast. |
Both attributes are synced to the client and can be modified via commands, other mods, or directly in code:
```java // Example: give a player double hunger capacity player.getAttribute(AttributeRegistries. MAX_HUNGER) .setBaseValue(40);
// Example: slow hunger drain to half speed player.getAttribute(AttributeRegistries. HUNGER_RATE) .setBaseValue(0. 5); ```
## 🔧 API Usage
### Replacing food icons
Register a provider with an ID and priority. Higher priority wins. Return `null` to fall through to the next provider.
```java FoodIconRegistry.register( ResourceLocation.fromNamespaceAndPath("mymod", "my_provider"), 10, // priority — higher = checked first (vanilla = 0) (player, iconIndex, row, type) -> { // iconIndex: 0 = rightmost icon, 9 = leftmost // row: 0 = bottom row, 1 = top row return switch (type) { case FULL -> ResourceLocation.fromNamespaceAndPath("mymod", "hud/my_food_full"); case HALF -> ResourceLocation.fromNamespaceAndPath("mymod", "hud/my_food_half"); case EMPTY -> ResourceLocation.fromNamespaceAndPath("mymod", "hud/my_food_empty"); default -> null; // let other providers or vanilla handle the rest }; } ); ```
### Icon types
| Type | Description | |---|---| | `EMPTY` | Background (empty slot) | | `HALF` | Half-filled icon | | `FULL` | Fully filled icon | | `EMPTY_HUNGER` | Background during Hunger effect | | `HALF_HUNGER` | Half icon during Hunger effect | | `FULL_HUNGER` | Full icon during Hunger effect | | `HALF_OVERLAY` | Half icon on top row (Overflowing Bars only) | | `FULL_OVERLAY` | Full icon on top row (Overflowing Bars only) | | `SATURATION` | Saturation overlay texture (AppleSkin only) |
### Registering at the right time
📊 Mod Details
- Game
- Minecraft Mods
- Author
- AxoLabs
- Version
- 1.1
- Downloads
- 273
- Endorsements
- 2
- Category
- food
- Created
- 3/16/2026
- Updated
- 3/16/2026
- Game Versions
- 1.21.1
- Tags
- food, game-mechanics
🔧 How to Install Minecraft Mods Mods
Download from Modrinth. Use Prism Launcher or drop into your mods folder.
📖 Full step-by-step install guide for Minecraft Mods →
Visit the official mod page for specific installation instructions for this mod.
🎮 Need cheat codes or console commands? Check ur gaming wiki for Minecraft Mods commands, item IDs, and more.
❓ Frequently Asked Questions
Which Minecraft Mods versions does Food API support?
The author lists 1.21.1. Other versions may work but are untested by the author.
What is the latest version of Food API?
Version 1.1, published 2026-03-16 with 273 downloads recorded at the source.
Keep browsing — more Minecraft Mods mods await