Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 20:40:07 +01:00
842e040c19
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: 220bc594 #486: Add method to get player's attack cooldown 21853d39 SPIGOT-5681: Increase max plugin channel size 5b972adc Improve build process b55e58d9 Note which custom generator is missing required method CraftBukkit Changes:893ad93b
#650: Add method to get player's attack cooldownef706b06
#655: Added support for the VM tag jansi.passthrough when processing messages sent to a ColouredConsoleSender.e0cfb347
SPIGOT-5689: Fireball.setDirection increases velocity too much94cb030f
SPIGOT-5673: swingHand API does not show to selfb331a055
SPIGOT-5680: isChunkGenerated creates empty region filese1335932
Improve build processa8ec1d60
Add a couple of method null checks to CraftWorldce66f693
Misc checkstyle fixes8bd0e9ab
SPIGOT-5669: Fix Beehive.isSedated Spigot Changes: 2040c4c4 SPIGOT-5677, MC-114796: Fix portals generating outside world border ab8f6b5a Rebuild patches e7dc2f53 Rebuild patches
28 Zeilen
1.4 KiB
Diff
28 Zeilen
1.4 KiB
Diff
From 25caaaa1941940964265ef43367036d28837e9dc Mon Sep 17 00:00:00 2001
|
|
From: Aikar <aikar@aikar.co>
|
|
Date: Mon, 4 Jun 2018 20:39:20 -0400
|
|
Subject: [PATCH] Allow spawning Item entities with World.spawnEntity
|
|
|
|
This API has more capabilities than .dropItem with the Consumer 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
|
|
index 7d73fe4c59..2575228cb0 100644
|
|
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
|
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
|
@@ -1493,6 +1493,10 @@ public class CraftWorld implements World {
|
|
if (Boat.class.isAssignableFrom(clazz)) {
|
|
entity = new EntityBoat(world, x, y, z);
|
|
entity.setPositionRotation(x, y, z, yaw, pitch);
|
|
+ // Paper start
|
|
+ } else if (org.bukkit.entity.Item.class.isAssignableFrom(clazz)) {
|
|
+ entity = new EntityItem(world, x, y, z, new net.minecraft.server.ItemStack(net.minecraft.server.Item.getItemOf(net.minecraft.server.Blocks.DIRT)));
|
|
+ // Paper end
|
|
} else if (FallingBlock.class.isAssignableFrom(clazz)) {
|
|
entity = new EntityFallingBlock(world, x, y, z, world.getType(new BlockPosition(x, y, z)));
|
|
} else if (Projectile.class.isAssignableFrom(clazz)) {
|
|
--
|
|
2.26.2
|
|
|