mirror of
https://github.com/Samsuik/Sakura.git
synced 2025-12-22 16:29:16 +00:00
20 lines
1.1 KiB
Diff
20 lines
1.1 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Samsuik <kfian294ma4@gmail.com>
|
|
Date: Thu, 6 Jun 2024 18:18:28 +0100
|
|
Subject: [PATCH] Configure fast health regen
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/world/food/FoodData.java b/src/main/java/net/minecraft/world/food/FoodData.java
|
|
index b89860d451d92ddda64b7e4144542b7fc5fd86f0..bb3e1a81356bda63e64f519cce96659801022925 100644
|
|
--- a/src/main/java/net/minecraft/world/food/FoodData.java
|
|
+++ b/src/main/java/net/minecraft/world/food/FoodData.java
|
|
@@ -83,7 +83,7 @@ public class FoodData {
|
|
|
|
boolean flag = player.level().getGameRules().getBoolean(GameRules.RULE_NATURAL_REGENERATION);
|
|
|
|
- if (flag && this.saturationLevel > 0.0F && player.isHurt() && this.foodLevel >= 20) {
|
|
+ if (flag && this.saturationLevel > 0.0F && player.isHurt() && this.foodLevel >= 20 && player.level().sakuraConfig().players.combat.fastHealthRegen) { // Sakura - configure fast health regen
|
|
++this.tickTimer;
|
|
if (this.tickTimer >= this.saturatedRegenRate) { // CraftBukkit
|
|
float f = Math.min(this.saturationLevel, 6.0F);
|