20 lines
1 KiB
Diff
20 lines
1 KiB
Diff
From 0000000000000000000000000000000000000000 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/world/entity/animal/Ocelot.java b/src/main/java/net/minecraft/world/entity/animal/Ocelot.java
|
|
index b18546b6816ee77f1458a7ca44b32f76c33f2fe9..a781048b0c43e63e441e6afecec125d7f838c342 100644
|
|
--- a/src/main/java/net/minecraft/world/entity/animal/Ocelot.java
|
|
+++ b/src/main/java/net/minecraft/world/entity/animal/Ocelot.java
|
|
@@ -134,7 +134,7 @@ public class Ocelot extends Animal {
|
|
|
|
@Override
|
|
public boolean removeWhenFarAway(double distanceSquared) {
|
|
- return !this.isTrusting() /*&& this.tickCount > 2400*/; // CraftBukkit
|
|
+ return !this.isTrusting() && !this.hasCustomName() && !this.isLeashed() /*&& this.tickCount > 2400*/; // CraftBukkit // Paper - honor name and leash
|
|
}
|
|
|
|
public static AttributeSupplier.Builder createAttributes() {
|