9
0
mirror of https://github.com/LeavesMC/Leaves.git synced 2025-12-27 02:49:10 +00:00
Files
LeavesMC/patches/server/0128-Can-disable-LivingEntity-aiStep-alive-check.patch
2024-08-14 17:07:19 +08:00

20 lines
927 B
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: violetc <58360096+s-yh-china@users.noreply.github.com>
Date: Mon, 22 Jul 2024 18:30:42 +0800
Subject: [PATCH] Can disable LivingEntity aiStep alive check
diff --git a/src/main/java/net/minecraft/world/entity/LivingEntity.java b/src/main/java/net/minecraft/world/entity/LivingEntity.java
index c578497c824021e571b21b1b938705e7f585632c..0730c2a7fe66e38b71df15050b17d2acb6b47251 100644
--- a/src/main/java/net/minecraft/world/entity/LivingEntity.java
+++ b/src/main/java/net/minecraft/world/entity/LivingEntity.java
@@ -3193,7 +3193,7 @@ public abstract class LivingEntity extends Entity implements Attackable {
}
}
- if (!this.isRemoved()) {
+ if (org.leavesmc.leaves.LeavesConfig.disableLivingEntityAiStepAliveCheck || !this.isRemoved()) { // Leaves - can disable check
this.aiStep();
}