跳到正文

Nutritional

作者:Saereth

Nutritional adds a diet system where every food counts toward five groups: dairy, fruit, grain, protein, and vegetable. Keep them balanced to climb diet tiers and earn health, speed, and armor bonuses. Eat poorly and pay for it. Datapack-driven.

收藏

截图

介绍

中文介绍正在准备中,下面暂时显示原文。

Nutritional

Nutritional adds a diet system to Minecraft. The food you eat counts toward five food groups, and keeping them in balance makes you stronger, while living on a single food works against you. It is a NeoForge 1.21.1 rewrite of WesCook’s Nutrition.

Everything in the mod is built to be retuned by pack makers without writing code. See For pack makers and developers below.

How it works

Every food belongs to one or more of five groups: dairy, fruit, grain, protein, and vegetable. Eating raises the groups that food belongs to, and each group slowly drops over time as you get hungry. The goal is to keep all five reasonably topped up rather than spamming one food.

Your overall balance is graded into a diet tier, from worst to best:

starving, malnourished, surviving, nourished, gourmand

A poor diet leaves you in a low tier with penalties. A varied, well-fed diet pushes you into a high tier that grants bonuses to things like max health, movement speed, and armor. Eating well also makes future meals more nourishing and slows how fast your groups drop, so good habits build on themselves.

On top of the tiers:

  • Status effects. Crossing certain nutrient levels can give you status effects, both helpful ones for eating well and penalties for eating badly.
  • Long-term rewards. Keep a good diet going for several Minecraft days in a row and you earn a permanent bonus. It sticks until you die or let your diet slip too far.
  • Harsher dimensions. By default the Nether and the End are tougher on you: your groups drain faster and food does less there.

Seeing your diet

  • Press N to open a screen with a bar for every food group and your current diet tier.
  • A small widget in the top-right corner shows your current tier at a glance. You can toggle it from a button on the diet screen.
  • Hovering a food shows which groups it fills and how much.
  • If you use JEI, looking up a food shows a "Provides nutrients" entry with the same information.

Advancements

The mod ships a small advancement tree for eating from each food group, eating a varied diet, and reaching the higher diet tiers and rewards.

Configuration

Most behavior can be changed in two config files:

  • nutritional-client.toml for personal display options like the tooltip, the HUD widget, and the diet screen button.
  • nutritional-server.toml for world rules like how fast groups drain, the death penalty, and overall difficulty multipliers.

Pack makers can change far more than this through datapacks, covered next.

For pack makers and developers

Nutritional is data-driven. Food groups, the items in them, diet tiers, status-effect rules, rewards, and per-dimension difficulty are all defined in datapacks, so they can be added, rebalanced, or removed without touching Java.

Data model

Six first-class datapack registries:

Registry Path
nutritional:nutrient data/<pack>/nutritional/nutrient/<id>.json
nutritional:effect data/<pack>/nutritional/effect/<id>.json
nutritional:food_hint data/<pack>/nutritional/food_hint/<id>.json
nutritional:diet_tier data/<pack>/nutritional/diet_tier/<id>.json
nutritional:sustained_reward data/<pack>/nutritional/sustained_reward/<id>.json
nutritional:dimension_modifier data/<pack>/nutritional/dimension_modifier/<dim_namespace>/<dim_path>.json

Effects support four detection modes: any, average, all, and cumulative. The nourished, malnourished, and toughness mob effects ship by default.

Items and scaling

Which group an item belongs to comes from tags (#nutritional:nutrient/<id>). Per-item scale overrides come from a NeoForge DataMap (nutritional:nutrient_scales on the minecraft:item registry). Most foods need only a tag entry.

Custom attributes

Two attributes are added and can be modified by equipment, mob effects, and other mods:

  • nutritional:nutrient_absorption, how much food gives. Higher means meals are more nourishing.
  • nutritional:nutrient_decay_rate, how fast groups drop. Lower means they drain slower.

Commands

  • /nutritional get|set|add|subtract|reset <player> <nutrient> [<value>]
  • /nutritional reload reloads datapacks
  • /nutritional-food prints the nutrient yield for the held item

Advancement triggers

Two custom criterion triggers, nutritional:tier_reached and nutritional:reward_earned, are available for datapacks to build their own advancement trees against.

Credits

  • WesCook, original Nutrition author. The original 1.12 mod inspired this rewrite’s core concepts: nutrients, thresholds, and decay tied to hunger.
  • Original 1.12 contributors are listed in this repo’s git history, preserved on the 1.12 branch.

常见问题

Nutritional 支持哪些 Minecraft 版本?

Nutritional 支持 Minecraft Java 版 1.21.1–26.1.2,共 2 个版本,可用的加载器:NeoForge。下载时注意选择和你游戏版本一致的文件。

Nutritional 怎么安装?

先用 PCL2 或 HMCL 启动器安装对应版本的 NeoForge,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。

评论

登录后评论和评分

Saereth 的其他作品

查看全部 →