Fix bug I was getting with ShopItem
This commit is contained in:
parent
5cdd502d11
commit
76dc735b6b
@ -1,13 +1,13 @@
|
|||||||
package mineplex.core.shop.item;
|
package mineplex.core.shop.item;
|
||||||
|
|
||||||
import mineplex.core.common.util.UtilInv;
|
|
||||||
import net.minecraft.server.v1_7_R4.NBTTagList;
|
|
||||||
import net.minecraft.server.v1_7_R4.NBTTagString;
|
|
||||||
|
|
||||||
import org.bukkit.ChatColor;
|
import org.bukkit.ChatColor;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
import org.bukkit.craftbukkit.v1_7_R4.inventory.CraftItemStack;
|
import org.bukkit.craftbukkit.v1_7_R4.inventory.CraftItemStack;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
import net.minecraft.server.v1_7_R4.NBTTagList;
|
||||||
|
import net.minecraft.server.v1_7_R4.NBTTagString;
|
||||||
|
|
||||||
|
import mineplex.core.common.util.UtilInv;
|
||||||
|
|
||||||
public class ShopItem extends CraftItemStack
|
public class ShopItem extends CraftItemStack
|
||||||
{
|
{
|
||||||
@ -27,7 +27,8 @@ public class ShopItem extends CraftItemStack
|
|||||||
_displayItem = displayItem;
|
_displayItem = displayItem;
|
||||||
_deliveryAmount = deliveryAmount;
|
_deliveryAmount = deliveryAmount;
|
||||||
|
|
||||||
getHandle().tag = ((CraftItemStack)itemStack).getHandle().tag;
|
CraftItemStack craftItem = CraftItemStack.asCraftCopy(itemStack);
|
||||||
|
getHandle().tag = craftItem.getHandle().tag;
|
||||||
|
|
||||||
UpdateVisual(true);
|
UpdateVisual(true);
|
||||||
getHandle().tag.set("AttributeModifiers", new NBTTagList());
|
getHandle().tag.set("AttributeModifiers", new NBTTagList());
|
||||||
|
Loading…
Reference in New Issue
Block a user