mirror of
https://github.com/BX-Team/DivineMC.git
synced 2025-12-22 08:19:19 +00:00
Upstream has released updates that appear to apply and compile correctly Purpur Changes: PurpurMC/Purpur@c0f5e78 add default silverfish movement speed & attack damage attributes PurpurMC/Purpur@b82f693 configurable mob size attribute (#1538) PurpurMC/Purpur@e05f91b [ci skip] move import to config patch PurpurMC/Purpur@2ba7bee Updated Upstream (Paper)
23 lines
1.0 KiB
Diff
23 lines
1.0 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: NONPLAYT <76615486+NONPLAYT@users.noreply.github.com>
|
|
Date: Sat, 10 Jun 2023 13:17:01 +0300
|
|
Subject: [PATCH] Fix MC-31819
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/world/entity/player/Player.java b/src/main/java/net/minecraft/world/entity/player/Player.java
|
|
index b06eebbad2b20d4c59c9163388af220594ddf6b7..b8db58d25d91bc538fb310dfb801be4f05ec0b57 100644
|
|
--- a/src/main/java/net/minecraft/world/entity/player/Player.java
|
|
+++ b/src/main/java/net/minecraft/world/entity/player/Player.java
|
|
@@ -1946,6 +1946,11 @@ public abstract class Player extends LivingEntity {
|
|
}
|
|
|
|
public void causeFoodExhaustion(float f, EntityExhaustionEvent.ExhaustionReason reason) {
|
|
+ // DivineMC start - Fix MC-31819
|
|
+ if (this.level().getDifficulty() == Difficulty.PEACEFUL) {
|
|
+ return;
|
|
+ }
|
|
+ // DivineMC end
|
|
// CraftBukkit end
|
|
if (!this.abilities.invulnerable) {
|
|
if (!this.level().isClientSide) {
|