9
0
mirror of https://github.com/Samsuik/Sakura.git synced 2025-12-23 08:49:25 +00:00
Files
SakuraMC/patches/server/0034-Add-option-to-disable-entity-ai.patch
Samsuik b7e6fbe70e Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly

Paper Changes:
PaperMC/Paper@956b3d1 Ensure MaterialChoice materials are items (#11325)
PaperMC/Paper@5625051 Prevent duplicate pickup event for piglins (#11322)
PaperMC/Paper@94444ce Fix incorrect timestamp in region file header recalculation (#11318)
PaperMC/Paper@5b2c43e Remove set damage lootable item function from compasses (#11317)
PaperMC/Paper@5167856 Fix despawn ranges by defaulting to an ellipsoid shape (#11312)
PaperMC/Paper@e2da65c Deprecate API relating to menu title changes (#11309)
PaperMC/Paper@ad4c524 Properly destroy placed blocks on the end platform (#11292)
PaperMC/Paper@374d9c8 Add a method to reset Lodestone compasses back to normal ones (#11308)
PaperMC/Paper@dd8c70a Ensure TabCompleteEvent always has a mutable backing list. (#11302)
PaperMC/Paper@a7b8d95 Add enchantment seed update API (#11282)
PaperMC/Paper@789a267 Re-implement maxLeashDistance world conf and call missing event (#11301)
PaperMC/Paper@e08e667 Fix: synchronise sending chat to client with updating message signature cache (#11332)
2024-08-27 09:18:54 +01:00

20 lines
1.0 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Samsuik <40902469+Samsuik@users.noreply.github.com>
Date: Sat, 18 Nov 2023 15:12:14 +0000
Subject: [PATCH] Add option to disable entity ai
diff --git a/src/main/java/net/minecraft/world/entity/Mob.java b/src/main/java/net/minecraft/world/entity/Mob.java
index 763abeea3f14f15c27d600e0bdae44b387687bb4..f805e62b527180c074f63c0887c86cdc94f166ab 100644
--- a/src/main/java/net/minecraft/world/entity/Mob.java
+++ b/src/main/java/net/minecraft/world/entity/Mob.java
@@ -912,7 +912,7 @@ public abstract class Mob extends LivingEntity implements EquipmentUser, Leashab
protected final void serverAiStep() {
++this.noActionTime;
// Paper start - Allow nerfed mobs to jump and float
- if (!this.aware) {
+ if (!this.aware || this.level().sakuraConfig().entity.disableMobAi) { // Sakura
if (goalFloat != null) {
if (goalFloat.canUse()) goalFloat.tick();
this.getJumpControl().tick();