Anti Xray v2 (#858)

This commit is contained in:
stonar96 2017-10-05 14:38:21 +01:00
parent 4632195902
commit 3a9f17bc4b
49 changed files with 1695 additions and 153 deletions

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Activation Range Improvements
Fixes and adds new Immunities to improve gameplay behavior
diff --git a/src/main/java/net/minecraft/server/EntityCreature.java b/src/main/java/net/minecraft/server/EntityCreature.java
index 0c82c6f5..9659a45e 100644
index 0c82c6f5b..9659a45ef 100644
--- a/src/main/java/net/minecraft/server/EntityCreature.java
+++ b/src/main/java/net/minecraft/server/EntityCreature.java
@@ -0,0 +0,0 @@ public abstract class EntityCreature extends EntityInsentient {
@ -18,7 +18,7 @@ index 0c82c6f5..9659a45e 100644
private float b;
private final float c;
diff --git a/src/main/java/net/minecraft/server/EntityLiving.java b/src/main/java/net/minecraft/server/EntityLiving.java
index e50f7a3c..194d55c3 100644
index 3086a36f9..b437ebf26 100644
--- a/src/main/java/net/minecraft/server/EntityLiving.java
+++ b/src/main/java/net/minecraft/server/EntityLiving.java
@@ -0,0 +0,0 @@ public abstract class EntityLiving extends Entity {
@ -31,7 +31,7 @@ index e50f7a3c..194d55c3 100644
protected int ticksFarFromPlayer;
protected float aW;
diff --git a/src/main/java/net/minecraft/server/EntityLlama.java b/src/main/java/net/minecraft/server/EntityLlama.java
index dbda68dd..af49b727 100644
index dbda68dd0..af49b7273 100644
--- a/src/main/java/net/minecraft/server/EntityLlama.java
+++ b/src/main/java/net/minecraft/server/EntityLlama.java
@@ -0,0 +0,0 @@ public class EntityLlama extends EntityHorseChestedAbstract implements IRangedEn
@ -43,7 +43,7 @@ index dbda68dd..af49b727 100644
return this.bL != null;
}
diff --git a/src/main/java/net/minecraft/server/PathfinderGoal.java b/src/main/java/net/minecraft/server/PathfinderGoal.java
index 83d9c43f..1cb6652c 100644
index 83d9c43f3..1cb6652c2 100644
--- a/src/main/java/net/minecraft/server/PathfinderGoal.java
+++ b/src/main/java/net/minecraft/server/PathfinderGoal.java
@@ -0,0 +0,0 @@ public abstract class PathfinderGoal {
@ -59,7 +59,7 @@ index 83d9c43f..1cb6652c 100644
public void e() {}
diff --git a/src/main/java/net/minecraft/server/PathfinderGoalGotoTarget.java b/src/main/java/net/minecraft/server/PathfinderGoalGotoTarget.java
index e5b5e988..e3781f3a 100644
index e5b5e9887..e3781f3a8 100644
--- a/src/main/java/net/minecraft/server/PathfinderGoalGotoTarget.java
+++ b/src/main/java/net/minecraft/server/PathfinderGoalGotoTarget.java
@@ -0,0 +0,0 @@ package net.minecraft.server;
@ -96,7 +96,7 @@ index e5b5e988..e3781f3a 100644
}
}
diff --git a/src/main/java/org/spigotmc/ActivationRange.java b/src/main/java/org/spigotmc/ActivationRange.java
index 47865c02..b0856461 100644
index 47865c027..b08564618 100644
--- a/src/main/java/org/spigotmc/ActivationRange.java
+++ b/src/main/java/org/spigotmc/ActivationRange.java
@@ -0,0 +0,0 @@ import net.minecraft.server.EntityFireball;

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Add API methods to control if armour stands can move
diff --git a/src/main/java/net/minecraft/server/EntityArmorStand.java b/src/main/java/net/minecraft/server/EntityArmorStand.java
index b0324509..036498c0 100644
index 5603a3746..fcbfcd6a9 100644
--- a/src/main/java/net/minecraft/server/EntityArmorStand.java
+++ b/src/main/java/net/minecraft/server/EntityArmorStand.java
@@ -0,0 +0,0 @@ public class EntityArmorStand extends EntityLiving {
@ -31,7 +31,7 @@ index b0324509..036498c0 100644
+ // Paper end
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java
index 2b66a08a..8a06cb16 100644
index 2b66a08ad..8a06cb165 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftArmorStand.java
@@ -0,0 +0,0 @@ public class CraftArmorStand extends CraftLivingEntity implements ArmorStand {

View file

@ -66,7 +66,7 @@ index 7f011aef8..6ac89d1e3 100644
vec3d1 = new Vec3D(movingobjectposition.pos.x, movingobjectposition.pos.y, movingobjectposition.pos.z);
}
diff --git a/src/main/java/net/minecraft/server/EntityProjectile.java b/src/main/java/net/minecraft/server/EntityProjectile.java
index 3d3c1f5f9..0415c521d 100644
index cfcaf3832..01c7fcc8b 100644
--- a/src/main/java/net/minecraft/server/EntityProjectile.java
+++ b/src/main/java/net/minecraft/server/EntityProjectile.java
@@ -0,0 +0,0 @@ public abstract class EntityProjectile extends Entity implements IProjectile {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Add fromBottle flag to Experience Orbs
diff --git a/src/main/java/net/minecraft/server/EntityExperienceOrb.java b/src/main/java/net/minecraft/server/EntityExperienceOrb.java
index ec23eb98..dab33b25 100644
index ec23eb98c..dab33b25a 100644
--- a/src/main/java/net/minecraft/server/EntityExperienceOrb.java
+++ b/src/main/java/net/minecraft/server/EntityExperienceOrb.java
@@ -0,0 +0,0 @@ public class EntityExperienceOrb extends Entity {
@ -37,7 +37,7 @@ index ec23eb98..dab33b25 100644
return false;
}
diff --git a/src/main/java/net/minecraft/server/EntityThrownExpBottle.java b/src/main/java/net/minecraft/server/EntityThrownExpBottle.java
index 0255986f..28931295 100644
index 0255986fd..289312950 100644
--- a/src/main/java/net/minecraft/server/EntityThrownExpBottle.java
+++ b/src/main/java/net/minecraft/server/EntityThrownExpBottle.java
@@ -0,0 +0,0 @@ public class EntityThrownExpBottle extends EntityProjectile {
@ -50,7 +50,7 @@ index 0255986f..28931295 100644
this.die();
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftExperienceOrb.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftExperienceOrb.java
index 3a09cab3..61e3c6c3 100644
index 3a09cab3d..61e3c6c3e 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftExperienceOrb.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftExperienceOrb.java
@@ -0,0 +0,0 @@ public class CraftExperienceOrb extends CraftEntity implements ExperienceOrb {

View file

@ -39,7 +39,7 @@ index 3cc13bdc4..a8f5117bc 100644
}
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
index 65b69574e..5c8cd73ea 100644
index 751989f5a..2b11f68f4 100644
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Add option to remove invalid statistics
diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java
index da0984a3..28917f63 100644
index da0984a35..28917f63d 100644
--- a/src/main/java/com/destroystokyo/paper/PaperConfig.java
+++ b/src/main/java/com/destroystokyo/paper/PaperConfig.java
@@ -0,0 +0,0 @@ public class PaperConfig {
@ -23,7 +23,7 @@ index da0984a3..28917f63 100644
+ }
}
diff --git a/src/main/java/net/minecraft/server/ServerStatisticManager.java b/src/main/java/net/minecraft/server/ServerStatisticManager.java
index 14af226f..e3d2c0ff 100644
index 14af226f3..e3d2c0ff7 100644
--- a/src/main/java/net/minecraft/server/ServerStatisticManager.java
+++ b/src/main/java/net/minecraft/server/ServerStatisticManager.java
@@ -0,0 +0,0 @@ public class ServerStatisticManager extends StatisticManager {

View file

@ -11,7 +11,7 @@ to make books with as much data as they want. Do not use this without
limiting incoming data from packets in some other way.
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java
index 5d971f07..6a7d1034 100644
index 5d971f07b..6a7d10344 100644
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaBook.java
@@ -0,0 +0,0 @@ public class CraftMetaBook extends CraftMetaItem implements BookMeta {

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Allow specifying a custom "authentication servers down" kick
diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java
index f4b23703..f5cb9799 100644
index f4b237034..f5cb9799b 100644
--- a/src/main/java/com/destroystokyo/paper/PaperConfig.java
+++ b/src/main/java/com/destroystokyo/paper/PaperConfig.java
@@ -0,0 +0,0 @@
@ -27,7 +27,7 @@ index f4b23703..f5cb9799 100644
+ }
}
diff --git a/src/main/java/net/minecraft/server/LoginListener.java b/src/main/java/net/minecraft/server/LoginListener.java
index c5434e6b..75df9283 100644
index c5434e6ba..75df92836 100644
--- a/src/main/java/net/minecraft/server/LoginListener.java
+++ b/src/main/java/net/minecraft/server/LoginListener.java
@@ -0,0 +0,0 @@ public class LoginListener implements PacketLoginInListener, ITickable {

File diff suppressed because it is too large Load diff

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Assign the World in WorldGenStronghold
diff --git a/src/main/java/net/minecraft/server/WorldGenStronghold.java b/src/main/java/net/minecraft/server/WorldGenStronghold.java
index c9375470..a3b958e0 100644
index c93754704..a3b958e01 100644
--- a/src/main/java/net/minecraft/server/WorldGenStronghold.java
+++ b/src/main/java/net/minecraft/server/WorldGenStronghold.java
@@ -0,0 +0,0 @@ public class WorldGenStronghold extends StructureGenerator {

View file

@ -11,7 +11,7 @@ that is outside happens to be closer, but unreachable, yet another reachable
one is in border that would of been missed.
diff --git a/src/main/java/net/minecraft/server/StructureGenerator.java b/src/main/java/net/minecraft/server/StructureGenerator.java
index 078957aa..7b635d3f 100644
index 078957aac..7b635d3fa 100644
--- a/src/main/java/net/minecraft/server/StructureGenerator.java
+++ b/src/main/java/net/minecraft/server/StructureGenerator.java
@@ -0,0 +0,0 @@ public abstract class StructureGenerator extends WorldGenBase {
@ -25,7 +25,7 @@ index 078957aa..7b635d3f 100644
if (!flag1 || !world.b(l2, i3)) {
return new BlockPosition((l2 << 4) + 8, 64, (i3 << 4) + 8);
diff --git a/src/main/java/net/minecraft/server/WorldBorder.java b/src/main/java/net/minecraft/server/WorldBorder.java
index 632eb1c9..1bb172bb 100644
index 632eb1c9d..1bb172bbf 100644
--- a/src/main/java/net/minecraft/server/WorldBorder.java
+++ b/src/main/java/net/minecraft/server/WorldBorder.java
@@ -0,0 +0,0 @@ public class WorldBorder {

View file

@ -27,7 +27,7 @@ index 70af657f5..af953dda4 100644
+ }
}
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
index 147f00fe8..d34ec4ff1 100644
index b4318e4f7..d744477c9 100644
--- a/src/main/java/net/minecraft/server/Entity.java
+++ b/src/main/java/net/minecraft/server/Entity.java
@@ -0,0 +0,0 @@ public abstract class Entity implements ICommandListener {

View file

@ -9,7 +9,7 @@ Also allow turning off treasure maps all together as they can eat up Map ID's
which are limited in quantity.
diff --git a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
index a80d8b2a..32ca0a40 100644
index a80d8b2ac..32ca0a40e 100644
--- a/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
+++ b/src/main/java/com/destroystokyo/paper/PaperWorldConfig.java
@@ -0,0 +0,0 @@ public class PaperWorldConfig {
@ -28,7 +28,7 @@ index a80d8b2a..32ca0a40 100644
+ }
}
diff --git a/src/main/java/net/minecraft/server/EntityVillager.java b/src/main/java/net/minecraft/server/EntityVillager.java
index ae68f07a..35221dec 100644
index ae68f07ab..35221decf 100644
--- a/src/main/java/net/minecraft/server/EntityVillager.java
+++ b/src/main/java/net/minecraft/server/EntityVillager.java
@@ -0,0 +0,0 @@ public class EntityVillager extends EntityAgeable implements NPC, IMerchant {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Do not allow a zero max height in BiomeJungle
diff --git a/src/main/java/net/minecraft/server/BiomeJungle.java b/src/main/java/net/minecraft/server/BiomeJungle.java
index 8f67cb36..8dc0b623 100644
index 8f67cb36c..8dc0b6238 100644
--- a/src/main/java/net/minecraft/server/BiomeJungle.java
+++ b/src/main/java/net/minecraft/server/BiomeJungle.java
@@ -0,0 +0,0 @@ public class BiomeJungle extends BiomeBase {
@ -22,7 +22,7 @@ index 8f67cb36..8dc0b623 100644
(new WorldGenMelon()).generate(world, random, blockposition.a(i, k, j));
WorldGenVines worldgenvines = new WorldGenVines();
diff --git a/src/main/java/net/minecraft/server/BlockPosition.java b/src/main/java/net/minecraft/server/BlockPosition.java
index 6a0b3a62..38a7af58 100644
index 6a0b3a62d..38a7af58c 100644
--- a/src/main/java/net/minecraft/server/BlockPosition.java
+++ b/src/main/java/net/minecraft/server/BlockPosition.java
@@ -0,0 +0,0 @@ public class BlockPosition extends BaseBlockPosition {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Do not let armorstands drown
diff --git a/src/main/java/net/minecraft/server/EntityArmorStand.java b/src/main/java/net/minecraft/server/EntityArmorStand.java
index 036498c09..f25ee9061 100644
index fcbfcd6a9..7899324ed 100644
--- a/src/main/java/net/minecraft/server/EntityArmorStand.java
+++ b/src/main/java/net/minecraft/server/EntityArmorStand.java
@@ -0,0 +0,0 @@ public class EntityArmorStand extends EntityLiving {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Don't allow entities to ride themselves - #572
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
index 314d1df4..147f00fe 100644
index e0ae1f7dd..b4318e4f7 100644
--- a/src/main/java/net/minecraft/server/Entity.java
+++ b/src/main/java/net/minecraft/server/Entity.java
@@ -0,0 +0,0 @@ public abstract class Entity implements ICommandListener {

View file

@ -5,7 +5,7 @@ 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
index 0a8d8a1a..e6b469a0 100644
index ffd4d836b..a042c37c7 100644
--- a/src/main/java/net/minecraft/server/Entity.java
+++ b/src/main/java/net/minecraft/server/Entity.java
@@ -0,0 +0,0 @@ public abstract class Entity implements ICommandListener {
@ -18,7 +18,7 @@ index 0a8d8a1a..e6b469a0 100644
public int dimension;
protected BlockPosition an;
diff --git a/src/main/java/net/minecraft/server/EntityFishingHook.java b/src/main/java/net/minecraft/server/EntityFishingHook.java
index 339d1f1b..7f011aef 100644
index 339d1f1b1..7f011aef8 100644
--- a/src/main/java/net/minecraft/server/EntityFishingHook.java
+++ b/src/main/java/net/minecraft/server/EntityFishingHook.java
@@ -0,0 +0,0 @@ public class EntityFishingHook extends Entity {

View file

@ -7,7 +7,7 @@ Unloading Chunks async is extremely dangerous. This will force it to main
the same way we handle async chunk loads.
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index 7ea64362..a606f6ce 100644
index 00dd2976d..1f37fa47e 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -0,0 +0,0 @@ public class CraftWorld implements World {

View file

@ -7,7 +7,7 @@ Saving players async is extremely dangerous. This will force it to main
the same way we handle async chunk loads.
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
index 73cf2e3d8..206068384 100644
index 953e5f901..acec81a92 100644
--- a/src/main/java/net/minecraft/server/PlayerList.java
+++ b/src/main/java/net/minecraft/server/PlayerList.java
@@ -0,0 +0,0 @@ public abstract class PlayerList {

View file

@ -49,7 +49,7 @@ index 0562c6e34..06b064a78 100644
if ( entity.world.spigotConfig.nerfSpawnerMobs )
{
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
index 437c3da11..0ada29f4f 100644
index 9429ae1ab..248477661 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftEntity.java
@@ -0,0 +0,0 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Firework API's
diff --git a/src/main/java/net/minecraft/server/EntityFireworks.java b/src/main/java/net/minecraft/server/EntityFireworks.java
index 48cdef5d..bd0ec95f 100644
index 48cdef5db..bd0ec95f2 100644
--- a/src/main/java/net/minecraft/server/EntityFireworks.java
+++ b/src/main/java/net/minecraft/server/EntityFireworks.java
@@ -0,0 +0,0 @@ package net.minecraft.server;
@ -53,7 +53,7 @@ index 48cdef5d..bd0ec95f 100644
public boolean bd() {
diff --git a/src/main/java/net/minecraft/server/ItemFireworks.java b/src/main/java/net/minecraft/server/ItemFireworks.java
index b0bb4aa2..44a99721 100644
index b0bb4aa23..44a997215 100644
--- a/src/main/java/net/minecraft/server/ItemFireworks.java
+++ b/src/main/java/net/minecraft/server/ItemFireworks.java
@@ -0,0 +0,0 @@ public class ItemFireworks extends Item {
@ -73,7 +73,7 @@ index b0bb4aa2..44a99721 100644
if (!entityhuman.abilities.canInstantlyBuild) {
itemstack.subtract(1);
diff --git a/src/main/java/net/minecraft/server/NBTTagCompound.java b/src/main/java/net/minecraft/server/NBTTagCompound.java
index e15c2336..82c2537b 100644
index e15c23367..82c2537b3 100644
--- a/src/main/java/net/minecraft/server/NBTTagCompound.java
+++ b/src/main/java/net/minecraft/server/NBTTagCompound.java
@@ -0,0 +0,0 @@ public class NBTTagCompound extends NBTBase {
@ -86,7 +86,7 @@ index e15c2336..82c2537b 100644
}
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftFirework.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftFirework.java
index 99746b3c..d4fbe31d 100644
index 99746b3c2..d4fbe31d6 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftFirework.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftFirework.java
@@ -0,0 +0,0 @@

View file

@ -10,7 +10,7 @@ Was done incorrectly and is now causing level desyncs to client.
Always send current level to the client, and instead make setWindowProperty set the level.
diff --git a/src/main/java/net/minecraft/server/ContainerAnvil.java b/src/main/java/net/minecraft/server/ContainerAnvil.java
index 04f117ace..e3897a3f7 100644
index 175753c5a..16ec67569 100644
--- a/src/main/java/net/minecraft/server/ContainerAnvil.java
+++ b/src/main/java/net/minecraft/server/ContainerAnvil.java
@@ -0,0 +0,0 @@ public class ContainerAnvil extends Container {
@ -26,7 +26,7 @@ index 04f117ace..e3897a3f7 100644
this.lastLevelCost = this.levelCost;
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 005c8a00b..c9a707e7e 100644
index f30613672..6642001e7 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -0,0 +0,0 @@ public class CraftPlayer extends CraftHumanEntity implements Player {

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Fix NFE when attempting to read EMPTY ItemStack
Thanks @gabizou
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
index 3aefb023..8c7f57bc 100644
index 3aefb023e..8c7f57bc7 100644
--- a/src/main/java/net/minecraft/server/ItemStack.java
+++ b/src/main/java/net/minecraft/server/ItemStack.java
@@ -0,0 +0,0 @@ public final class ItemStack {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Fix block break desync
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
index dd6cbe947..65b69574e 100644
index bcc6c9707..751989f5a 100644
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {

View file

@ -9,7 +9,7 @@ modified in order to prevent merge conflicts when Spigot changes/disables the wa
and to provide some level of hint without being disruptive.
diff --git a/src/main/java/org/bukkit/craftbukkit/Main.java b/src/main/java/org/bukkit/craftbukkit/Main.java
index c9e8a8737..ae2c51f5d 100644
index d3d848f8c..21628e196 100644
--- a/src/main/java/org/bukkit/craftbukkit/Main.java
+++ b/src/main/java/org/bukkit/craftbukkit/Main.java
@@ -0,0 +0,0 @@ public class Main {

View file

@ -6,7 +6,7 @@ Subject: [PATCH] IllegalPacketEvent
Fired for invalid data from players that represents hacking attempts
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
index 98a63dc0e..f82a81178 100644
index 02b5e3cad..52e8458ab 100644
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
@@ -0,0 +0,0 @@ import org.bukkit.inventory.CraftingInventory;

View file

@ -8,7 +8,7 @@ Fixes falling dragon eggs in lazy chunks fall to the block below the last empty
See also https://bugs.mojang.com/browse/MC-94186
diff --git a/src/main/java/net/minecraft/server/BlockDragonEgg.java b/src/main/java/net/minecraft/server/BlockDragonEgg.java
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
index ce186f825..291342c90 100644
--- a/src/main/java/net/minecraft/server/BlockDragonEgg.java
+++ b/src/main/java/net/minecraft/server/BlockDragonEgg.java
@@ -0,0 +0,0 @@ public class BlockDragonEgg extends Block {

View file

@ -44,7 +44,7 @@ index 71524f2cd..288c52c55 100644
}
diff --git a/src/main/java/net/minecraft/server/CommandAbstract.java b/src/main/java/net/minecraft/server/CommandAbstract.java
index 14a7b9c92..8b703db42 100644
index 76501e299..67cadecbb 100644
--- a/src/main/java/net/minecraft/server/CommandAbstract.java
+++ b/src/main/java/net/minecraft/server/CommandAbstract.java
@@ -0,0 +0,0 @@ public abstract class CommandAbstract implements ICommand {
@ -83,6 +83,28 @@ index 14a7b9c92..8b703db42 100644
return this.a((ICommand) object);
}
diff --git a/src/main/java/net/minecraft/server/RegistryBlockID.java b/src/main/java/net/minecraft/server/RegistryBlockID.java
index 58f47d0de..8860a0129 100644
--- a/src/main/java/net/minecraft/server/RegistryBlockID.java
+++ b/src/main/java/net/minecraft/server/RegistryBlockID.java
@@ -0,0 +0,0 @@ import java.util.Iterator;
import java.util.List;
import javax.annotation.Nullable;
-public class RegistryBlockID<T> implements Registry<T> {
+public class RegistryBlockID<T> implements Registry { // Paper - Fix decompile error
private final IdentityHashMap<T, Integer> a;
private final List<T> b;
@@ -0,0 +0,0 @@ public class RegistryBlockID<T> implements Registry<T> {
this.a.put(t0, Integer.valueOf(i));
while (this.b.size() <= i) {
- this.b.add((Object) null);
+ this.b.add(null); // Paper - Fix decompile error
}
this.b.set(i, t0);
diff --git a/src/test/java/org/bukkit/craftbukkit/inventory/ItemFactoryTest.java b/src/test/java/org/bukkit/craftbukkit/inventory/ItemFactoryTest.java
index f5bcbdbe1..3190cadfc 100644
--- a/src/test/java/org/bukkit/craftbukkit/inventory/ItemFactoryTest.java

View file

@ -5,9 +5,18 @@ Subject: [PATCH] MC Utils
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
index 38d69b944..7fee74d80 100644
index 4bbebb25a..c4d9344a7 100644
--- a/src/main/java/net/minecraft/server/Chunk.java
+++ b/src/main/java/net/minecraft/server/Chunk.java
@@ -0,0 +0,0 @@ import org.bukkit.Server; // CraftBukkit
public class Chunk {
private static final Logger e = LogManager.getLogger();
- public static final ChunkSection a = null;
+ public static final ChunkSection a = null; public static final ChunkSection EMPTY_CHUNK_SECTION = Chunk.a; // Paper - OBFHELPER
private final ChunkSection[] sections;
private final byte[] g;
private final int[] h;
@@ -0,0 +0,0 @@ public class Chunk {
return !block.isTileEntity() ? null : ((ITileEntity) block).a(this.world, iblockdata.getBlock().toLegacyData(iblockdata));
}
@ -16,6 +25,19 @@ index 38d69b944..7fee74d80 100644
@Nullable
public TileEntity a(BlockPosition blockposition, Chunk.EnumTileEntityState chunk_enumtileentitystate) {
// CraftBukkit start
diff --git a/src/main/java/net/minecraft/server/DataPaletteBlock.java b/src/main/java/net/minecraft/server/DataPaletteBlock.java
index 1f2fe87b6..2cb462b8e 100644
--- a/src/main/java/net/minecraft/server/DataPaletteBlock.java
+++ b/src/main/java/net/minecraft/server/DataPaletteBlock.java
@@ -0,0 +0,0 @@ import javax.annotation.Nullable;
public class DataPaletteBlock implements DataPaletteExpandable {
private static final DataPalette d = new DataPaletteGlobal();
- protected static final IBlockData a = Blocks.AIR.getBlockData();
+ protected static final IBlockData a = Blocks.AIR.getBlockData(); public static final IBlockData DEFAULT_BLOCK_DATA = DataPaletteBlock.a; // Paper - OBFHELPER
protected DataBits b;
protected DataPalette c;
private int e;
diff --git a/src/main/java/net/minecraft/server/MCUtil.java b/src/main/java/net/minecraft/server/MCUtil.java
new file mode 100644
index 000000000..1159eea1a

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Make targetSize more aggressive in the chunk unload queue
diff --git a/src/main/java/net/minecraft/server/ChunkProviderServer.java b/src/main/java/net/minecraft/server/ChunkProviderServer.java
index 9159ed02..e54f4f47 100644
index 73554a518..2558ba8c3 100644
--- a/src/main/java/net/minecraft/server/ChunkProviderServer.java
+++ b/src/main/java/net/minecraft/server/ChunkProviderServer.java
@@ -0,0 +0,0 @@ public class ChunkProviderServer implements IChunkProvider {

View file

@ -5,7 +5,7 @@ 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 5a76821e..858bbef5 100644
index 5a76821ea..858bbef5b 100644
--- a/src/main/java/net/minecraft/server/EntityOcelot.java
+++ b/src/main/java/net/minecraft/server/EntityOcelot.java
@@ -0,0 +0,0 @@ public class EntityOcelot extends EntityTameableAnimal {

View file

@ -1,86 +0,0 @@
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Alfie Cleveland <alfeh@me.com>
Date: Fri, 25 Nov 2016 20:35:05 +0000
Subject: [PATCH] Optimise NetworkManager
diff --git a/src/main/java/net/minecraft/server/NetworkManager.java b/src/main/java/net/minecraft/server/NetworkManager.java
index d583cced..89743d2b 100644
--- a/src/main/java/net/minecraft/server/NetworkManager.java
+++ b/src/main/java/net/minecraft/server/NetworkManager.java
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
}
};
private final EnumProtocolDirection h;
- private final Queue<NetworkManager.QueuedPacket> i = Queues.newConcurrentLinkedQueue();
- private final ReentrantReadWriteLock j = new ReentrantReadWriteLock();
+ // private final Queue<NetworkManager.QueuedPacket> i = Queues.newConcurrentLinkedQueue(); // Paper
+ // private final ReentrantReadWriteLock j = new ReentrantReadWriteLock(); // Paper
public Channel channel;
// Spigot Start // PAIL
public SocketAddress l;
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
if (this.isConnected()) {
this.m();
this.a(packet, (GenericFutureListener[]) null);
- } else {
- this.j.writeLock().lock();
-
- try {
- this.i.add(new NetworkManager.QueuedPacket(packet, new GenericFutureListener[0]));
- } finally {
- this.j.writeLock().unlock();
- }
}
-
}
public void sendPacket(Packet<?> packet, GenericFutureListener<? extends Future<? super Void>> genericfuturelistener, GenericFutureListener<? extends Future<? super Void>>... agenericfuturelistener) {
if (this.isConnected()) {
this.m();
this.a(packet, (GenericFutureListener[]) ArrayUtils.add(agenericfuturelistener, 0, genericfuturelistener));
- } else {
- this.j.writeLock().lock();
-
- try {
- this.i.add(new NetworkManager.QueuedPacket(packet, (GenericFutureListener[]) ArrayUtils.add(agenericfuturelistener, 0, genericfuturelistener)));
- } finally {
- this.j.writeLock().unlock();
- }
}
-
}
private void a(final Packet<?> packet, @Nullable final GenericFutureListener<? extends Future<? super Void>>[] agenericfuturelistener) {
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
}
private void m() {
- if (this.channel != null && this.channel.isOpen()) {
- this.j.readLock().lock();
-
- try {
- while (!this.i.isEmpty()) {
- NetworkManager.QueuedPacket networkmanager_queuedpacket = (NetworkManager.QueuedPacket) this.i.poll();
-
- this.a(networkmanager_queuedpacket.a, networkmanager_queuedpacket.b);
- }
- } finally {
- this.j.readLock().unlock();
- }
-
- }
+ // Paper - Contents removed
}
public void a() {
@@ -0,0 +0,0 @@ public class NetworkManager extends SimpleChannelInboundHandler<Packet<?>> {
} else if (this.i() != null) {
this.i().a(new ChatMessage("multiplayer.disconnect.generic", new Object[0]));
}
- this.i.clear(); // Free up packet queue.
+ // this.i.clear(); // Free up packet queue. // Paper - remove unneeded packet queue
}
}
--

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Optimise removeQueue
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java
index 8fb569be..df2e607d 100644
index e8b78b51a..53147c6e2 100644
--- a/src/main/java/net/minecraft/server/EntityPlayer.java
+++ b/src/main/java/net/minecraft/server/EntityPlayer.java
@@ -0,0 +0,0 @@ package net.minecraft.server;

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Optimize ItemStack.isEmpty()
Remove hashMap lookup every check, simplify code to remove ternary
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
index 0dcea61d..3aefb023 100644
index 0dcea61d2..3aefb023e 100644
--- a/src/main/java/net/minecraft/server/ItemStack.java
+++ b/src/main/java/net/minecraft/server/ItemStack.java
@@ -0,0 +0,0 @@ public final class ItemStack {

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Optimize World.isLoaded(BlockPosition)Z
Reduce method invocations for World.isLoaded(BlockPosition)Z
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 6b368216e..de11ef617 100644
index a2b5926a1..445936c7b 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -0,0 +0,0 @@ public abstract class World implements IBlockAccess {

View file

@ -19,7 +19,7 @@ index 32ca0a40e..70af657f5 100644
+ }
}
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index 5bd721814..12938b9f8 100644
index 843c944ab..30cf4a251 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -0,0 +0,0 @@ public abstract class World implements IBlockAccess {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] PlayerAttemptPickupItemEvent
diff --git a/src/main/java/net/minecraft/server/EntityItem.java b/src/main/java/net/minecraft/server/EntityItem.java
index fed1f4ab2..a580a5866 100644
index ae4910b4b..b56d1a35e 100644
--- a/src/main/java/net/minecraft/server/EntityItem.java
+++ b/src/main/java/net/minecraft/server/EntityItem.java
@@ -0,0 +0,0 @@ import org.apache.logging.log4j.Logger;

View file

@ -6,7 +6,7 @@ Subject: [PATCH] PlayerTeleportEndGatewayEvent
Allows you to access the Gateway being used in a teleport event
diff --git a/src/main/java/net/minecraft/server/TileEntityEndGateway.java b/src/main/java/net/minecraft/server/TileEntityEndGateway.java
index 9bde14d9..ab2cd176 100644
index cfce9274a..ecbc48b0c 100644
--- a/src/main/java/net/minecraft/server/TileEntityEndGateway.java
+++ b/src/main/java/net/minecraft/server/TileEntityEndGateway.java
@@ -0,0 +0,0 @@ public class TileEntityEndGateway extends TileEntityEnderPortal implements ITick

View file

@ -6,7 +6,7 @@ Subject: [PATCH] Prevent Pathfinding out of World Border
This prevents Entities from trying to run outside of the World Border
diff --git a/src/main/java/net/minecraft/server/NavigationAbstract.java b/src/main/java/net/minecraft/server/NavigationAbstract.java
index 3ac6f84d..935b2e81 100644
index 3ac6f84d3..935b2e81e 100644
--- a/src/main/java/net/minecraft/server/NavigationAbstract.java
+++ b/src/main/java/net/minecraft/server/NavigationAbstract.java
@@ -0,0 +0,0 @@ public abstract class NavigationAbstract {
@ -26,7 +26,7 @@ index 3ac6f84d..935b2e81 100644
if (this.c != null && !this.c.b() && blockposition.equals(this.q)) {
return this.c;
diff --git a/src/main/java/net/minecraft/server/WorldBorder.java b/src/main/java/net/minecraft/server/WorldBorder.java
index 9038d52e..632eb1c9 100644
index 9038d52eb..632eb1c9d 100644
--- a/src/main/java/net/minecraft/server/WorldBorder.java
+++ b/src/main/java/net/minecraft/server/WorldBorder.java
@@ -0,0 +0,0 @@ public class WorldBorder {

View file

@ -7,7 +7,7 @@ Adds a Pre Lookup Event and a Post Lookup Event so that plugins may prefill in p
profiles that had to be looked up.
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index ea2c57137..a2acf1b3e 100644
index e8bddc171..0e255861d 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -0,0 +0,0 @@ public abstract class MinecraftServer implements ICommandListener, Runnable, IAs

View file

@ -19,7 +19,7 @@ index 53147c6e2..5fbb99b7e 100644
@Override
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
index f82a81178..1dc9ddbb5 100644
index 52e8458ab..bcc6c9707 100644
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
@@ -0,0 +0,0 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {

View file

@ -30,7 +30,7 @@ will have plugins and worlds saving to the disk has a high potential to result
in corruption/dataloss.
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
index 005e3449f..a4f44b39b 100644
index 13c6b5ccd..908a5d273 100644
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
@@ -0,0 +0,0 @@ public abstract class MinecraftServer implements ICommandListener, Runnable, IAs

View file

@ -7,7 +7,7 @@ Provides counts without the ineffeciency of using .getEntities().size()
which creates copy of the collections.
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
index 416e86af..7ea64362 100644
index 67cb2230b..00dd2976d 100644
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
@@ -0,0 +0,0 @@ public class CraftWorld implements World {

View file

@ -9,7 +9,7 @@ One report of a suspected memory leak with the system.
This adds additional overhead to asynchronous task dispatching
diff --git a/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java b/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
index e30cfb7b..448c27cc 100644
index bce411288..e47f4cca2 100644
--- a/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
+++ b/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
@@ -0,0 +0,0 @@ public class CraftScheduler implements BukkitScheduler {

View file

@ -12,7 +12,7 @@ This then triggers async chunk loads!
What in the hell were you thinking?
diff --git a/src/main/java/net/minecraft/server/BlockBeacon.java b/src/main/java/net/minecraft/server/BlockBeacon.java
index f07ac018..21075974 100644
index f07ac0186..21075974d 100644
--- a/src/main/java/net/minecraft/server/BlockBeacon.java
+++ b/src/main/java/net/minecraft/server/BlockBeacon.java
@@ -0,0 +0,0 @@ public class BlockBeacon extends BlockTileEntity {

View file

@ -5,7 +5,7 @@ Subject: [PATCH] Shoulder Entities Release API
diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java
index f5e25e63d..c74095554 100644
index a8f5117bc..e9f48ecad 100644
--- a/src/main/java/net/minecraft/server/EntityHuman.java
+++ b/src/main/java/net/minecraft/server/EntityHuman.java
@@ -0,0 +0,0 @@ public abstract class EntityHuman extends EntityLiving {
@ -62,7 +62,7 @@ index f5e25e63d..c74095554 100644
public abstract boolean isSpectator();
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
index 25e1e5a3f..463dddc98 100644
index 90df0ae1c..4cce0920e 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
@@ -0,0 +0,0 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {

View file

@ -7,7 +7,7 @@ This ensures that Shulker Boxes can never drop their contents twice, and
that the inventory is cleared incase it some how also got saved to the world.
diff --git a/src/main/java/net/minecraft/server/BlockShulkerBox.java b/src/main/java/net/minecraft/server/BlockShulkerBox.java
index 8811eb3e..74e2e448 100644
index 8811eb3e3..74e2e448f 100644
--- a/src/main/java/net/minecraft/server/BlockShulkerBox.java
+++ b/src/main/java/net/minecraft/server/BlockShulkerBox.java
@@ -0,0 +0,0 @@ public class BlockShulkerBox extends BlockTileEntity {

View file

@ -21,7 +21,7 @@ This is based upon conclusions drawn from inspecting the assenmbly generated byt
They had 'callq' (invoke) instead of 'mov' (get from memory) instructions.
diff --git a/src/main/java/net/minecraft/server/BaseBlockPosition.java b/src/main/java/net/minecraft/server/BaseBlockPosition.java
index 679d5504..8e737718 100644
index 679d5504e..8e737718e 100644
--- a/src/main/java/net/minecraft/server/BaseBlockPosition.java
+++ b/src/main/java/net/minecraft/server/BaseBlockPosition.java
@@ -0,0 +0,0 @@ import javax.annotation.concurrent.Immutable;
@ -66,7 +66,7 @@ index 679d5504..8e737718 100644
public BaseBlockPosition d(BaseBlockPosition baseblockposition) {
return new BaseBlockPosition(this.getY() * baseblockposition.getZ() - this.getZ() * baseblockposition.getY(), this.getZ() * baseblockposition.getX() - this.getX() * baseblockposition.getZ(), this.getX() * baseblockposition.getY() - this.getY() * baseblockposition.getX());
diff --git a/src/main/java/net/minecraft/server/BlockPosition.java b/src/main/java/net/minecraft/server/BlockPosition.java
index b3c1f550..6a0b3a62 100644
index b3c1f550c..6a0b3a62d 100644
--- a/src/main/java/net/minecraft/server/BlockPosition.java
+++ b/src/main/java/net/minecraft/server/BlockPosition.java
@@ -0,0 +0,0 @@ public class BlockPosition extends BaseBlockPosition {

View file

@ -60,6 +60,7 @@ import ControllerJump
import DataBits
import DataConverterMaterialId
import DataInspectorBlockEntity
import DataPalette
import DefinedStructure
import EntityLlama
import EULA
@ -75,6 +76,7 @@ import NBTTagCompound
import NBTTagList
import PersistentScoreboard
import PacketPlayInUseEntity
import PacketPlayOutMapChunk
import PacketPlayOutPlayerListHeaderFooter
import PacketPlayOutScoreboardTeam
import PacketPlayOutTitle
@ -87,6 +89,7 @@ import PathfinderWater
import PersistentVillage
import PlayerConnectionUtils
import RegionFile
import RegistryBlockID
import RemoteControlListener
import TileEntityEnderChest
import TileEntityLootable