give EAR immunity to piston pushed entities
helps keep vanilla behavior with piston elevators
Dieser Commit ist enthalten in:
Ursprung
34ee08f240
Commit
6230d632e3
@ -21,6 +21,18 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
public BlockPosition h() {
|
||||
return new BlockPosition(this);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -575,6 +575,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
this.recalcPosition();
|
||||
} else {
|
||||
if (enummovetype == EnumMoveType.PISTON) {
|
||||
+ this.activatedTick = MinecraftServer.currentTick + 20; // Paper
|
||||
long i = this.world.getTime();
|
||||
|
||||
if (i != this.aM) {
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityCreature.java b/src/main/java/net/minecraft/server/EntityCreature.java
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityCreature.java
|
||||
|
@ -1,11 +1,11 @@
|
||||
From fd33332cf965cc89f246b3a1007ebb534c13476c Mon Sep 17 00:00:00 2001
|
||||
From 7ac07ac07ac07ac07ac07ac07ac07ac07ac07ac0 Mon Sep 17 00:00:00 2001
|
||||
From: Zach Brown <zach.brown@destroystokyo.com>
|
||||
Date: Sun, 22 May 2016 20:20:55 -0500
|
||||
Subject: [PATCH] Optional TNT doesn't move in water
|
||||
|
||||
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
index db3e70e97a..ff1a2046f6 100644
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||
@@ -2,7 +2,6 @@ package com.destroystokyo.paper;
|
||||
@ -32,10 +32,10 @@ index db3e70e97a..ff1a2046f6 100644
|
||||
+ }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index 5e5c241669..c17e41f128 100644
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -1172,6 +1172,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1173,6 +1173,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
}
|
||||
|
||||
public boolean aq() {
|
||||
@ -48,7 +48,7 @@ index 5e5c241669..c17e41f128 100644
|
||||
return this.isInWater() || this.q();
|
||||
}
|
||||
|
||||
@@ -2724,6 +2730,11 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2725,6 +2731,11 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
}
|
||||
|
||||
public boolean bw() {
|
||||
@ -61,7 +61,7 @@ index 5e5c241669..c17e41f128 100644
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityTNTPrimed.java b/src/main/java/net/minecraft/server/EntityTNTPrimed.java
|
||||
index 87f3205f82..8c1d25979f 100644
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityTNTPrimed.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityTNTPrimed.java
|
||||
@@ -147,4 +147,49 @@ public class EntityTNTPrimed extends Entity {
|
||||
@ -115,5 +115,5 @@ index 87f3205f82..8c1d25979f 100644
|
||||
+ // Paper end
|
||||
}
|
||||
--
|
||||
2.19.0
|
||||
2.19.1
|
||||
|
||||
|
@ -8,7 +8,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -2076,6 +2076,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2077,6 +2077,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
}
|
||||
|
||||
protected boolean addPassenger(Entity entity) { // CraftBukkit
|
||||
|
@ -16,7 +16,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
protected int numCollisions = 0; // Paper
|
||||
public void inactiveTick() { }
|
||||
// Spigot end
|
||||
@@ -1649,6 +1650,10 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1650,6 +1651,10 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
if (origin != null) {
|
||||
nbttagcompound.set("Paper.Origin", this.createList(origin.getX(), origin.getY(), origin.getZ()));
|
||||
}
|
||||
@ -27,7 +27,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
// Paper end
|
||||
return nbttagcompound;
|
||||
} catch (Throwable throwable) {
|
||||
@@ -1796,6 +1801,8 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1797,6 +1802,8 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
if (!originTag.isEmpty()) {
|
||||
origin = new Location(world.getWorld(), originTag.getDoubleAt(0), originTag.getDoubleAt(1), originTag.getDoubleAt(2));
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 3aed4cf92a8420481473aacf4a54016261305bac Mon Sep 17 00:00:00 2001
|
||||
From 7ac07ac07ac07ac07ac07ac07ac07ac07ac07ac0 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sun, 10 Jun 2018 20:04:42 -0400
|
||||
Subject: [PATCH] Properly remove entities on dimension teleport
|
||||
@ -22,10 +22,10 @@ requirement, but plugins (such as my own) use this method to
|
||||
trigger a "reload" of the entity on the client.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index 8660387623..347aef07d5 100644
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -2594,7 +2594,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2595,7 +2595,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
}
|
||||
// CraftBukkit end */
|
||||
|
||||
@ -35,7 +35,7 @@ index 8660387623..347aef07d5 100644
|
||||
this.world.methodProfiler.a("reposition");
|
||||
/* CraftBukkit start - Handled in calculateTarget
|
||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||
index ee06457653..b939c31b23 100644
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||
@@ -1020,6 +1020,7 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
||||
@ -47,5 +47,5 @@ index ee06457653..b939c31b23 100644
|
||||
this.entitiesById.d(entity.getId());
|
||||
this.entitiesByUUID.remove(entity.getUniqueID());
|
||||
--
|
||||
2.19.0
|
||||
2.19.1
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 9033f11036980fc2b1ba2f237e8b6e82cb939b3f Mon Sep 17 00:00:00 2001
|
||||
From 7ac07ac07ac07ac07ac07ac07ac07ac07ac07ac0 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Thu, 19 Jul 2018 01:13:28 -0400
|
||||
Subject: [PATCH] add more information to Entity.toString()
|
||||
@ -6,10 +6,10 @@ Subject: [PATCH] add more information to Entity.toString()
|
||||
UUID, ticks lived, valid, dead
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index 347aef07d5..42c1c47c58 100644
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -2497,7 +2497,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2498,7 +2498,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
}
|
||||
|
||||
public String toString() {
|
||||
@ -19,5 +19,5 @@ index 347aef07d5..42c1c47c58 100644
|
||||
|
||||
public boolean isInvulnerable(DamageSource damagesource) {
|
||||
--
|
||||
2.19.0
|
||||
2.19.1
|
||||
|
||||
|
@ -166,7 +166,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -2722,6 +2722,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2723,6 +2723,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -49,7 +49,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -1658,6 +1658,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1659,6 +1659,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
if (spawnedViaMobSpawner) {
|
||||
nbttagcompound.setBoolean("Paper.FromMobSpawner", true);
|
||||
}
|
||||
@ -62,7 +62,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
// Paper end
|
||||
return nbttagcompound;
|
||||
} catch (Throwable throwable) {
|
||||
@@ -1747,6 +1753,16 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1748,6 +1754,16 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
if (this.aD()) {
|
||||
this.setPosition(this.locX, this.locY, this.locZ);
|
||||
}
|
||||
@ -79,7 +79,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
|
||||
// CraftBukkit start
|
||||
if (this instanceof EntityLiving) {
|
||||
@@ -2816,6 +2832,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2817,6 +2833,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
return this.boundingBox;
|
||||
}
|
||||
|
||||
|
@ -30,7 +30,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -1538,6 +1538,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1539,6 +1539,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -38,7 +38,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
public void a(Entity entity, int i, DamageSource damagesource) {
|
||||
if (entity instanceof EntityPlayer) {
|
||||
CriterionTriggers.c.a((EntityPlayer) entity, this, damagesource);
|
||||
@@ -2407,6 +2408,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2408,6 +2409,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
this.fallDistance = 0.0F;
|
||||
}
|
||||
|
||||
@ -46,7 +46,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
public void b(EntityLiving entityliving) {}
|
||||
|
||||
protected boolean i(double d0, double d1, double d2) {
|
||||
@@ -3077,6 +3079,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -3078,6 +3080,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
return EnumPistonReaction.NORMAL;
|
||||
}
|
||||
|
||||
|
@ -29,7 +29,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -1733,7 +1733,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1734,7 +1734,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
this.setPosition(this.locX, this.locY, this.locZ);
|
||||
this.setYawPitch(this.yaw, this.pitch);
|
||||
if (nbttagcompound.hasKeyOfType("CustomName", 8)) {
|
||||
|
@ -17,7 +17,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -1720,7 +1720,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1721,7 +1721,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
this.setAirTicks(nbttagcompound.getShort("Air"));
|
||||
this.onGround = nbttagcompound.getBoolean("OnGround");
|
||||
if (nbttagcompound.hasKey("Dimension")) {
|
||||
|
@ -49,7 +49,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -1518,6 +1518,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -1519,6 +1519,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
return new Vec3D((double) (f5 * f6), (double) (-f7), (double) (f4 * f6));
|
||||
}
|
||||
|
||||
@ -57,7 +57,7 @@ index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
public Vec3D i(float f) {
|
||||
if (f == 1.0F) {
|
||||
return new Vec3D(this.locX, this.locY + (double) this.getHeadHeight(), this.locZ);
|
||||
@@ -2181,10 +2182,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2182,10 +2183,12 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
return this.bP().size() < 1;
|
||||
}
|
||||
|
||||
|
@ -8,7 +8,7 @@ diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/
|
||||
index 7ac07ac07ac0..7ac07ac07ac0 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -2334,7 +2334,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
@@ -2335,7 +2335,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
|
||||
|
||||
}
|
||||
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren