mirror of
https://github.com/PaperMC/Paper.git
synced 2025-01-06 02:35:49 +01:00
Fix dispenser removing data from items. Fixes BUKKIT-2045
This commit is contained in:
parent
7dc47892a4
commit
59aaa6a80a
1 changed files with 3 additions and 2 deletions
|
@ -106,8 +106,9 @@ public class BlockDispenser extends BlockContainer {
|
|||
ItemStack itemstack = tileentitydispenser.getItem(i1);
|
||||
|
||||
// CraftBukkit start
|
||||
// Copy item stack, because we want it to have 1 item
|
||||
itemstack = new ItemStack(itemstack.id, 1, itemstack.getData(), itemstack.getEnchantments());
|
||||
// Clone item stack, then set the count to 1
|
||||
itemstack = itemstack.cloneItemStack();
|
||||
itemstack.count = 1;
|
||||
|
||||
double d3 = random.nextDouble() * 0.1D + 0.2D;
|
||||
double motX = (double) b0 * d3;
|
||||
|
|
Loading…
Reference in a new issue