mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 02:55:47 +01:00
More 1.14 patches
This commit is contained in:
parent
4296582054
commit
9d3524b908
@ -1,4 +1,4 @@
|
|||||||
From 98fa17b2e410c24de48f86b9daaa28e549ceea1e Mon Sep 17 00:00:00 2001
|
From a0496589b3cfd1b90cb738162ae185d812763bf9 Mon Sep 17 00:00:00 2001
|
||||||
From: Minecrell <minecrell@minecrell.net>
|
From: Minecrell <minecrell@minecrell.net>
|
||||||
Date: Wed, 11 Oct 2017 19:30:51 +0200
|
Date: Wed, 11 Oct 2017 19:30:51 +0200
|
||||||
Subject: [PATCH] Call PaperServerListPingEvent for legacy pings
|
Subject: [PATCH] Call PaperServerListPingEvent for legacy pings
|
||||||
@ -6,7 +6,7 @@ Subject: [PATCH] Call PaperServerListPingEvent for legacy pings
|
|||||||
|
|
||||||
diff --git a/src/main/java/com/destroystokyo/paper/network/PaperLegacyStatusClient.java b/src/main/java/com/destroystokyo/paper/network/PaperLegacyStatusClient.java
|
diff --git a/src/main/java/com/destroystokyo/paper/network/PaperLegacyStatusClient.java b/src/main/java/com/destroystokyo/paper/network/PaperLegacyStatusClient.java
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 0000000000..74c012fd40
|
index 000000000..74c012fd4
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/src/main/java/com/destroystokyo/paper/network/PaperLegacyStatusClient.java
|
+++ b/src/main/java/com/destroystokyo/paper/network/PaperLegacyStatusClient.java
|
||||||
@@ -0,0 +1,73 @@
|
@@ -0,0 +1,73 @@
|
||||||
@ -84,7 +84,7 @@ index 0000000000..74c012fd40
|
|||||||
+
|
+
|
||||||
+}
|
+}
|
||||||
diff --git a/src/main/java/net/minecraft/server/LegacyPingHandler.java b/src/main/java/net/minecraft/server/LegacyPingHandler.java
|
diff --git a/src/main/java/net/minecraft/server/LegacyPingHandler.java b/src/main/java/net/minecraft/server/LegacyPingHandler.java
|
||||||
index 2a99f34df6..2a30af7def 100644
|
index 9bc1cce3f..e086b4140 100644
|
||||||
--- a/src/main/java/net/minecraft/server/LegacyPingHandler.java
|
--- a/src/main/java/net/minecraft/server/LegacyPingHandler.java
|
||||||
+++ b/src/main/java/net/minecraft/server/LegacyPingHandler.java
|
+++ b/src/main/java/net/minecraft/server/LegacyPingHandler.java
|
||||||
@@ -1,5 +1,7 @@
|
@@ -1,5 +1,7 @@
|
||||||
@ -105,7 +105,7 @@ index 2a99f34df6..2a30af7def 100644
|
|||||||
|
|
||||||
switch (i) {
|
switch (i) {
|
||||||
case 0:
|
case 0:
|
||||||
LegacyPingHandler.a.debug("Ping: (<1.3.x) from {}:{}", inetsocketaddress.getAddress(), inetsocketaddress.getPort());
|
LegacyPingHandler.LOGGER.debug("Ping: (<1.3.x) from {}:{}", inetsocketaddress.getAddress(), inetsocketaddress.getPort());
|
||||||
- s = String.format("%s\u00a7%d\u00a7%d", event.getMotd(), event.getNumPlayers(), event.getMaxPlayers()); // CraftBukkit
|
- s = String.format("%s\u00a7%d\u00a7%d", event.getMotd(), event.getNumPlayers(), event.getMaxPlayers()); // CraftBukkit
|
||||||
+ // Paper start - Call PaperServerListPingEvent and use results
|
+ // Paper start - Call PaperServerListPingEvent and use results
|
||||||
+ event = PaperLegacyStatusClient.processRequest(minecraftserver, inetsocketaddress, 39, null);
|
+ event = PaperLegacyStatusClient.processRequest(minecraftserver, inetsocketaddress, 39, null);
|
||||||
@ -120,7 +120,7 @@ index 2a99f34df6..2a30af7def 100644
|
|||||||
@@ -59,7 +68,14 @@ public class LegacyPingHandler extends ChannelInboundHandlerAdapter {
|
@@ -59,7 +68,14 @@ public class LegacyPingHandler extends ChannelInboundHandlerAdapter {
|
||||||
}
|
}
|
||||||
|
|
||||||
LegacyPingHandler.a.debug("Ping: (1.4-1.5.x) from {}:{}", inetsocketaddress.getAddress(), inetsocketaddress.getPort());
|
LegacyPingHandler.LOGGER.debug("Ping: (1.4-1.5.x) from {}:{}", inetsocketaddress.getAddress(), inetsocketaddress.getPort());
|
||||||
- s = String.format("\u00a71\u0000%d\u0000%s\u0000%s\u0000%d\u0000%d", 127, minecraftserver.getVersion(), event.getMotd(), event.getNumPlayers(), event.getMaxPlayers()); // CraftBukkit
|
- s = String.format("\u00a71\u0000%d\u0000%s\u0000%s\u0000%d\u0000%d", 127, minecraftserver.getVersion(), event.getMotd(), event.getNumPlayers(), event.getMaxPlayers()); // CraftBukkit
|
||||||
+ // Paper start - Call PaperServerListPingEvent and use results
|
+ // Paper start - Call PaperServerListPingEvent and use results
|
||||||
+ event = PaperLegacyStatusClient.processRequest(minecraftserver, inetsocketaddress, 127, null); // Paper
|
+ event = PaperLegacyStatusClient.processRequest(minecraftserver, inetsocketaddress, 127, null); // Paper
|
@ -1,4 +1,4 @@
|
|||||||
From 2e2942bc159b5c614d5dc2b7cb28a3cc92c769a0 Mon Sep 17 00:00:00 2001
|
From 2adba7d40590352c767b1fdb4aebd8886fc15835 Mon Sep 17 00:00:00 2001
|
||||||
From: Shane Freeder <theboyetronic@gmail.com>
|
From: Shane Freeder <theboyetronic@gmail.com>
|
||||||
Date: Sat, 31 Mar 2018 17:04:26 +0100
|
Date: Sat, 31 Mar 2018 17:04:26 +0100
|
||||||
Subject: [PATCH] Flag to disable the channel limit
|
Subject: [PATCH] Flag to disable the channel limit
|
||||||
@ -9,10 +9,10 @@ e.g. servers which allow and support the usage of mod packs.
|
|||||||
provide an optional flag to disable this check, at your own risk.
|
provide an optional flag to disable this check, at your own risk.
|
||||||
|
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||||
index 66873e98fe..62235efde9 100644
|
index 1aff6cab9..01e260024 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
|
||||||
@@ -131,6 +131,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
@@ -136,6 +136,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||||
// Paper start
|
// Paper start
|
||||||
private org.bukkit.event.player.PlayerResourcePackStatusEvent.Status resourcePackStatus;
|
private org.bukkit.event.player.PlayerResourcePackStatusEvent.Status resourcePackStatus;
|
||||||
private String resourcePackHash;
|
private String resourcePackHash;
|
||||||
@ -20,7 +20,7 @@ index 66873e98fe..62235efde9 100644
|
|||||||
// Paper end
|
// Paper end
|
||||||
|
|
||||||
public CraftPlayer(CraftServer server, EntityPlayer entity) {
|
public CraftPlayer(CraftServer server, EntityPlayer entity) {
|
||||||
@@ -1433,7 +1434,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
@@ -1458,7 +1459,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void addChannel(String channel) {
|
public void addChannel(String channel) {
|
@ -1,14 +1,14 @@
|
|||||||
From 72a83e45b01f592f4f0bed57cb341631b515b925 Mon Sep 17 00:00:00 2001
|
From 1d5cd93e8dab70b3891db2a05b7a332c53033714 Mon Sep 17 00:00:00 2001
|
||||||
From: Mark Vainomaa <mikroskeem@mikroskeem.eu>
|
From: Mark Vainomaa <mikroskeem@mikroskeem.eu>
|
||||||
Date: Sun, 1 Apr 2018 02:29:37 +0300
|
Date: Sun, 1 Apr 2018 02:29:37 +0300
|
||||||
Subject: [PATCH] Add method to open already placed sign
|
Subject: [PATCH] Add method to open already placed sign
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||||
index d5dbc4ca81..9b19dce9bd 100644
|
index c2b6e792a..6478d6126 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||||
@@ -655,4 +655,17 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
@@ -709,4 +709,17 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
|
||||||
entity.remove();
|
entity.remove();
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -0,0 +1,21 @@
|
|||||||
|
From ce0d24798899c83d963e9f0879fe170ea59132af Mon Sep 17 00:00:00 2001
|
||||||
|
From: Kyle Wood <demonwav@gmail.com>
|
||||||
|
Date: Thu, 1 Mar 2018 19:38:14 -0600
|
||||||
|
Subject: [PATCH] Load version history at server start
|
||||||
|
|
||||||
|
|
||||||
|
diff --git a/src/main/java/net/minecraft/server/DedicatedServer.java b/src/main/java/net/minecraft/server/DedicatedServer.java
|
||||||
|
index d9f1c2205..c2c676e3b 100644
|
||||||
|
--- a/src/main/java/net/minecraft/server/DedicatedServer.java
|
||||||
|
+++ b/src/main/java/net/minecraft/server/DedicatedServer.java
|
||||||
|
@@ -172,6 +172,7 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
com.destroystokyo.paper.PaperConfig.registerCommands();
|
||||||
|
+ com.destroystokyo.paper.VersionHistoryManager.INSTANCE.getClass(); // load version history now
|
||||||
|
// Paper end
|
||||||
|
|
||||||
|
this.setSpawnAnimals(dedicatedserverproperties.spawnAnimals);
|
||||||
|
--
|
||||||
|
2.21.0
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From c618e7b5819a5514e61df2af06ec51351ebe8881 Mon Sep 17 00:00:00 2001
|
From 2dcdbc031e78acf21b630f4f21662851935325f2 Mon Sep 17 00:00:00 2001
|
||||||
From: Brokkonaut <hannos17@gmx.de>
|
From: Brokkonaut <hannos17@gmx.de>
|
||||||
Date: Sat, 14 Apr 2018 20:20:46 +0200
|
Date: Sat, 14 Apr 2018 20:20:46 +0200
|
||||||
Subject: [PATCH] Configurable sprint interruption on attack
|
Subject: [PATCH] Configurable sprint interruption on attack
|
||||||
@ -6,10 +6,10 @@ Subject: [PATCH] Configurable sprint interruption on attack
|
|||||||
If the sprint interruption is disabled players continue sprinting when they attack entities.
|
If the sprint interruption is disabled players continue sprinting when they attack entities.
|
||||||
|
|
||||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
index f68b8a4b05..6fb76388e9 100644
|
index 32bfe0e46..7024336c3 100644
|
||||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
@@ -423,4 +423,9 @@ public class PaperWorldConfig {
|
@@ -354,4 +354,9 @@ public class PaperWorldConfig {
|
||||||
private void squidMaxSpawnHeight() {
|
private void squidMaxSpawnHeight() {
|
||||||
squidMaxSpawnHeight = getDouble("squid-spawn-height.maximum", 0.0D);
|
squidMaxSpawnHeight = getDouble("squid-spawn-height.maximum", 0.0D);
|
||||||
}
|
}
|
||||||
@ -20,13 +20,13 @@ index f68b8a4b05..6fb76388e9 100644
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java
|
diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java
|
||||||
index 7f29d12771..d4618d644a 100644
|
index 1df83d13a..27bf83f37 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityHuman.java
|
--- a/src/main/java/net/minecraft/server/EntityHuman.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityHuman.java
|
+++ b/src/main/java/net/minecraft/server/EntityHuman.java
|
||||||
@@ -1081,7 +1081,11 @@ public abstract class EntityHuman extends EntityLiving {
|
@@ -1030,7 +1030,11 @@ public abstract class EntityHuman extends EntityLiving {
|
||||||
|
}
|
||||||
|
|
||||||
this.motX *= 0.6D;
|
this.setMot(this.getMot().d(0.6D, 1.0D, 0.6D));
|
||||||
this.motZ *= 0.6D;
|
|
||||||
- this.setSprinting(false);
|
- this.setSprinting(false);
|
||||||
+ // Paper start - Configuration option to disable automatic sprint interruption
|
+ // Paper start - Configuration option to disable automatic sprint interruption
|
||||||
+ if (!world.paperConfig.disableSprintInterruptionOnAttack) {
|
+ if (!world.paperConfig.disableSprintInterruptionOnAttack) {
|
@ -1,14 +1,14 @@
|
|||||||
From daadce88762d874da50c14fc9ed25c3b3037de45 Mon Sep 17 00:00:00 2001
|
From 7fcb20e1726495b07d82c141a552372c1d2efec1 Mon Sep 17 00:00:00 2001
|
||||||
From: 0x22 <0x22@futureclient.net>
|
From: 0x22 <0x22@futureclient.net>
|
||||||
Date: Thu, 26 Apr 2018 04:41:11 -0400
|
Date: Thu, 26 Apr 2018 04:41:11 -0400
|
||||||
Subject: [PATCH] Fix exploit that allowed colored signs to be created
|
Subject: [PATCH] Fix exploit that allowed colored signs to be created
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||||
index 2f00929f63..6dea9456a4 100644
|
index 25c86b53e..c9caf4423 100644
|
||||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||||
@@ -2465,7 +2465,7 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {
|
@@ -2516,7 +2516,7 @@ public class PlayerConnection implements PacketListenerPlayIn {
|
||||||
String[] lines = new String[4];
|
String[] lines = new String[4];
|
||||||
|
|
||||||
for (int i = 0; i < astring.length; ++i) {
|
for (int i = 0; i < astring.length; ++i) {
|
@ -1,4 +1,4 @@
|
|||||||
From 5ca1ad1bd48d14028083ed5c8cbb8478a9f918df Mon Sep 17 00:00:00 2001
|
From 631be52465547db97f19c1fbf1739710294218c3 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Mon, 30 Apr 2018 13:15:55 -0400
|
Date: Mon, 30 Apr 2018 13:15:55 -0400
|
||||||
Subject: [PATCH] EndermanEscapeEvent
|
Subject: [PATCH] EndermanEscapeEvent
|
||||||
@ -8,18 +8,18 @@ Fires an event anytime an enderman intends to teleport away from the player
|
|||||||
You may cancel this, enabling ranged attacks to damage the enderman for example.
|
You may cancel this, enabling ranged attacks to damage the enderman for example.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
index d5d1be8b6b..8949529e67 100644
|
index 9f2e350b3..2b484c819 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
@@ -1,6 +1,7 @@
|
@@ -2,6 +2,7 @@ package net.minecraft.server;
|
||||||
package net.minecraft.server;
|
|
||||||
|
|
||||||
|
import java.util.EnumSet;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
+import com.destroystokyo.paper.event.entity.EndermanEscapeEvent; // Paper
|
+import com.destroystokyo.paper.event.entity.EndermanEscapeEvent; // Paper
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
import java.util.function.Function;
|
import java.util.function.Predicate;
|
||||||
@@ -48,6 +49,12 @@ public class EntityEnderman extends EntityMonster {
|
@@ -55,6 +56,12 @@ public class EntityEnderman extends EntityMonster {
|
||||||
setGoalTarget(entityliving, org.bukkit.event.entity.EntityTargetEvent.TargetReason.UNKNOWN, true);
|
setGoalTarget(entityliving, org.bukkit.event.entity.EntityTargetEvent.TargetReason.UNKNOWN, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -32,49 +32,52 @@ index d5d1be8b6b..8949529e67 100644
|
|||||||
@Override
|
@Override
|
||||||
public boolean setGoalTarget(EntityLiving entityliving, org.bukkit.event.entity.EntityTargetEvent.TargetReason reason, boolean fireEvent) {
|
public boolean setGoalTarget(EntityLiving entityliving, org.bukkit.event.entity.EntityTargetEvent.TargetReason reason, boolean fireEvent) {
|
||||||
if (!super.setGoalTarget(entityliving, reason, fireEvent)) {
|
if (!super.setGoalTarget(entityliving, reason, fireEvent)) {
|
||||||
@@ -160,7 +167,7 @@ public class EntityEnderman extends EntityMonster {
|
@@ -174,7 +181,7 @@ public class EntityEnderman extends EntityMonster {
|
||||||
if (this.world.L() && this.ticksLived >= this.bE + 600) {
|
if (this.world.J() && this.ticksLived >= this.bC + 600) {
|
||||||
float f = this.az();
|
float f = this.aE();
|
||||||
|
|
||||||
- if (f > 0.5F && this.world.e(new BlockPosition(this)) && this.random.nextFloat() * 30.0F < (f - 0.4F) * 2.0F) {
|
- if (f > 0.5F && this.world.f(new BlockPosition(this)) && this.random.nextFloat() * 30.0F < (f - 0.4F) * 2.0F) {
|
||||||
+ if (f > 0.5F && this.world.e(new BlockPosition(this)) && this.random.nextFloat() * 30.0F < (f - 0.4F) * 2.0F && tryEscape(EndermanEscapeEvent.Reason.RUNAWAY)) { // Paper
|
+ if (f > 0.5F && this.world.f(new BlockPosition(this)) && this.random.nextFloat() * 30.0F < (f - 0.4F) * 2.0F && this.tryEscape(EndermanEscapeEvent.Reason.RUNAWAY)) { // Paper
|
||||||
this.setGoalTarget((EntityLiving) null);
|
this.setGoalTarget((EntityLiving) null);
|
||||||
this.dz();
|
this.dW();
|
||||||
}
|
}
|
||||||
@@ -239,7 +246,7 @@ public class EntityEnderman extends EntityMonster {
|
@@ -256,17 +263,19 @@ public class EntityEnderman extends EntityMonster {
|
||||||
public boolean damageEntity(DamageSource damagesource, float f) {
|
} else if (!(damagesource instanceof EntityDamageSourceIndirect) && damagesource != DamageSource.FIREWORKS) {
|
||||||
if (this.isInvulnerable(damagesource)) {
|
|
||||||
return false;
|
|
||||||
- } else if (damagesource instanceof EntityDamageSourceIndirect) {
|
|
||||||
+ } else if (damagesource instanceof EntityDamageSourceIndirect && tryEscape(EndermanEscapeEvent.Reason.INDIRECT)) { // Paper
|
|
||||||
for (int i = 0; i < 64; ++i) {
|
|
||||||
if (this.dz()) {
|
|
||||||
return true;
|
|
||||||
@@ -250,7 +257,7 @@ public class EntityEnderman extends EntityMonster {
|
|
||||||
} else {
|
|
||||||
boolean flag = super.damageEntity(damagesource, f);
|
boolean flag = super.damageEntity(damagesource, f);
|
||||||
|
|
||||||
- if (damagesource.ignoresArmor() && this.random.nextInt(10) != 0) {
|
- if (damagesource.ignoresArmor() && this.random.nextInt(10) != 0) {
|
||||||
+ if (damagesource.ignoresArmor() && this.random.nextInt(10) != 0 && tryEscape(damagesource == DamageSource.DROWN ? EndermanEscapeEvent.Reason.DROWN : EndermanEscapeEvent.Reason.CRITICAL_HIT)) { // Paper
|
+ if (damagesource.ignoresArmor() && this.random.nextInt(10) != 0 && this.tryEscape(damagesource == DamageSource.DROWN ? EndermanEscapeEvent.Reason.DROWN : EndermanEscapeEvent.Reason.CRITICAL_HIT)) { // Paper
|
||||||
this.dz();
|
this.dW();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -339,7 +346,7 @@ public class EntityEnderman extends EntityMonster {
|
return flag;
|
||||||
|
} else {
|
||||||
|
+ if (this.tryEscape(EndermanEscapeEvent.Reason.INDIRECT)) { // Paper start
|
||||||
|
for (int i = 0; i < 64; ++i) {
|
||||||
|
if (this.dW()) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
+ } // Paper end
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
@@ -388,7 +397,7 @@ public class EntityEnderman extends EntityMonster {
|
||||||
|
|
||||||
static class PathfinderGoalPlayerWhoLookedAtTarget extends PathfinderGoalNearestAttackableTarget<EntityHuman> {
|
static class PathfinderGoalPlayerWhoLookedAtTarget extends PathfinderGoalNearestAttackableTarget<EntityHuman> {
|
||||||
|
|
||||||
- private final EntityEnderman i;
|
- private final EntityEnderman i;
|
||||||
+ private final EntityEnderman i; public EntityEnderman getEnderman() { return i; } // Paper - OBFHELPER
|
+ private final EntityEnderman i; public final EntityEnderman getEnderman() { return this.i; } // Paper - OBFHELPER
|
||||||
private EntityHuman j;
|
private EntityHuman j;
|
||||||
private int k;
|
private int k;
|
||||||
private int l;
|
private int l;
|
||||||
@@ -391,7 +398,7 @@ public class EntityEnderman extends EntityMonster {
|
@@ -446,7 +455,7 @@ public class EntityEnderman extends EntityMonster {
|
||||||
} else {
|
} else {
|
||||||
if (this.d != null) {
|
if (this.c != null && !this.i.isPassenger()) {
|
||||||
if (this.i.f((EntityHuman) this.d)) {
|
if (this.i.f((EntityHuman) this.c)) {
|
||||||
- if (((EntityHuman) this.d).h(this.i) < 16.0D) {
|
- if (this.c.h((Entity) this.i) < 16.0D) {
|
||||||
+ if (((EntityHuman) this.d).h(this.i) < 16.0D && this.getEnderman().tryEscape(EndermanEscapeEvent.Reason.STARE)) { // Paper
|
+ if (this.c.h((Entity) this.i) < 16.0D && this.getEnderman().tryEscape(EndermanEscapeEvent.Reason.STARE)) {
|
||||||
this.i.dz();
|
this.i.dW();
|
||||||
}
|
}
|
||||||
|
|
||||||
--
|
--
|
@ -1,4 +1,4 @@
|
|||||||
From d92790d85799f57bd6f30b8eed5589b289935287 Mon Sep 17 00:00:00 2001
|
From c80235802b0eb5c67f0682ef37f8bb4f257671d4 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Mon, 30 Apr 2018 13:29:44 -0400
|
Date: Mon, 30 Apr 2018 13:29:44 -0400
|
||||||
Subject: [PATCH] Enderman.teleportRandomly()
|
Subject: [PATCH] Enderman.teleportRandomly()
|
||||||
@ -6,22 +6,22 @@ Subject: [PATCH] Enderman.teleportRandomly()
|
|||||||
Ability to trigger the vanilla "teleport randomly" mechanic of an enderman.
|
Ability to trigger the vanilla "teleport randomly" mechanic of an enderman.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
index 8949529e67..233568cc12 100644
|
index 2b484c819..e441fa234 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
@@ -176,6 +176,7 @@ public class EntityEnderman extends EntityMonster {
|
@@ -190,6 +190,7 @@ public class EntityEnderman extends EntityMonster {
|
||||||
super.mobTick();
|
super.mobTick();
|
||||||
}
|
}
|
||||||
|
|
||||||
+ public boolean teleportRandomly() { return dz(); } // Paper - OBFHELPER
|
+ public final boolean teleportRandomly() { return this.dW(); } // Paper - OBFHELPER
|
||||||
protected boolean dz() {
|
protected boolean dW() {
|
||||||
double d0 = this.locX + (this.random.nextDouble() - 0.5D) * 64.0D;
|
double d0 = this.locX + (this.random.nextDouble() - 0.5D) * 64.0D;
|
||||||
double d1 = this.locY + (double) (this.random.nextInt(64) - 32);
|
double d1 = this.locY + (double) (this.random.nextInt(64) - 32);
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
|
||||||
index b81693d9ff..9bc6a6c0c1 100644
|
index da8a70d6a..e56da9085 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
|
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEnderman.java
|
||||||
@@ -17,6 +17,7 @@ public class CraftEnderman extends CraftMonster implements Enderman {
|
@@ -16,6 +16,7 @@ public class CraftEnderman extends CraftMonster implements Enderman {
|
||||||
super(server, entity);
|
super(server, entity);
|
||||||
}
|
}
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From 4e03b9b37015ba08e1491234302e6662eb1e0b23 Mon Sep 17 00:00:00 2001
|
From 3881d12211b3b592149a8537eabf9ea2bae4996b Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Mon, 30 Apr 2018 17:15:26 -0400
|
Date: Mon, 30 Apr 2018 17:15:26 -0400
|
||||||
Subject: [PATCH] Block Enderpearl Travel Exploit
|
Subject: [PATCH] Block Enderpearl Travel Exploit
|
||||||
@ -12,10 +12,10 @@ This disables that by not saving the thrower when the chunk is unloaded.
|
|||||||
This is mainly useful for survival servers that do not allow freeform teleporting.
|
This is mainly useful for survival servers that do not allow freeform teleporting.
|
||||||
|
|
||||||
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
index 6fb76388e9..0a270b899d 100644
|
index 7024336c3..fe9415b1d 100644
|
||||||
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
|
||||||
@@ -428,4 +428,10 @@ public class PaperWorldConfig {
|
@@ -359,4 +359,10 @@ public class PaperWorldConfig {
|
||||||
private void disableSprintInterruptionOnAttack() {
|
private void disableSprintInterruptionOnAttack() {
|
||||||
disableSprintInterruptionOnAttack = getBoolean("game-mechanics.disable-sprint-interruption-on-attack", false);
|
disableSprintInterruptionOnAttack = getBoolean("game-mechanics.disable-sprint-interruption-on-attack", false);
|
||||||
}
|
}
|
||||||
@ -27,10 +27,10 @@ index 6fb76388e9..0a270b899d 100644
|
|||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityProjectile.java b/src/main/java/net/minecraft/server/EntityProjectile.java
|
diff --git a/src/main/java/net/minecraft/server/EntityProjectile.java b/src/main/java/net/minecraft/server/EntityProjectile.java
|
||||||
index bab5b89fe9..62b5b6ecea 100644
|
index bb4679cf7..c19828ed5 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityProjectile.java
|
--- a/src/main/java/net/minecraft/server/EntityProjectile.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityProjectile.java
|
+++ b/src/main/java/net/minecraft/server/EntityProjectile.java
|
||||||
@@ -242,6 +242,7 @@ public abstract class EntityProjectile extends Entity implements IProjectile {
|
@@ -205,6 +205,7 @@ public abstract class EntityProjectile extends Entity implements IProjectile {
|
||||||
if (nbttagcompound.hasKeyOfType("owner", 10)) {
|
if (nbttagcompound.hasKeyOfType("owner", 10)) {
|
||||||
this.shooterId = GameProfileSerializer.b(nbttagcompound.getCompound("owner"));
|
this.shooterId = GameProfileSerializer.b(nbttagcompound.getCompound("owner"));
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
From 66592b7c943fac7d1ec21d536a47fcb6fa128dd8 Mon Sep 17 00:00:00 2001
|
From 587bf039a8a66b88900cf9ea3a7ad8c8f1ebb434 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Tue, 15 Aug 2017 22:29:12 -0400
|
Date: Tue, 15 Aug 2017 22:29:12 -0400
|
||||||
Subject: [PATCH] Expand World.spawnParticle API and add Builder
|
Subject: [PATCH] Expand World.spawnParticle API and add Builder
|
||||||
@ -10,10 +10,10 @@ Adds an option to control the force mode of the particle.
|
|||||||
This adds a new Builder API which is much friendlier to use.
|
This adds a new Builder API which is much friendlier to use.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index ee09f4c5a0..e4730352d3 100644
|
index bbf676958..e400cc05d 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -1183,12 +1183,17 @@ public class WorldServer extends World implements IAsyncTaskHandler {
|
@@ -1334,12 +1334,17 @@ public class WorldServer extends World {
|
||||||
}
|
}
|
||||||
|
|
||||||
public <T extends ParticleParam> int sendParticles(EntityPlayer sender, T t0, double d0, double d1, double d2, int i, double d3, double d4, double d5, double d6, boolean force) {
|
public <T extends ParticleParam> int sendParticles(EntityPlayer sender, T t0, double d0, double d1, double d2, int i, double d3, double d4, double d5, double d6, boolean force) {
|
||||||
@ -34,10 +34,10 @@ index ee09f4c5a0..e4730352d3 100644
|
|||||||
|
|
||||||
if (this.a(entityplayer, force, d0, d1, d2, packetplayoutworldparticles)) { // CraftBukkit
|
if (this.a(entityplayer, force, d0, d1, d2, packetplayoutworldparticles)) { // CraftBukkit
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||||
index d72f393a75..1ed6e86855 100644
|
index 3fbc48150..ab54624d6 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||||
@@ -1761,11 +1761,17 @@ public class CraftWorld implements World {
|
@@ -1942,11 +1942,17 @@ public class CraftWorld implements World {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public <T> void spawnParticle(Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, T data, boolean force) {
|
public <T> void spawnParticle(Particle particle, double x, double y, double z, int count, double offsetX, double offsetY, double offsetZ, double extra, T data, boolean force) {
|
@ -1,4 +1,4 @@
|
|||||||
From 33883f6d7a690c25a2c8a73bdf1de1ab9b6dcddd Mon Sep 17 00:00:00 2001
|
From 561006a113ae741a0aee842e0e50b9d4e853711b Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Tue, 1 May 2018 20:18:54 -0400
|
Date: Tue, 1 May 2018 20:18:54 -0400
|
||||||
Subject: [PATCH] EndermanAttackPlayerEvent
|
Subject: [PATCH] EndermanAttackPlayerEvent
|
||||||
@ -8,10 +8,10 @@ Allow control over whether or not an enderman aggros a player.
|
|||||||
This allows you to override/extend the pumpkin/stare logic.
|
This allows you to override/extend the pumpkin/stare logic.
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
diff --git a/src/main/java/net/minecraft/server/EntityEnderman.java b/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
index 233568cc12..139a70ca3b 100644
|
index e441fa234..a1033ce28 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
--- a/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
+++ b/src/main/java/net/minecraft/server/EntityEnderman.java
|
||||||
@@ -127,7 +127,15 @@ public class EntityEnderman extends EntityMonster {
|
@@ -138,7 +138,15 @@ public class EntityEnderman extends EntityMonster {
|
||||||
this.setCarried(iblockdata);
|
this.setCarried(iblockdata);
|
||||||
}
|
}
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From 342abd56794abdc32b82160b0044e6cce4c67d61 Mon Sep 17 00:00:00 2001
|
From baa10d9b32eee5eacbdf112bd430ebcd0be6609c Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Wed, 16 May 2018 20:35:16 -0400
|
Date: Wed, 16 May 2018 20:35:16 -0400
|
||||||
Subject: [PATCH] WitchConsumePotionEvent
|
Subject: [PATCH] WitchConsumePotionEvent
|
||||||
@ -6,10 +6,10 @@ Subject: [PATCH] WitchConsumePotionEvent
|
|||||||
Fires when a witch consumes the potion in their hand
|
Fires when a witch consumes the potion in their hand
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityWitch.java b/src/main/java/net/minecraft/server/EntityWitch.java
|
diff --git a/src/main/java/net/minecraft/server/EntityWitch.java b/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
index eaae9ea9af..0d579c7e47 100644
|
index 477b53fa7..abac47d4c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityWitch.java
|
--- a/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityWitch.java
|
+++ b/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
@@ -67,7 +67,11 @@ public class EntityWitch extends EntityMonster implements IRangedEntity {
|
@@ -88,7 +88,11 @@ public class EntityWitch extends EntityRaider implements IRangedEntity {
|
||||||
|
|
||||||
this.setSlot(EnumItemSlot.MAINHAND, ItemStack.a);
|
this.setSlot(EnumItemSlot.MAINHAND, ItemStack.a);
|
||||||
if (itemstack.getItem() == Items.POTION) {
|
if (itemstack.getItem() == Items.POTION) {
|
@ -1,4 +1,4 @@
|
|||||||
From fa2f88446775c7b2cce37aef73802e12ed324c9f Mon Sep 17 00:00:00 2001
|
From 91612ff7638c1acee6859407f427cc583974e322 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Wed, 16 May 2018 20:44:58 -0400
|
Date: Wed, 16 May 2018 20:44:58 -0400
|
||||||
Subject: [PATCH] WitchThrowPotionEvent
|
Subject: [PATCH] WitchThrowPotionEvent
|
||||||
@ -6,14 +6,13 @@ Subject: [PATCH] WitchThrowPotionEvent
|
|||||||
Fired when a witch throws a potion at a player
|
Fired when a witch throws a potion at a player
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityWitch.java b/src/main/java/net/minecraft/server/EntityWitch.java
|
diff --git a/src/main/java/net/minecraft/server/EntityWitch.java b/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
index 0d579c7e47..62f99fc3b7 100644
|
index abac47d4c..b9307d380 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityWitch.java
|
--- a/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityWitch.java
|
+++ b/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
@@ -154,7 +154,15 @@ public class EntityWitch extends EntityMonster implements IRangedEntity {
|
@@ -185,9 +185,16 @@ public class EntityWitch extends EntityRaider implements IRangedEntity {
|
||||||
potionregistry = Potions.M;
|
potionregistry = Potions.M;
|
||||||
}
|
}
|
||||||
|
|
||||||
- EntityPotion entitypotion = new EntityPotion(this.world, this, PotionUtil.a(new ItemStack(Items.SPLASH_POTION), potionregistry));
|
|
||||||
+ // Paper start
|
+ // Paper start
|
||||||
+ ItemStack potion = PotionUtil.a(new ItemStack(Items.SPLASH_POTION), potionregistry);
|
+ ItemStack potion = PotionUtil.a(new ItemStack(Items.SPLASH_POTION), potionregistry);
|
||||||
+ com.destroystokyo.paper.event.entity.WitchThrowPotionEvent event = new com.destroystokyo.paper.event.entity.WitchThrowPotionEvent((org.bukkit.entity.Witch) this.getBukkitEntity(), (org.bukkit.entity.LivingEntity) entityliving.getBukkitEntity(), org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(potion));
|
+ com.destroystokyo.paper.event.entity.WitchThrowPotionEvent event = new com.destroystokyo.paper.event.entity.WitchThrowPotionEvent((org.bukkit.entity.Witch) this.getBukkitEntity(), (org.bukkit.entity.LivingEntity) entityliving.getBukkitEntity(), org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(potion));
|
||||||
@ -21,11 +20,14 @@ index 0d579c7e47..62f99fc3b7 100644
|
|||||||
+ return;
|
+ return;
|
||||||
+ }
|
+ }
|
||||||
+ potion = org.bukkit.craftbukkit.inventory.CraftItemStack.asNMSCopy(event.getPotion());
|
+ potion = org.bukkit.craftbukkit.inventory.CraftItemStack.asNMSCopy(event.getPotion());
|
||||||
+ EntityPotion entitypotion = new EntityPotion(this.world, this, potion);
|
EntityPotion entitypotion = new EntityPotion(this.world, this);
|
||||||
|
-
|
||||||
|
- entitypotion.setItem(PotionUtil.a(new ItemStack(Items.SPLASH_POTION), potionregistry));
|
||||||
|
+ entitypotion.setItem(potion);
|
||||||
+ // Paper end
|
+ // Paper end
|
||||||
|
|
||||||
entitypotion.pitch -= -20.0F;
|
entitypotion.pitch -= -20.0F;
|
||||||
entitypotion.shoot(d1, d2 + (double) (f1 * 0.2F), d3, 0.75F, 8.0F);
|
entitypotion.shoot(d0, d1 + (double) (f1 * 0.2F), d2, 0.75F, 8.0F);
|
||||||
|
this.world.a((EntityHuman) null, this.locX, this.locY, this.locZ, SoundEffects.ENTITY_WITCH_THROW, this.getSoundCategory(), 1.0F, 0.8F + this.random.nextFloat() * 0.4F);
|
||||||
--
|
--
|
||||||
2.21.0
|
2.21.0
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From ee9295648e6b091a34abda3af8c24f48153c3253 Mon Sep 17 00:00:00 2001
|
From 50cdaa7cbf2d7b274416a5ddf8beedd4faba2fa7 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Mon, 4 Jun 2018 20:39:20 -0400
|
Date: Mon, 4 Jun 2018 20:39:20 -0400
|
||||||
Subject: [PATCH] Allow spawning Item entities with World.spawnEntity
|
Subject: [PATCH] Allow spawning Item entities with World.spawnEntity
|
||||||
@ -8,10 +8,10 @@ This API has more capabilities than .dropItem with the Consumer function
|
|||||||
Item can be set inside of the Consumer pre spawn function.
|
Item can be set inside of the Consumer pre spawn function.
|
||||||
|
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||||
index 1ed6e86855..1cc42edae8 100644
|
index ab54624d6..3ed9d3f47 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||||
@@ -1070,6 +1070,10 @@ public class CraftWorld implements World {
|
@@ -1236,6 +1236,10 @@ public class CraftWorld implements World {
|
||||||
if (Boat.class.isAssignableFrom(clazz)) {
|
if (Boat.class.isAssignableFrom(clazz)) {
|
||||||
entity = new EntityBoat(world, x, y, z);
|
entity = new EntityBoat(world, x, y, z);
|
||||||
entity.setPositionRotation(x, y, z, yaw, pitch);
|
entity.setPositionRotation(x, y, z, yaw, pitch);
|
@ -1,14 +1,14 @@
|
|||||||
From d2c614b2a47fdc650f7d86e1f79969022c48d1eb Mon Sep 17 00:00:00 2001
|
From d504fafc40b766c15453a3dda97e1351ec889280 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Tue, 5 Jun 2018 22:47:26 -0400
|
Date: Tue, 5 Jun 2018 22:47:26 -0400
|
||||||
Subject: [PATCH] WitchReadyPotionEvent
|
Subject: [PATCH] WitchReadyPotionEvent
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityWitch.java b/src/main/java/net/minecraft/server/EntityWitch.java
|
diff --git a/src/main/java/net/minecraft/server/EntityWitch.java b/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
index 62f99fc3b7..feedfc9d9c 100644
|
index b9307d380..ae9efb72c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityWitch.java
|
--- a/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityWitch.java
|
+++ b/src/main/java/net/minecraft/server/EntityWitch.java
|
||||||
@@ -100,7 +100,11 @@ public class EntityWitch extends EntityMonster implements IRangedEntity {
|
@@ -121,7 +121,11 @@ public class EntityWitch extends EntityRaider implements IRangedEntity {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (potionregistry != null) {
|
if (potionregistry != null) {
|
||||||
@ -18,9 +18,9 @@ index 62f99fc3b7..feedfc9d9c 100644
|
|||||||
+ org.bukkit.inventory.ItemStack bukkitStack = com.destroystokyo.paper.event.entity.WitchReadyPotionEvent.process((org.bukkit.entity.Witch) this.getBukkitEntity(), org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(potion));
|
+ org.bukkit.inventory.ItemStack bukkitStack = com.destroystokyo.paper.event.entity.WitchReadyPotionEvent.process((org.bukkit.entity.Witch) this.getBukkitEntity(), org.bukkit.craftbukkit.inventory.CraftItemStack.asCraftMirror(potion));
|
||||||
+ this.setSlot(EnumItemSlot.MAINHAND, org.bukkit.craftbukkit.inventory.CraftItemStack.asNMSCopy(bukkitStack));
|
+ this.setSlot(EnumItemSlot.MAINHAND, org.bukkit.craftbukkit.inventory.CraftItemStack.asNMSCopy(bukkitStack));
|
||||||
+ // Paper end
|
+ // Paper end
|
||||||
this.bC = this.getItemInMainHand().k();
|
this.bB = this.getItemInMainHand().k();
|
||||||
this.a(true);
|
this.s(true);
|
||||||
this.world.a((EntityHuman) null, this.locX, this.locY, this.locZ, SoundEffects.ENTITY_WITCH_DRINK, this.bV(), 1.0F, 0.8F + this.random.nextFloat() * 0.4F);
|
this.world.a((EntityHuman) null, this.locX, this.locY, this.locZ, SoundEffects.ENTITY_WITCH_DRINK, this.getSoundCategory(), 1.0F, 0.8F + this.random.nextFloat() * 0.4F);
|
||||||
--
|
--
|
||||||
2.21.0
|
2.21.0
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From c386a2b894d68b0d9cc0cd0710b616de0585cf4b Mon Sep 17 00:00:00 2001
|
From 221b24670380be1789c502a52c5adf4ae9edf22b Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Tue, 5 Jun 2018 23:00:29 -0400
|
Date: Tue, 5 Jun 2018 23:00:29 -0400
|
||||||
Subject: [PATCH] ItemStack#getMaxItemUseDuration
|
Subject: [PATCH] ItemStack#getMaxItemUseDuration
|
||||||
@ -6,22 +6,22 @@ Subject: [PATCH] ItemStack#getMaxItemUseDuration
|
|||||||
Allows you to determine how long it takes to use a usable/consumable item
|
Allows you to determine how long it takes to use a usable/consumable item
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
|
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
|
||||||
index 927394333a..c1b6eb52bf 100644
|
index b7d327211..2acd02f2f 100644
|
||||||
--- a/src/main/java/net/minecraft/server/ItemStack.java
|
--- a/src/main/java/net/minecraft/server/ItemStack.java
|
||||||
+++ b/src/main/java/net/minecraft/server/ItemStack.java
|
+++ b/src/main/java/net/minecraft/server/ItemStack.java
|
||||||
@@ -548,6 +548,7 @@ public final class ItemStack {
|
@@ -545,6 +545,7 @@ public final class ItemStack {
|
||||||
this.getItem().b(this, world, entityhuman);
|
this.getItem().b(this, world, entityhuman);
|
||||||
}
|
}
|
||||||
|
|
||||||
+ public int getItemUseMaxDuration() { return k(); } // Paper - OBFHELPER
|
+ public int getItemUseMaxDuration() { return k(); } // Paper - OBFHELPER
|
||||||
public int k() {
|
public int k() {
|
||||||
return this.getItem().c(this);
|
return this.getItem().f_(this);
|
||||||
}
|
}
|
||||||
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
|
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
|
||||||
index 69faeb9c09..bc8fb28163 100644
|
index 4d8013685..1a7849767 100644
|
||||||
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
|
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
|
||||||
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
|
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemStack.java
|
||||||
@@ -184,6 +184,13 @@ public final class CraftItemStack extends ItemStack {
|
@@ -174,6 +174,13 @@ public final class CraftItemStack extends ItemStack {
|
||||||
return (handle == null) ? Material.AIR.getMaxStackSize() : handle.getItem().getMaxStackSize();
|
return (handle == null) ? Material.AIR.getMaxStackSize() : handle.getItem().getMaxStackSize();
|
||||||
}
|
}
|
||||||
|
|
@ -1,14 +1,14 @@
|
|||||||
From c366ba96ccf88a22ec175dc58f4c31ec647be0c1 Mon Sep 17 00:00:00 2001
|
From f86419891df8d7944efd7630b3b4ce5f8a9d51a9 Mon Sep 17 00:00:00 2001
|
||||||
From: Shane Freeder <theboyetronic@gmail.com>
|
From: Shane Freeder <theboyetronic@gmail.com>
|
||||||
Date: Sat, 9 Jun 2018 14:08:39 +0200
|
Date: Sat, 9 Jun 2018 14:08:39 +0200
|
||||||
Subject: [PATCH] Implement EntityTeleportEndGatewayEvent
|
Subject: [PATCH] Implement EntityTeleportEndGatewayEvent
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/TileEntityEndGateway.java b/src/main/java/net/minecraft/server/TileEntityEndGateway.java
|
diff --git a/src/main/java/net/minecraft/server/TileEntityEndGateway.java b/src/main/java/net/minecraft/server/TileEntityEndGateway.java
|
||||||
index d2b29ecbe0..2af225021b 100644
|
index 5dd670615..734d04c09 100644
|
||||||
--- a/src/main/java/net/minecraft/server/TileEntityEndGateway.java
|
--- a/src/main/java/net/minecraft/server/TileEntityEndGateway.java
|
||||||
+++ b/src/main/java/net/minecraft/server/TileEntityEndGateway.java
|
+++ b/src/main/java/net/minecraft/server/TileEntityEndGateway.java
|
||||||
@@ -138,8 +138,19 @@ public class TileEntityEndGateway extends TileEntityEnderPortal implements ITick
|
@@ -144,8 +144,19 @@ public class TileEntityEndGateway extends TileEntityEnderPortal implements ITick
|
||||||
|
|
||||||
}
|
}
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
@ -1,4 +1,4 @@
|
|||||||
From 9c180725949eeb8017beef9b50987cb1660c74f8 Mon Sep 17 00:00:00 2001
|
From 0dca0b4450442373fd420c8ec714f858a394bcca Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Sun, 10 Jun 2018 01:18:49 -0400
|
Date: Sun, 10 Jun 2018 01:18:49 -0400
|
||||||
Subject: [PATCH] Unset Ignited flag on cancel of Explosion Event
|
Subject: [PATCH] Unset Ignited flag on cancel of Explosion Event
|
||||||
@ -6,19 +6,19 @@ Subject: [PATCH] Unset Ignited flag on cancel of Explosion Event
|
|||||||
Otherwise the creeper infinite explodes
|
Otherwise the creeper infinite explodes
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/EntityCreeper.java b/src/main/java/net/minecraft/server/EntityCreeper.java
|
diff --git a/src/main/java/net/minecraft/server/EntityCreeper.java b/src/main/java/net/minecraft/server/EntityCreeper.java
|
||||||
index b6af429044..a07337ae40 100644
|
index 9f03d0337..29569805c 100644
|
||||||
--- a/src/main/java/net/minecraft/server/EntityCreeper.java
|
--- a/src/main/java/net/minecraft/server/EntityCreeper.java
|
||||||
+++ b/src/main/java/net/minecraft/server/EntityCreeper.java
|
+++ b/src/main/java/net/minecraft/server/EntityCreeper.java
|
||||||
@@ -12,7 +12,7 @@ public class EntityCreeper extends EntityMonster {
|
@@ -11,7 +11,7 @@ public class EntityCreeper extends EntityMonster {
|
||||||
|
|
||||||
private static final DataWatcherObject<Integer> a = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.b);
|
private static final DataWatcherObject<Integer> b = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.b);
|
||||||
private static final DataWatcherObject<Boolean> b = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.i);
|
private static final DataWatcherObject<Boolean> POWERED = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.i);
|
||||||
- private static final DataWatcherObject<Boolean> c = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.i);
|
- private static final DataWatcherObject<Boolean> d = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.i);
|
||||||
+ private static final DataWatcherObject<Boolean> c = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.i);private static final DataWatcherObject<Boolean> isIgnitedDW = c; // Paper OBFHELPER
|
+ private static final DataWatcherObject<Boolean> d = DataWatcher.a(EntityCreeper.class, DataWatcherRegistry.i); private static final DataWatcherObject<Boolean> isIgnitedDW = d; // Paper OBFHELPER
|
||||||
private int bC;
|
private int bz;
|
||||||
private int fuseTicks;
|
private int fuseTicks;
|
||||||
public int maxFuseTicks = 30;
|
public int maxFuseTicks = 30;
|
||||||
@@ -205,6 +205,7 @@ public class EntityCreeper extends EntityMonster {
|
@@ -216,6 +216,7 @@ public class EntityCreeper extends EntityMonster {
|
||||||
this.createEffectCloud();
|
this.createEffectCloud();
|
||||||
} else {
|
} else {
|
||||||
fuseTicks = 0;
|
fuseTicks = 0;
|
@ -1,21 +0,0 @@
|
|||||||
From 93b5a6f9f10f7e599af102f0c960f6d63d347ea3 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Kyle Wood <demonwav@gmail.com>
|
|
||||||
Date: Thu, 1 Mar 2018 19:38:14 -0600
|
|
||||||
Subject: [PATCH] Load version history at server start
|
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/DedicatedServer.java b/src/main/java/net/minecraft/server/DedicatedServer.java
|
|
||||||
index 0d2c7a6dc4..437ac386ac 100644
|
|
||||||
--- a/src/main/java/net/minecraft/server/DedicatedServer.java
|
|
||||||
+++ b/src/main/java/net/minecraft/server/DedicatedServer.java
|
|
||||||
@@ -212,6 +212,7 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
com.destroystokyo.paper.PaperConfig.registerCommands();
|
|
||||||
+ com.destroystokyo.paper.VersionHistoryManager.INSTANCE.getClass(); // load version history now
|
|
||||||
// Paper end
|
|
||||||
|
|
||||||
DedicatedServer.LOGGER.info("Generating keypair");
|
|
||||||
--
|
|
||||||
2.21.0
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user