Fix NBT data loss when shift-clicking stacked items in the enchantment table (MC-17431) (#4817)

This commit is contained in:
malte0811 authored and LexManos committed 2018-03-23 17:32:59 -07:00
1 parent f9a2695662
commit 9d8bf87e93
1 file changed
+13
@@ -83,3 +83,16 @@
}
for (int j1 = 0; j1 < 3; ++j1)
@@ -400,10 +382,9 @@
return ItemStack.field_190927_a;
}
- if (itemstack1.func_77942_o() && itemstack1.func_190916_E() == 1)
+ if (itemstack1.func_77942_o())// Forge: Fix MC-17431
{
- ((Slot)this.field_75151_b.get(0)).func_75215_d(itemstack1.func_77946_l());
- itemstack1.func_190920_e(0);
+ ((Slot)this.field_75151_b.get(0)).func_75215_d(itemstack1.func_77979_a(1));
}
else if (!itemstack1.func_190926_b())
{