geforkt von Mirrors/Paper
Updated Upstream (Bukkit/CraftBukkit/Spigot)
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: ffc8e4ca SPIGOT-5716: Clarify documentation of MultipleFacing CraftBukkit Changes:d07a78b1
SPIGOT-5716: Clarify documentation of MultipleFacing46a13860
SPIGOT-5718: Block.BreakBlockNaturally does not reflect tool used214ffea9
SPIGOT-5727: GameRule doImmediateRespawn cannot be set per-world Spigot Changes: 2f5d615f SPIGOT-5730: Modernise inventory patch a2bdb119 SPIGOT-5679: Add config option for end portal activation sound Closes #3352
Dieser Commit ist enthalten in:
Ursprung
92497a1b5d
Commit
47f11f19a5
@ -20,11 +20,12 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
+ public boolean breakNaturally(ItemStack item, boolean triggerEffect) {
|
||||
+ // Paper end
|
||||
// Order matters here, need to drop before setting to air so skulls can get their data
|
||||
net.minecraft.server.Block block = this.getNMSBlock();
|
||||
boolean result = false;
|
||||
|
||||
if (block != null && block != Blocks.AIR) {
|
||||
net.minecraft.server.Block.dropItems(getNMS(), world.getMinecraftWorld(), position, world.getTileEntity(position), null, CraftItemStack.asNMSCopy(item));
|
||||
net.minecraft.server.IBlockData iblockdata = this.getNMS();
|
||||
net.minecraft.server.Block block = iblockdata.getBlock();
|
||||
@@ -0,0 +0,0 @@ public class CraftBlock implements Block {
|
||||
// Modelled off EntityHuman#hasBlock
|
||||
if (block != Blocks.AIR && (iblockdata.getMaterial().isAlwaysDestroyable() || nmsItem.canDestroySpecialBlock(iblockdata))) {
|
||||
net.minecraft.server.Block.dropItems(iblockdata, world.getMinecraftWorld(), position, world.getTileEntity(position), null, nmsItem);
|
||||
+ if (triggerEffect) world.triggerEffect(org.bukkit.Effect.STEP_SOUND.getId(), position, net.minecraft.server.Block.getCombinedId(block.getBlockData())); // Paper
|
||||
result = true;
|
||||
}
|
||||
|
@ -118,23 +118,23 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||
@@ -0,0 +0,0 @@ public class WorldServer extends World {
|
||||
{
|
||||
if ( h instanceof org.bukkit.craftbukkit.entity.CraftHumanEntity )
|
||||
{
|
||||
- ( (org.bukkit.craftbukkit.entity.CraftHumanEntity) h).getHandle().closeInventory();
|
||||
+ ( (org.bukkit.craftbukkit.entity.CraftHumanEntity) h).getHandle().closeInventory(org.bukkit.event.inventory.InventoryCloseEvent.Reason.UNLOADED); // Paper
|
||||
}
|
||||
for (TileEntity tileentity : chunk.getTileEntities().values()) {
|
||||
if (tileentity instanceof IInventory) {
|
||||
for (org.bukkit.entity.HumanEntity h : Lists.newArrayList(((IInventory) tileentity).getViewers())) {
|
||||
- h.closeInventory();
|
||||
+ h.closeInventory(org.bukkit.event.inventory.InventoryCloseEvent.Reason.UNLOADED); // Paper
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +0,0 @@ public class WorldServer extends World {
|
||||
{
|
||||
if ( h instanceof org.bukkit.craftbukkit.entity.CraftHumanEntity )
|
||||
{
|
||||
- ( (org.bukkit.craftbukkit.entity.CraftHumanEntity) h).getHandle().closeInventory();
|
||||
+ ( (org.bukkit.craftbukkit.entity.CraftHumanEntity) h).getHandle().closeInventory(org.bukkit.event.inventory.InventoryCloseEvent.Reason.UNLOADED); // Paper
|
||||
}
|
||||
}
|
||||
}
|
||||
// Spigot Start
|
||||
if (entity.getBukkitEntity() instanceof org.bukkit.inventory.InventoryHolder) {
|
||||
for (org.bukkit.entity.HumanEntity h : Lists.newArrayList(((org.bukkit.inventory.InventoryHolder) entity.getBukkitEntity()).getInventory().getViewers())) {
|
||||
- h.closeInventory();
|
||||
+ h.closeInventory(org.bukkit.event.inventory.InventoryCloseEvent.Reason.UNLOADED); // Paper
|
||||
}
|
||||
}
|
||||
// Spigot End
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftHumanEntity.java
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit da9ef3c55fa3bce91f7fdcd77d50171be7297d7d
|
||||
Subproject commit ffc8e4caa484af8f3e4ec2647e546ec0f2b6e95f
|
@ -1 +1 @@
|
||||
Subproject commit 933e9094bfef3b0758f62342f06163bbba1bb6a1
|
||||
Subproject commit d07a78b1f3aa79945600e5e07d5a457909480b40
|
@ -1 +1 @@
|
||||
Subproject commit 2040c4c476931e2b1582cd14e2e4d1e260eb5322
|
||||
Subproject commit 2f5d615f157752a2b28b0986b34cc708d5e77674
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren