3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-17 03:50:08 +01:00

[Auto] Updated Upstream (Bukkit/CraftBukkit)

Upstream has released updates that appears to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing

Bukkit Changes:
4b9a93ec Add BatToggleSleepEvent

CraftBukkit Changes:
a222e4a2 Implement BatToggleSleepEvent
Dieser Commit ist enthalten in:
Aikar 2018-09-17 03:06:34 -04:00
Ursprung 32c9917149
Commit f95ffce1af
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 401ADFC9891FAAFE
11 geänderte Dateien mit 64 neuen und 64 gelöschten Zeilen

Datei anzeigen

@ -1,11 +1,11 @@
From 681b02dd72d0d81713197b5e1db3f089d4239b0a Mon Sep 17 00:00:00 2001
From e7414eb657029523360d06b5b799af2885ffeac1 Mon Sep 17 00:00:00 2001
From: AlphaBlend <whizkid3000@hotmail.com>
Date: Sun, 16 Oct 2016 23:19:30 -0700
Subject: [PATCH] Add EntityZapEvent
diff --git a/src/main/java/net/minecraft/server/EntityPig.java b/src/main/java/net/minecraft/server/EntityPig.java
index fecc7e154d..b405e63e81 100644
index fecc7e154..b405e63e8 100644
--- a/src/main/java/net/minecraft/server/EntityPig.java
+++ b/src/main/java/net/minecraft/server/EntityPig.java
@@ -152,6 +152,12 @@ public class EntityPig extends EntityAnimal {
@ -22,7 +22,7 @@ index fecc7e154d..b405e63e81 100644
if (CraftEventFactory.callPigZapEvent(this, entitylightning, entitypigzombie).isCancelled()) {
return;
diff --git a/src/main/java/net/minecraft/server/EntityVillager.java b/src/main/java/net/minecraft/server/EntityVillager.java
index 32e327e42c..5aebdba56c 100644
index 32e327e42..5aebdba56 100644
--- a/src/main/java/net/minecraft/server/EntityVillager.java
+++ b/src/main/java/net/minecraft/server/EntityVillager.java
@@ -610,6 +610,12 @@ public class EntityVillager extends EntityAgeable implements NPC, IMerchant {
@ -48,10 +48,10 @@ index 32e327e42c..5aebdba56c 100644
}
}
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 002c483e1e..bd094eef8a 100644
index 58b64a671..9a8bf6e74 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -710,6 +710,14 @@ public class CraftEventFactory {
@@ -711,6 +711,14 @@ public class CraftEventFactory {
return event;
}
@ -67,5 +67,5 @@ index 002c483e1e..bd094eef8a 100644
HorseJumpEvent event = new HorseJumpEvent((AbstractHorse) horse.getBukkitEntity(), power);
horse.getBukkitEntity().getServer().getPluginManager().callEvent(event);
--
2.18.0
2.19.0

Datei anzeigen

@ -1,11 +1,11 @@
From 5f5a14dac2d1cdc06244646c0032b338d0ce66ab Mon Sep 17 00:00:00 2001
From 74c2079bb29c3189e14a810c2c8e2f1301fd9156 Mon Sep 17 00:00:00 2001
From: AlphaBlend <whizkid3000@hotmail.com>
Date: Thu, 8 Sep 2016 08:48:33 -0700
Subject: [PATCH] Add source to PlayerExpChangeEvent
diff --git a/src/main/java/net/minecraft/server/EntityExperienceOrb.java b/src/main/java/net/minecraft/server/EntityExperienceOrb.java
index 33b24c833b..880f496526 100644
index 33b24c833..880f49652 100644
--- a/src/main/java/net/minecraft/server/EntityExperienceOrb.java
+++ b/src/main/java/net/minecraft/server/EntityExperienceOrb.java
@@ -185,7 +185,7 @@ public class EntityExperienceOrb extends Entity {
@ -18,10 +18,10 @@ index 33b24c833b..880f496526 100644
this.die();
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index bd094eef8a..3c498c56eb 100644
index 9a8bf6e74..07f47977f 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -48,6 +48,7 @@ import org.bukkit.entity.Player;
@@ -49,6 +49,7 @@ import org.bukkit.entity.Player;
import org.bukkit.entity.Projectile;
import org.bukkit.entity.ThrownExpBottle;
import org.bukkit.entity.ThrownPotion;
@ -29,7 +29,7 @@ index bd094eef8a..3c498c56eb 100644
import org.bukkit.event.Cancellable;
import org.bukkit.event.Event;
import org.bukkit.event.block.*;
@@ -679,6 +680,17 @@ public class CraftEventFactory {
@@ -680,6 +681,17 @@ public class CraftEventFactory {
return event;
}
@ -48,5 +48,5 @@ index bd094eef8a..3c498c56eb 100644
return handleBlockGrowEvent(world, pos, block, 3);
}
--
2.18.0
2.19.0

Datei anzeigen

@ -1,11 +1,11 @@
From e6c073eebee251cb71ae1c5ea572b793cc9bde64 Mon Sep 17 00:00:00 2001
From 9702c25b3b10d921eaa19c92d0631b08ee806395 Mon Sep 17 00:00:00 2001
From: Techcable <Techcable@outlook.com>
Date: Fri, 16 Dec 2016 21:25:39 -0600
Subject: [PATCH] Add ProjectileCollideEvent
diff --git a/src/main/java/net/minecraft/server/EntityArrow.java b/src/main/java/net/minecraft/server/EntityArrow.java
index c24225892f..187f02d4e4 100644
index c24225892..187f02d4e 100644
--- a/src/main/java/net/minecraft/server/EntityArrow.java
+++ b/src/main/java/net/minecraft/server/EntityArrow.java
@@ -195,6 +195,16 @@ public abstract class EntityArrow extends Entity implements IProjectile {
@ -26,7 +26,7 @@ index c24225892f..187f02d4e4 100644
this.a(movingobjectposition);
this.impulse = true;
diff --git a/src/main/java/net/minecraft/server/EntityFireball.java b/src/main/java/net/minecraft/server/EntityFireball.java
index 3e3619d79f..58cc4824cf 100644
index 3e3619d79..58cc4824c 100644
--- a/src/main/java/net/minecraft/server/EntityFireball.java
+++ b/src/main/java/net/minecraft/server/EntityFireball.java
@@ -68,6 +68,15 @@ public abstract class EntityFireball extends Entity {
@ -46,7 +46,7 @@ index 3e3619d79f..58cc4824cf 100644
this.a(movingobjectposition);
diff --git a/src/main/java/net/minecraft/server/EntityFishingHook.java b/src/main/java/net/minecraft/server/EntityFishingHook.java
index 62e8f27aa7..81de03084a 100644
index 62e8f27aa..81de03084 100644
--- a/src/main/java/net/minecraft/server/EntityFishingHook.java
+++ b/src/main/java/net/minecraft/server/EntityFishingHook.java
@@ -245,6 +245,16 @@ public class EntityFishingHook extends Entity {
@ -67,7 +67,7 @@ index 62e8f27aa7..81de03084a 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 ee402d4140..fc8c0cab55 100644
index ee402d414..fc8c0cab5 100644
--- a/src/main/java/net/minecraft/server/EntityProjectile.java
+++ b/src/main/java/net/minecraft/server/EntityProjectile.java
@@ -144,6 +144,15 @@ public abstract class EntityProjectile extends Entity implements IProjectile {
@ -87,10 +87,10 @@ index ee402d4140..fc8c0cab55 100644
if (movingobjectposition.type == MovingObjectPosition.EnumMovingObjectType.BLOCK && this.world.getType(movingobjectposition.a()).getBlock() == Blocks.NETHER_PORTAL) {
this.e(movingobjectposition.a());
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 3c498c56eb..43ccf4e23c 100644
index 07f47977f..307b59a27 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -814,6 +814,16 @@ public class CraftEventFactory {
@@ -815,6 +815,16 @@ public class CraftEventFactory {
return CraftItemStack.asNMSCopy(bitem);
}
@ -108,5 +108,5 @@ index 3c498c56eb..43ccf4e23c 100644
Projectile bukkitEntity = (Projectile) entity.getBukkitEntity();
ProjectileLaunchEvent event = new ProjectileLaunchEvent(bukkitEntity);
--
2.18.0
2.19.0

Datei anzeigen

@ -1,4 +1,4 @@
From 23371c2a5c2b7b93ceba7a3b95ce559d1d8cffa1 Mon Sep 17 00:00:00 2001
From 47c73c9e33d7ccabf5347e95f0b392c2bea6711b Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Sat, 15 Jun 2013 19:51:17 -0400
Subject: [PATCH] EntityShootBowEvent consumeArrow and getArrowItem API
@ -6,7 +6,7 @@ Subject: [PATCH] EntityShootBowEvent consumeArrow and getArrowItem API
Adds ability to get what arrow was shot, and control if it should be consumed.
diff --git a/src/main/java/net/minecraft/server/EntitySkeletonAbstract.java b/src/main/java/net/minecraft/server/EntitySkeletonAbstract.java
index c2bc8060ac..1ae967d1c0 100644
index c2bc8060a..1ae967d1c 100644
--- a/src/main/java/net/minecraft/server/EntitySkeletonAbstract.java
+++ b/src/main/java/net/minecraft/server/EntitySkeletonAbstract.java
@@ -160,7 +160,7 @@ public abstract class EntitySkeletonAbstract extends EntityMonster implements IR
@ -19,7 +19,7 @@ index c2bc8060ac..1ae967d1c0 100644
event.getProjectile().remove();
return;
diff --git a/src/main/java/net/minecraft/server/ItemBow.java b/src/main/java/net/minecraft/server/ItemBow.java
index b0f7649b82..152b179ce1 100644
index b0f7649b8..152b179ce 100644
--- a/src/main/java/net/minecraft/server/ItemBow.java
+++ b/src/main/java/net/minecraft/server/ItemBow.java
@@ -57,6 +57,7 @@ public class ItemBow extends Item {
@ -58,10 +58,10 @@ index b0f7649b82..152b179ce1 100644
if (itemstack1.isEmpty()) {
entityhuman.inventory.f(itemstack1);
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 89e765e803..92960eb735 100644
index 307b59a27..8295a4c7a 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -244,7 +244,7 @@ public class CraftEventFactory {
@@ -245,7 +245,7 @@ public class CraftEventFactory {
/**
* EntityShootBowEvent
*/
@ -70,7 +70,7 @@ index 89e765e803..92960eb735 100644
LivingEntity shooter = (LivingEntity) who.getBukkitEntity();
CraftItemStack itemInHand = CraftItemStack.asCraftMirror(itemstack);
Arrow arrow = (Arrow) entityArrow.getBukkitEntity();
@@ -253,7 +253,7 @@ public class CraftEventFactory {
@@ -254,7 +254,7 @@ public class CraftEventFactory {
itemInHand = null;
}
@ -80,5 +80,5 @@ index 89e765e803..92960eb735 100644
return event;
--
2.18.0
2.19.0

Datei anzeigen

@ -1,4 +1,4 @@
From c5e7c1fea11313a52ac0d87c6e543f4db56a847c Mon Sep 17 00:00:00 2001
From 0f0fd7a9745f505cd9bc4bc85ae658de25b33581 Mon Sep 17 00:00:00 2001
From: Brokkonaut <hannos17@gmx.de>
Date: Sat, 30 Jun 2018 05:45:39 +0200
Subject: [PATCH] Improve ProjectileHitEvent to include the BlockFace where the
@ -6,10 +6,10 @@ Subject: [PATCH] Improve ProjectileHitEvent to include the BlockFace where the
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index c344c8a9ca..15ae4cb8ea 100644
index 8295a4c7a..29d8773f2 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -838,7 +838,7 @@ public class CraftEventFactory {
@@ -839,7 +839,7 @@ public class CraftEventFactory {
hitBlock = entity.getBukkitEntity().getWorld().getBlockAt(blockposition.getX(), blockposition.getY(), blockposition.getZ());
}
@ -19,5 +19,5 @@ index c344c8a9ca..15ae4cb8ea 100644
return event;
}
--
2.18.0
2.19.0

Datei anzeigen

@ -1,4 +1,4 @@
From f01d6308d059e6754bb682252277fd2121e90f48 Mon Sep 17 00:00:00 2001
From 251f2f64caf0e0bb572e850306e472c82a3d2c08 Mon Sep 17 00:00:00 2001
From: Aikar <aikar@aikar.co>
Date: Tue, 3 Jul 2018 21:56:23 -0400
Subject: [PATCH] InventoryCloseEvent Reason API
@ -7,7 +7,7 @@ Allows you to determine why an inventory was closed, enabling plugin developers
to "confirm" things based on if it was player triggered close or not.
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
index 6bbb737df7..614fce4447 100644
index 6bbb737df..614fce444 100644
--- a/src/main/java/net/minecraft/server/Chunk.java
+++ b/src/main/java/net/minecraft/server/Chunk.java
@@ -900,7 +900,7 @@ public class Chunk implements IChunkAccess {
@ -29,7 +29,7 @@ index 6bbb737df7..614fce4447 100644
}
}
diff --git a/src/main/java/net/minecraft/server/EntityHuman.java b/src/main/java/net/minecraft/server/EntityHuman.java
index 5e13cb0640..c7dc6fe0ef 100644
index 5e13cb064..c7dc6fe0e 100644
--- a/src/main/java/net/minecraft/server/EntityHuman.java
+++ b/src/main/java/net/minecraft/server/EntityHuman.java
@@ -162,7 +162,7 @@ public abstract class EntityHuman extends EntityLiving {
@ -56,7 +56,7 @@ index 5e13cb0640..c7dc6fe0ef 100644
this.activeContainer = this.defaultContainer;
}
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java
index 3644fde3bb..68f5842cfe 100644
index 3644fde3b..68f5842cf 100644
--- a/src/main/java/net/minecraft/server/EntityPlayer.java
+++ b/src/main/java/net/minecraft/server/EntityPlayer.java
@@ -346,7 +346,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
@ -110,7 +110,7 @@ index 3644fde3bb..68f5842cfe 100644
this.m();
}
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
index 5199c1fe4e..06709e0c7f 100644
index ad9053d23..d48f54592 100644
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
@@ -2056,7 +2056,7 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {
@ -123,7 +123,7 @@ index 5199c1fe4e..06709e0c7f 100644
this.player.m();
}
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
index 304cae655d..6d511b6230 100644
index 304cae655..6d511b623 100644
--- a/src/main/java/net/minecraft/server/PlayerList.java
+++ b/src/main/java/net/minecraft/server/PlayerList.java
@@ -422,7 +422,7 @@ public abstract class PlayerList {
@ -136,7 +136,7 @@ index 304cae655d..6d511b6230 100644
PlayerQuitEvent playerQuitEvent = new PlayerQuitEvent(cserver.getPlayer(entityplayer), "\u00A7e" + entityplayer.getName() + " left the game");
cserver.getPluginManager().callEvent(playerQuitEvent);
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
index 92fe80316f..70a4dbe26b 100644
index 92fe80316..70a4dbe26 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
@@ -412,8 +412,13 @@ public class CraftHumanEntity extends CraftLivingEntity implements HumanEntity {
@ -155,7 +155,7 @@ index 92fe80316f..70a4dbe26b 100644
public boolean isBlocking() {
return getHandle().isBlocking();
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 40b590da36..f372f19dec 100644
index 40b590da3..f372f19de 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -740,7 +740,7 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
@ -168,10 +168,10 @@ index 40b590da36..f372f19dec 100644
// Check if the fromWorld and toWorld are the same.
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 15ae4cb8ea..063c1b7fa3 100644
index 29d8773f2..ea787a523 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -928,8 +928,19 @@ public class CraftEventFactory {
@@ -929,8 +929,19 @@ public class CraftEventFactory {
return event;
}
@ -193,5 +193,5 @@ index 15ae4cb8ea..063c1b7fa3 100644
human.activeContainer.transferTo(human.defaultContainer, human.getBukkitEntity());
}
--
2.18.0
2.19.0

Datei anzeigen

@ -1,11 +1,11 @@
From 48d202457a79862fe2914f5e765bc8ba91969cc2 Mon Sep 17 00:00:00 2001
From f406c64032ba93f6307424288ee6e521e2c36c19 Mon Sep 17 00:00:00 2001
From: Hugo Manrique <hugmanrique@gmail.com>
Date: Mon, 23 Jul 2018 14:22:26 +0200
Subject: [PATCH] Vanished players don't have rights
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
index 46399cc9b0..fdc9d96c27 100644
index 46399cc9b..fdc9d96c2 100644
--- a/src/main/java/net/minecraft/server/Entity.java
+++ b/src/main/java/net/minecraft/server/Entity.java
@@ -94,7 +94,7 @@ public abstract class Entity implements INamableTileEntity, ICommandListener, Ke
@ -18,7 +18,7 @@ index 46399cc9b0..fdc9d96c27 100644
protected int k;
private Entity vehicle;
diff --git a/src/main/java/net/minecraft/server/IBlockData.java b/src/main/java/net/minecraft/server/IBlockData.java
index 24ce9137ae..bf06a90312 100644
index 24ce9137a..bf06a9031 100644
--- a/src/main/java/net/minecraft/server/IBlockData.java
+++ b/src/main/java/net/minecraft/server/IBlockData.java
@@ -165,6 +165,7 @@ public interface IBlockData extends IBlockDataHolder<IBlockData> {
@ -30,7 +30,7 @@ index 24ce9137ae..bf06a90312 100644
return this.getBlock().f(this, iblockaccess, blockposition);
}
diff --git a/src/main/java/net/minecraft/server/ItemBlock.java b/src/main/java/net/minecraft/server/ItemBlock.java
index 1cecccef23..afc881d9af 100644
index 1cecccef2..afc881d9a 100644
--- a/src/main/java/net/minecraft/server/ItemBlock.java
+++ b/src/main/java/net/minecraft/server/ItemBlock.java
@@ -70,7 +70,8 @@ public class ItemBlock extends Item {
@ -44,7 +44,7 @@ index 1cecccef23..afc881d9af 100644
BlockCanBuildEvent event = new BlockCanBuildEvent(CraftBlock.at(blockactioncontext.getWorld(), blockactioncontext.getClickPosition()), CraftBlockData.fromData(iblockdata), defaultReturn);
blockactioncontext.getWorld().getServer().getPluginManager().callEvent(event);
diff --git a/src/main/java/net/minecraft/server/VoxelShape.java b/src/main/java/net/minecraft/server/VoxelShape.java
index ea8f1c170a..fdfc0d442e 100644
index ea8f1c170..fdfc0d442 100644
--- a/src/main/java/net/minecraft/server/VoxelShape.java
+++ b/src/main/java/net/minecraft/server/VoxelShape.java
@@ -24,6 +24,7 @@ public abstract class VoxelShape {
@ -64,7 +64,7 @@ index ea8f1c170a..fdfc0d442e 100644
return this.a.a();
}
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
index a0e1eb3ff1..887dba69ce 100644
index 802a3e43d..cb878ced7 100644
--- a/src/main/java/net/minecraft/server/World.java
+++ b/src/main/java/net/minecraft/server/World.java
@@ -1588,6 +1588,37 @@ public abstract class World implements IEntityAccess, GeneratorAccess, IIBlockAc
@ -106,10 +106,10 @@ index a0e1eb3ff1..887dba69ce 100644
if (voxelshape.b()) {
return true;
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 063c1b7fa3..f6b7f7a462 100644
index ea787a523..77c6c0ec1 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -819,6 +819,14 @@ public class CraftEventFactory {
@@ -820,6 +820,14 @@ public class CraftEventFactory {
Projectile projectile = (Projectile) entity.getBukkitEntity();
org.bukkit.entity.Entity collided = position.entity.getBukkitEntity();
com.destroystokyo.paper.event.entity.ProjectileCollideEvent event = new com.destroystokyo.paper.event.entity.ProjectileCollideEvent(projectile, collided);

Datei anzeigen

@ -1,11 +1,11 @@
From 6d8e6a49a7721155163e3b0639970957d5f46899 Mon Sep 17 00:00:00 2001
From dcebaefd1b38c02ae40710ee69b1a420cc5fa34f Mon Sep 17 00:00:00 2001
From: BillyGalbreath <Blake.Galbreath@GMail.com>
Date: Thu, 2 Aug 2018 08:44:35 -0500
Subject: [PATCH] Add hand to bucket events
diff --git a/src/main/java/net/minecraft/server/EntityCow.java b/src/main/java/net/minecraft/server/EntityCow.java
index 5f4f107d5a..b2e50f8532 100644
index 5f4f107d5..b2e50f853 100644
--- a/src/main/java/net/minecraft/server/EntityCow.java
+++ b/src/main/java/net/minecraft/server/EntityCow.java
@@ -65,7 +65,7 @@ public class EntityCow extends EntityAnimal {
@ -18,7 +18,7 @@ index 5f4f107d5a..b2e50f8532 100644
if (event.isCancelled()) {
return false;
diff --git a/src/main/java/net/minecraft/server/ItemBucket.java b/src/main/java/net/minecraft/server/ItemBucket.java
index b63da71512..b0dd30dd12 100644
index b63da7151..b0dd30dd1 100644
--- a/src/main/java/net/minecraft/server/ItemBucket.java
+++ b/src/main/java/net/minecraft/server/ItemBucket.java
@@ -35,7 +35,7 @@ public class ItemBucket extends Item {
@ -67,10 +67,10 @@ index b63da71512..b0dd30dd12 100644
((EntityPlayer) entityhuman).playerConnection.sendPacket(new PacketPlayOutBlockChange(world, blockposition)); // SPIGOT-4238: needed when looking through entity
// TODO: inventory not updated
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index 1f3774c249..e0a012a82b 100644
index 77c6c0ec1..a553c2065 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -168,6 +168,20 @@ public class CraftEventFactory {
@@ -169,6 +169,20 @@ public class CraftEventFactory {
}
private static PlayerEvent getPlayerBucketEvent(boolean isFilling, EntityHuman who, int clickedX, int clickedY, int clickedZ, EnumDirection clickedFace, ItemStack itemstack, net.minecraft.server.Item item) {
@ -91,7 +91,7 @@ index 1f3774c249..e0a012a82b 100644
Player player = (who == null) ? null : (Player) who.getBukkitEntity();
CraftItemStack itemInHand = CraftItemStack.asNewCraftStack(item);
Material bucket = CraftMagicNumbers.getMaterial(itemstack.getItem());
@@ -180,10 +194,10 @@ public class CraftEventFactory {
@@ -181,10 +195,10 @@ public class CraftEventFactory {
PlayerEvent event = null;
if (isFilling) {
@ -105,5 +105,5 @@ index 1f3774c249..e0a012a82b 100644
}
--
2.18.0
2.19.0

Datei anzeigen

@ -1,4 +1,4 @@
From ce2c789269e4675bf3af76a5ec7933563eb0c4b3 Mon Sep 17 00:00:00 2001
From c004ce3cd2aa07cae0ed7ef353f954a9aaa0bd88 Mon Sep 17 00:00:00 2001
From: Phoenix616 <mail@moep.tv>
Date: Tue, 21 Aug 2018 01:39:35 +0100
Subject: [PATCH] Improve death events
@ -306,10 +306,10 @@ index b6cf96e18..96232aa07 100644
public void injectScaledMaxHealth(Collection<AttributeInstance> collection, boolean force) {
diff --git a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
index ef8e7c6f6..83e9a6022 100644
index a553c2065..12e2c0f6e 100644
--- a/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
+++ b/src/main/java/org/bukkit/craftbukkit/event/CraftEventFactory.java
@@ -425,9 +425,16 @@ public class CraftEventFactory {
@@ -426,9 +426,16 @@ public class CraftEventFactory {
public static EntityDeathEvent callEntityDeathEvent(EntityLiving victim, List<org.bukkit.inventory.ItemStack> drops) {
CraftLivingEntity entity = (CraftLivingEntity) victim.getBukkitEntity();
EntityDeathEvent event = new EntityDeathEvent(entity, drops, victim.getExpReward());
@ -326,7 +326,7 @@ index ef8e7c6f6..83e9a6022 100644
victim.expToDrop = event.getDroppedExp();
for (org.bukkit.inventory.ItemStack stack : event.getDrops()) {
@@ -443,8 +450,15 @@ public class CraftEventFactory {
@@ -444,8 +451,15 @@ public class CraftEventFactory {
CraftPlayer entity = victim.getBukkitEntity();
PlayerDeathEvent event = new PlayerDeathEvent(entity, drops, victim.getExpReward(), 0, deathMessage);
event.setKeepInventory(keepInventory);
@ -342,7 +342,7 @@ index ef8e7c6f6..83e9a6022 100644
victim.keepLevel = event.getKeepLevel();
victim.newLevel = event.getNewLevel();
@@ -465,6 +479,31 @@ public class CraftEventFactory {
@@ -466,6 +480,31 @@ public class CraftEventFactory {
return event;
}

@ -1 +1 @@
Subproject commit 47b9cf30ac5f6e61c84c126075932c4b9d123d95
Subproject commit 4b9a93eccfefb73860fbbf6e6ea072676e26ef92

@ -1 +1 @@
Subproject commit 79ada744cba8ddec39bd65adc12adefa9c8a45d3
Subproject commit a222e4a252012ef3b5d6b711f723749ccc14a240