• check_circle Functions
  • 4,157 views, 2 today
  • 171 downloads, 0 today
  • 18
  • 11
  • 22
KNIZE_1007's Avatar KNIZE_1007
Level 46 : Master Blacksmith
27

Balanced Diet Datapack


This datapack adds new nutrition bars. There are 5 of them - fruit, vegetable, meat, grains and sugar/energy bar. It is important to keep all of them as high as possible. High values give positive effects while low values give negative effects. These values go down when you eat something or slowly go down overtime.

Fruit

  • if high - occasional regen
  • if low - occasional poison

Vegetables

  • if high - resistance
  • if low - mining fatigue

Meat

  • if high - strenght
  • if low - mining fatigue

Grains

  • if high - saturation
  • if low - hunger

Sugar/Energy

  • if high - speed
  • if low - slowness this bar works slightly different than the others, it decreases 5x faster than the others, but can be increased up by a variety of foods. Also I would not recommend filling it up all the way ;)

More info


The value of increased nutrition is based on how many hunger bars the food fills. for example carrot fills up vegetable bar by 3, steak increases meat bar by 8, bread increases grain bar by 5. For example, eating bread increases your grain bar by 5. but all other bars can decrease by 1 (50% chance). Some foods increase 2 or more bars simultaneously. Effects from nutrition bars increase or decrease in level or frequency by the amount of nutrition.

Commands


There are two trigger commands: /trigger see_ur_nutrition and /trigger turn_off_see_ur_nutrition. The first command enables the player to see how much nutrition does he have in each bar. There is a config menu for admins, use /function knize:config

Unistalling


Run the command /function knize:unistall and remove the datapack from the datapacks folder

License

You are not allowed to re-publish or re-distribute this datapack in any form. You can use this in a video/stream if you give credit, and it is not allowed to take credit for its development.

Known Bugs

  • Might sometimes miss eating dried kelp, because the scoreboards check every 1s instead of every tick to decrease lag caused.
CompatibilityMinecraft 1.19
Tags

5 Update Logs

V2.1 : by KNIZE_1007 05/14/2023 10:11:40 amMay 14th, 2023

  • Added advancement to show that this datapack is being used
  • Added advancement to tell people about /trigger commands
  • Added advancements for various things around this datapack
  • Chance of nutrition decreasing from 50% to 75% after eating food
LOAD MORE LOGS

Create an account or sign in to comment.

2
03/12/2023 9:36 am
Level 1 : New Miner
susbus
susbus's Avatar
Hey man, i've been playing hardcore for like 2 hours with this data pack and i have to be honest, the sugar-slowness mechanic is absolutely unbearable. I had to open the source code and change some values because i can't play with Slowness VI for like hours. The idea is great tho, no hate of course, I just feel like this mechanic is way too extreme especially in early game as we don't really have many different food options, especially sugar-ish ones.
1
03/12/2023 12:12 pm
Level 46 : Master Blacksmith
KNIZE_1007
KNIZE_1007's Avatar
I am sorry that the sugar-energy thing is too unbearable for you, the newest update has somewhat reduced that because eating food only loweres values 50% of the time. It isnt in the changelog, but honey was changed so you can drink it without it lowering other nutritions. If you still feel like it is too extreme, you could run the command schedule clear knize:60second, which would mean that energy will decrease only every 240 seconds by one automatically instead of every minute. And as a recommendation, cookies or honey are a great source of energy (farmers sell cookies for a relatively cheap price if you dont have cocoa beans).
2
03/11/2023 9:59 pm
Level 1 : New Miner
DanDark
DanDark's Avatar
Hi! I really like this datapack but I've found a bug. Wherever I plant a carrot, for exemple, the datapack counts as if I ate it.


Also is it possible to slow down the system? I think the nutrition points are changing too fast and that makes the game unplayable.
Can you make it easier?

PS: I am playing on my server with friends. Vanilla 1.19.2 java.
2
03/11/2023 10:33 pm
Level 1 : New Miner
DanDark
DanDark's Avatar
It would be great if you could manage to:

- fix the planting bug
- slow down the speed of the values (allow players to eat more so it doesn't get annoying)
- change the positive and negative effects to activate only at 90/100 and 10/100 respectively.

Thanks in advance!
2
03/12/2023 5:26 am
Level 46 : Master Blacksmith
KNIZE_1007
KNIZE_1007's Avatar
The planting bug has been fixed, Slowed down the draining of nutritions and adjusted the effect activations slightly based on your feedback.
2
03/12/2023 3:24 pm
Level 1 : New Miner
DanDark
DanDark's Avatar
Thanks Knize! The datapack is almost perfect now!
I ran the command "schedule clear knize:60second" and its much better!

One question, how can I modify the datapack folder instead of running the command "schedule clear knize:60second"?
2
03/12/2023 3:54 pmhistory
Level 46 : Master Blacksmith
KNIZE_1007
KNIZE_1007's Avatar
you could just delete the knize:60second file entirely, and then delete "function knize:60second" in the load.mcfunction it wont mess up the datapack in any way.
I may add a toggle in the future so you could turn off fast draining of energy with how many people dont seem to like it.
2
03/13/2023 11:01 pm
Level 1 : New Miner
DanDark
DanDark's Avatar
Knize, is there a command I can run to reset all player's values to default from server console?
3
03/11/2023 6:01 amhistory
Level 9 : Apprentice Blacksmith
Big Man Max
Big Man Max's Avatar
Theres a file in the recipies folder that completely disables being able to craft Crafting Tables for some reason.

Planting eatable foods like Potatoes and Carrots for some reason also counts towards eating it, therefore changing the nutrition values

My friend ate a glowberry and it caused all his nutrition meters to drain constantly and permanently

after 10 hours of playing I gotta say this pack isn't that fun to use in its base form
2
03/11/2023 10:58 am
Level 46 : Master Blacksmith
KNIZE_1007
KNIZE_1007's Avatar
new version is out, fixing crafting tables and eating glowberries. I dont know how to fix the potato/carrot thing right now, but when i find a solution it will be implemented.
1
03/11/2023 10:52 am
Level 46 : Master Blacksmith
KNIZE_1007
KNIZE_1007's Avatar
Thank you for pointing out that crafting crafting tables is disabled, oops, and you are right about the glow berry thing, the reset scoreboard command is missing. Unfortunately, I dont know how to fix the planting of potatoes/carrots thing right now. A new version will be released very soon.
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome