9
0
mirror of https://github.com/Winds-Studio/Leaf.git synced 2026-01-06 15:51:31 +00:00
Files
Leaf/leaf-server/minecraft-patches/features/0110-Fix-sprint-glitch.patch
2025-03-31 16:33:30 -04:00

21 lines
969 B
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: pixelNightly <pixelnightly@proton.me>
Date: Mon, 4 Dec 2023 16:11:36 +0200
Subject: [PATCH] Fix sprint glitch
diff --git a/net/minecraft/world/entity/LivingEntity.java b/net/minecraft/world/entity/LivingEntity.java
index 08c2021a43f626ae142d38d0d0492bffeb1b346b..e65914c2623197031d50508af5c45a4db6b98836 100644
--- a/net/minecraft/world/entity/LivingEntity.java
+++ b/net/minecraft/world/entity/LivingEntity.java
@@ -1358,7 +1358,8 @@ public abstract class LivingEntity extends Entity implements Attackable {
player.setRealHealth(health);
}
- player.updateScaledHealth(false);
+ //player.updateScaledHealth(false); // Leaf - Fix sprint glitch - commented out
+ this.entityData.set(LivingEntity.DATA_HEALTH_ID, player.getScaledHealth()); // Leaf - Fix sprint glitch
return;
}
// CraftBukkit end