Healthy DietFEATURE GUIDEEnglish
01 / NUTRITION

Nutrition: values, stages and conditional rules

Follow a meal through group gains, hunger-driven decay, stage evaluation, ongoing bonuses and optional conditional rules. Figures show examples, never a live server.

0–100 with decimalsInteger stage checksServer-configurable
Illustration boundary: The panel uses bundled Forge-branch definitions and chosen example player values; NeoForge defaults and actual servers may differ.

01Nutrition groups and panel

Each group is an independent 0–100 value. A food can affect multiple groups (for example, an apple can supply fruit and sugar). Consumption affects group values; hunger-point consumption causes configurable decay. The common bundled groups are dairy, fruit, grains, protein, sugar and vegetables, but servers can add, remove, rename and reorder groups.

AppleIllustrative food
→
Fruit+26
Sugar+12
Illustrative settled values, not the bundled item’s actual default values.

Press H to open the nutrition screen, or use /headiet. The six sample bars below show illustrative player values and Forge-branch bundled stage boundaries and schemes; hover or focus a stage segment for configured example bonuses. NeoForge’s bundled stages may differ.

Nutrition status · examplePress H in game
Read-only HTML approximation, not a game screenshot or initial player values. Hover/focus for configured example ranges.
Nutrition and hunger are distinct values: hunger governs eating; nutrition represents long-term dietary balance.

02Gains and hunger-based decay

Approximate eating gain: food base value × group gainMultiplier × lifetime fatigue factor (if applicable), clamped to 0–100. Admin changes, natural decay and initial values do not use the eating gain multiplier. For decay, every consumed hunger point removes 1 / decayRate nutrition from each applicable group; saturation is not included.

4
20
Nutrition lost: 5.0 · Remaining from 100: 95.0

This slider illustrates the formula, not the player’s initial value. Decimals are retained, while stage checks round to an integer (59.6 checks as 60). Death does not clear nutrition; player capability data is copied on respawn.

03Stages and their editor

A stage is an integer nutrition interval with optional title, hover description and click commands. Adjacent intervals must not overlap or leave gaps; the server rounds the current value before matching. /hdui stage (OP4) offers separate Stage, Command and Description tabs for enabled groups. A green Effects button opens a separate bonus page, not a fourth tab.

Low 0–29
Mid 30–69
High 70–100
Rounded: 60Stage: Mid

Those three named ranges are illustrative, not fixed defaults. Clicking a configured stage command runs it with administrator permission and suppressed output; a player may click at most once every 1.5 seconds and the server rechecks. Do not click untrusted stage commands.

Stage tab · /hdui stage (OP4) · Read-only HTML diagram derived from the in-game layout; not a screenshot or live server data.
Stage tab · /hdui stage (OP4)
Enabled groupSelect a group; pick a stage on the interval bar
RangeAdd / delete / split contiguous integer intervals
Command tabAdd click-triggered commands; they do not execute merely on entering a stage
Description tabOptional title, hover text and automatic bonus preview
SaveBack
The three tabs share one draft and save. An unsaved draft prompts before changing groups or opening Effects; automatic tooltip preview has its own immediate group-level toggle.

04Ongoing bonuses and cross-group conditions

The separate Effects page can attach attribute modifiers and recurring potions to one or more nutrient intervals. All group conditions in a combined bonus must match. Attributes are recalculated about every five seconds by default; effects are refreshed about every ten seconds, so effect durations should exceed that cadence to avoid gaps. Exiting an interval removes attribute modifiers at the next refresh; potion effects expire over their remaining duration. This differs from one-shot food effects.

Fruit 30–69
+
Vegetables 30–69
+
Grains 30–69
+
Protein 30–69
→
All conditions matchApply bonus

On the Effects screen, clicking a stage fills its bounds; manually typed bounds require selecting Custom before they take effect. Shift-click selects or deselects additional stages. A selection of multiple groups saves separate range combinations in nutrition_bonuses; it is not a single-group stage table.

Nutrition Effects page · /hdui stage → Effects · Read-only HTML diagram derived from the in-game layout; not a screenshot or live server data.
Nutrition Effects page · /hdui stage → Effects
Groups and intervalsSelect one or more enabled groups / range combinations
Potions and attributesAdd, edit, export or inspect the currently selected combination
SaveEnter a remark before saving; canceling the remark cancels the save
Delete fileAvailable only when editing an existing definition
SaveBack
Cancel discards unsaved effect/attribute edits. Export and file search are separate actions; these web buttons cannot execute them.

05Per-meal conditional rules

After ordinary nutrition from eating is settled, each conditional rule checks its required group ranges. If all match, it can modify any target group, run commands, show a result tip, or combine those actions. Condition groups and target groups need not be the same. Changes are clamped to 0–100. If the same food has both a normal value and a conditional change for a group, both paths run in sequence, so avoid unintentional double counting.

Eat food
→
Apply normal nutrients
→
Check all conditions
→
Changes / commands

Example cap: condition protein 0–86, target protein +20. At 80 it rises at most to 86; at 90 the rule does not match. A correction rule can target protein −30 when current protein is 86–100; it stops around the lower condition boundary rather than decreasing indefinitely.

06Item editor, groups and variants

Hold an item and use /hdui (OP4) for nutrition, food fatigue, thirst, hunger, stack limit, quality binding, shelf life, potion effects, commands, conditional rules and effect removal. /hdui create (OP4) manages group definitions, quality and rarity; it does not edit a player’s current value or register a new item. Group definitions can include ID, localized display name, icon, decay rate, initial value, gain multiplier, player tag, required mod ID, order, enable switch and four nutrient tip colors.

Nutrition group tab · /hdui create (OP4) · Read-only HTML diagram derived from the in-game layout; not a screenshot or live server data.
Nutrition group tab · /hdui create (OP4)
ID / nameChoose a new ID and display name; an existing ID is read-only
Icon and colorsChoose item icon, solid color or scheme and optional tip colors
RatesSet positive decay rate, initial value (0–100) and nonnegative gain multiplier
AvailabilityOptional player tag or loaded mod, sort order and enabled switch
SaveBack
Create or Save writes a group definition; it does not register an item. The localization action for bundled names changes the server display name, not only a local translation.

One item can define distinct NBT variants, such as two potion types with different nutrition; matching variants do not automatically inherit the generic entry. Stack size and some thirst fields are item-level, not per-variant. /hdui groups [player] opens a value-management screen; /hdui registry manages startup item registration; /hdui tooltip opens item tooltip editing. The old /hdgroups command has been removed.

07Administrative commands

CommandPermission and target
/headiet / /headiet openSelf, no OP: open your own panel.
/headiet open <player>OP2: send the panel to the specified player, not view that player’s panel on the executor’s screen.
/headiet add|subtract|set <player> <group> <value>OP4: modify the named group; input accepts decimals in 0–100.
/hdui groups [player]OP4: manage the player’s values and pause groups, not definitions.

A paused group neither gains from eating nor decays until resumed. Group definitions come from datapacks and editor writes use an override layer.

08Takeaways

  1. Values stay within 0–100, retain decimals and round for stage checks.
  2. Hunger consumption drives natural decay; saturation does not. Death does not erase nutrition.
  3. Stages and recurring bonuses track ongoing state; per-food conditional rules settle during eating. Server files decide the real groups, thresholds and effects.