- Change CustomFoodLevel default value to false - Add potion material to BottleMaterial - Add exception for execute command(customFood and vanillaFood) - Add PotionColor option to customfood (hex color) - Add HidePotionEffect option to customfood - Add Unstackable option to customfood - Add message disable configuration - Add hex color support for custom item names and lore. - Add ItemsAdder support - Add option to ignore items created with ItemsAdder - Fixed an issue where the player's hunger was not reduced when customfoodlevel was disabled
Code (YAML):
Compatibility: ItemsAdder:
Enabled: false
Ignore-Item: true
#If true, Ignore items created with ItemsAdder
Code (YAML):
Customfood-GlobalCooldown:
Enabled: false
Message: "Time left: <customfood_global_timeleft>" Customfood-PersonalCooldown:
Enabled: false
Message: "<customfood_name> &fTime left: <customfood_personal_timeleft>" VanillaFood-GlobalCooldown:
Enabled: false
Message: "Time left: <vanilla_global_timeleft>" VanillaFood-PersonalCooldown:
Enabled: false
Message: "<food_name> Time left: <vanilla_personal_timeleft>" Max-foodlevel:
Enabled: false
Message: "&aFood level reached the maximum value of <max_foodlevel>." Max-saturation:
Enabled: false
Message: "&aSaturation reached the maximum value of <max_saturation>." Permission-Error:
Enabled: false
Message: "&cYou don't have permission"
- Add inspection for vanilla food(Possibly no longer change saturation for custom items made of edible materials) - Add 'DisableCrafting' option for custom food - Add 'DisableSmelting' option for custom food - Add 'DisableAnvil' option for custom food - Add 'DisableEnchant' option for custom food - If Max-Consumable is true, when the player's hunger is full, vanilla food (e.g. carrot, potato) will be planted instead of consumed when right click farmland. - Fixed an issue where the edit gui was empty if there was no uuid when setting the material to player_head - Add sound option to custom food - Add food diet feature
Code (YAML):
# Food diet # Including custom food FoodDiet:
Enabled: false
RecoveryPenaltyCount: 1
# Amount of penalty to be reduced when eating different types of food MaxPenaltyCount: 5
Penalty:
0: # first time eating FoodLevel: 0
#reduce percent Saturation: 0
#reduce percent 1:
FoodLevel: 0
Saturation: 0.5
2:
FoodLevel: 0.5
Saturation: 0.5
3:
FoodLevel: 0.5
Saturation: 0.5
PotionEffect: - poison:1:5:0.5
4:
FoodLevel: 0.75
Saturation: 0.75
PotionEffect: - poison:1:5:0.75
5:
FoodLevel: 1
Saturation: 1
PotionEffect: - poison:1:5:1
- wither:1:5:1
- Add bstats for plugin - Add plugin update checker - Add permission for each command - Add configuration in message.yml - Add an option to get the bowl or bottle back when eating food related to the bottle or bowl
(New configurations are added automatically, but if they are not added, please add them manually.)
Code (YAML):
(Default: op
) consumefood.command.help
consumefood.command.reload
consumefood.command.edit
consumefood.command.get
consumefood.command.hunger
consumefood.command.customhunger
consumefood.command.saturation
Update For servers where paper-api is not available(ex. spigot server), NBTAPI plugin is required. - This is an important update - The plugin code has been rewritten.
- Delete or backup the previous config.yml, customfood.yml, message.yml and then create a new one.
- Configuration in config.yml has changed to be easier to use than before.
- Previous /hunger, /saturation commands changed to /consumefood hunger, /consumefood saturation
- Added '/consumefood customhunger' command
- Support for placeholders in commands and messages
- If the PlaceholderApi plugin is on the server, you can use %consumefood_foodlevel% and %consuemfood_max_foodlevel%
# Changing this doesn't change the hunger bar. # If 'Enabled-CustomFoodLevel' is true, can change the player's max foodlevel. # Available placeholder = [ %consumefood_foodlevel%, %consumefood_max_foodlevel% ] # # If 'Sync-CustomFoodLevel' is true, the player's foodlevel and custom foodlevel will be synchronized. ('Sync-CustomFoodLevel' recommends true) # For example, if the custom foodlevel is 10/40(value/max), the player's foodlevel will be 5 | 15/40 = 8 # # 'Sprint-FoodLevel' is the minimum foodlevel at which the player can run. # 'Sprint-FoodLevel' is applied only when 'Sync-CustomFoodLevel' is true. CustomSetting:
Enabled-CustomFoodLevel: true
Sync-CustomFoodLevel: true
Max-FoodLevel: 20
Max-Saturation: 10
Sprint-FoodLevel: 6
# If 'Max-Consumable' is true, the player can eat food even if the player's hunger bar is full.. # But this doesn't play the food eating animation. Max-Consumable:
Enabled: false
# Available Type values: [global, personal, disable] # If Type is global, all food cooldown is applied as global_cooldown value # If Type is personal, the cooldown is applied for each food # If Type is disable, cooldown is disabled Cooldown-Setting:
Type: 'disable'
Global_Cooldown: 3
#If you don't need a message, leave a blank. Placeholders are available (ex. %player_name%) Customfood-GlobalCooldown: "Time left: <customfood_global_timeleft>" Customfood-PersonalCooldown: "<customfood_name> &fTime left: <customfood_personal_timeleft>" VanillaFood-GlobalCooldown: "Time left: <vanilla_global_timeleft>" VanillaFood-PersonalCooldown: "<food_name> Time left: <vanilla_personal_timeleft>" Max-foodlevel: "&aFood level reached the maximum value of <max_foodlevel>." Max-saturation: "&aSaturation reached the maximum value of <max_saturation>."
This version adds configuration to config.yml and customfood.yml
How to configure cooldown Cooldown is disabled by default
Code (Text):
# Available Type values: global, personal, disable
# If Type is global, all food cooldown is applied as global_cooldown value
# If Type is personal, the cooldown is applied for each food
# If Type is disable, cooldown is disabled
Cooldown:
Type: 'disable'
Global_Cooldown: 3
# Available Type values: global, personal, disable
# If Type is global, all food cooldown is applied as global_cooldown value
# If Type is personal, the cooldown is applied for each food
# If Type is disable, cooldown is disabled
Custom_Food_Cooldown:
Type: 'disable'
Global_Cooldown: 3
- Fixed incorrect potiontype.yml (Delete potiontype.yml and restart the plugin)
- Fixed a problem where null was generated when a character was entered in <vaule> when using /hunger and /saturation
Code (YAML):
# You can use data for custom model data Custom_Food:
food_4:
material: APPLE
data: 1
name: '&ctest food 4'
lore: - '&aTest 4'
- '&fTest 4.4'
foodlevel: 4
saturation: 4.4
- If you use player_head for material in custom food, you need to use paper server. (Custom food made of material player_head uses paper-api)
- Custom food added. (The material of custom food is currently only supported for player_head or edible food.)
- Custom food can be create at customfood.yml
- Added consumefood command to get custom food (/consumefood get <internal_name> <amount>)
Once the customfood.yml file is created,
There is an example custom food by default
Code (Text):
Custom_Food:
internal_name: (The internal name is what is used to get it with the command)
material: (material sets the material of the custom food. The material of custom food is currently only supported for player_head or edible food)
value: (Required if material is player_head. The value can be found here: https://minecraft-heads.com/custom-heads)
name: (name is the item name of the custom food. You can use color code)
lore: (lore is the lore of custom food. You can use color code)
foodlevel: (foodlevel sets the food level of custom food)
saturation: (saturation sets the saturation of custom food)
potion-effect: (potion-effect applies the potion effect of custom food)
Chance: (Chance is the chance of apply of the potion-effect)
- Add Buff-Debuff_Food configuration to config.yml. This includes enchanted_golden_apple, golden_apple, pufferfish, poisonous_potato, rotten_fresh, spider_eye
- Add golden_carrot to Food configuration in config.yml
- Added /gethunger and /getsaturation commands
(If you want, you can apply the potion effect by moving the Food configuration to the Buff-Debuff_Food configuration in config.yml.)
There was a mistake because it was the first plugin I made.
The size of ConsumeFood.jar was large because spigot-api was included in the process of compiling the plugin from the project. Fixed this issue in this version. I'm sorry for causing you any trouble.
Update
- Added configuration to set maximum FoodLevel and Saturation in config
- Please add MaxSetting configuration to config like the following code
- If the MaxSetting configuration does not exist, it will be applied as a default value. (Both FoodLevel and Saturation default to 20)