2020-04-22 00:06:30 +02:00
|
|
|
From 44c5bb2c6355406dc77de81f8ee0602a9e2e7b71 Mon Sep 17 00:00:00 2001
|
2016-12-16 23:03:56 +01:00
|
|
|
From: Zach Brown <zach.brown@destroystokyo.com>
|
|
|
|
Date: Fri, 16 Dec 2016 16:03:19 -0600
|
|
|
|
Subject: [PATCH] Don't let fishinghooks use portals
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
2020-04-22 00:06:30 +02:00
|
|
|
index 7e552f98..2ab877c8 100644
|
2016-12-16 23:03:56 +01:00
|
|
|
--- a/src/main/java/net/minecraft/server/Entity.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/Entity.java
|
2019-12-12 00:43:22 +01:00
|
|
|
@@ -161,7 +161,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
|
|
|
public boolean ac;
|
2016-12-16 23:03:56 +01:00
|
|
|
public boolean impulse;
|
|
|
|
public int portalCooldown;
|
2019-12-12 00:43:22 +01:00
|
|
|
- protected boolean af;
|
|
|
|
+ protected boolean af; public final boolean inPortal() { return this.af; } // Paper - OBFHELPER
|
|
|
|
protected int ag;
|
2018-08-26 20:11:49 +02:00
|
|
|
public DimensionManager dimension;
|
2019-12-12 00:43:22 +01:00
|
|
|
protected BlockPosition ai;
|
2016-12-16 23:03:56 +01:00
|
|
|
diff --git a/src/main/java/net/minecraft/server/EntityFishingHook.java b/src/main/java/net/minecraft/server/EntityFishingHook.java
|
2020-04-22 00:06:30 +02:00
|
|
|
index 40bdcf4e..39e3bd37 100644
|
2016-12-16 23:03:56 +01:00
|
|
|
--- a/src/main/java/net/minecraft/server/EntityFishingHook.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/EntityFishingHook.java
|
2019-12-12 00:43:22 +01:00
|
|
|
@@ -160,6 +160,12 @@ public class EntityFishingHook extends Entity {
|
2019-04-27 08:26:04 +02:00
|
|
|
|
|
|
|
this.setMot(this.getMot().a(0.92D));
|
2019-12-12 00:43:22 +01:00
|
|
|
this.Z();
|
2016-12-16 23:03:56 +01:00
|
|
|
+
|
|
|
|
+ // Paper start - These shouldn't be going through portals
|
|
|
|
+ if (this.inPortal()) {
|
|
|
|
+ this.die();
|
|
|
|
+ }
|
|
|
|
+ // Paper end
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
--
|
2020-04-22 00:06:30 +02:00
|
|
|
2.25.1.windows.1
|
2016-12-16 23:03:56 +01:00
|
|
|
|