mirror of
https://github.com/PaperMC/Paper.git
synced 2024-08-21 11:52:55 +02:00
23 lines
921 B
Diff
23 lines
921 B
Diff
From b85a89090ea6103014d91a52477423811b2052a3 Mon Sep 17 00:00:00 2001
|
|
From: BillyGalbreath <Blake.Galbreath@GMail.com>
|
|
Date: Mon, 31 Jul 2017 01:54:40 -0500
|
|
Subject: [PATCH] Ocelot despawns should honor nametags and leash
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityOcelot.java b/src/main/java/net/minecraft/server/EntityOcelot.java
|
|
index 062411455..d9a7b8ac1 100644
|
|
--- a/src/main/java/net/minecraft/server/EntityOcelot.java
|
|
+++ b/src/main/java/net/minecraft/server/EntityOcelot.java
|
|
@@ -81,7 +81,7 @@ public class EntityOcelot extends EntityAnimal {
|
|
|
|
@Override
|
|
public boolean isTypeNotPersistent(double d0) {
|
|
- return !this.isTrusting() /*&& this.ticksLived > 2400*/; // CraftBukkit
|
|
+ return !this.isTrusting() && !this.hasCustomName() && !this.isLeashed() /*&& this.ticksLived > 2400*/; // CraftBukkit // Paper - honor name and leash
|
|
}
|
|
|
|
@Override
|
|
--
|
|
2.25.0.windows.1
|
|
|