mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-27 23:33:08 +00:00
stackTagCompound -> getTagCompound()
This commit is contained in:
1 parent
9b2dbcbe3e
commit
4ef5840ff9
38 files changed
+300
-300
No files matched your search
@@ -142,22 +142,22 @@ public class ItemBlockCardboardBox extends ItemBlock
|
||||
|
||||
public void setBlockData(ItemStack itemstack, BlockData data)
|
||||
{
|
||||
if(itemstack.stackTagCompound == null)
|
||||
if(itemstack.getTagCompound() == null)
|
||||
{
|
||||
itemstack.setTagCompound(new NBTTagCompound());
|
||||
}
|
||||
|
||||
itemstack.stackTagCompound.setTag("blockData", data.write(new NBTTagCompound()));
|
||||
itemstack.getTagCompound().setTag("blockData", data.write(new NBTTagCompound()));
|
||||
}
|
||||
|
||||
public BlockData getBlockData(ItemStack itemstack)
|
||||
{
|
||||
if(itemstack.stackTagCompound == null || !itemstack.stackTagCompound.hasKey("blockData"))
|
||||
if(itemstack.getTagCompound() == null || !itemstack.getTagCompound().hasKey("blockData"))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
return BlockData.read(itemstack.stackTagCompound.getCompoundTag("blockData"));
|
||||
return BlockData.read(itemstack.getTagCompound().getCompoundTag("blockData"));
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
|
||||
Reference in new issue
Block a user