9
0
mirror of https://github.com/Samsuik/Sakura.git synced 2025-12-21 15:59:26 +00:00
Files
SakuraMC/patches/server/0039-Option-to-configure-entity-water-sensitivity.patch
Samsuik ae970e6a71 Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly
2023-12-07 16:00:45 +00:00

20 lines
1.1 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Samsuik <40902469+Samsuik@users.noreply.github.com>
Date: Tue, 21 Nov 2023 11:21:37 +0000
Subject: [PATCH] Option to configure entity water sensitivity
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index 558c862f082d4e48c2c0d7ecf900f9354387d32b..7728492fd3623670482f4ca89e0934e7bcb972e1 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -3502,7 +3502,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
}
}
// Paper end
- if (!this.level().isClientSide && this.isSensitiveToWater() && this.isInWaterRainOrBubble()) {
+ if (!this.level().isClientSide && this.level().sakuraConfig().entity.waterSensitivity && this.isSensitiveToWater() && this.isInWaterRainOrBubble()) { // Sakura
this.hurt(this.damageSources().drown(), 1.0F);
}