30 lines
994 B
Java
30 lines
994 B
Java
package com.bgsoftware.wildloaders.nms.v1_18_R2.mappings.net.minecraft.world.item;
|
|
|
|
import com.bgsoftware.common.remaps.Remap;
|
|
import com.bgsoftware.wildloaders.nms.v1_18_R2.mappings.MappedObject;
|
|
import com.bgsoftware.wildloaders.nms.v1_18_R2.mappings.net.minecraft.nbt.NBTTagCompound;
|
|
|
|
public class ItemStack extends MappedObject<net.minecraft.world.item.ItemStack> {
|
|
|
|
public ItemStack(net.minecraft.world.item.ItemStack handle) {
|
|
super(handle);
|
|
}
|
|
|
|
@Remap(classPath = "net.minecraft.world.item.ItemStack",
|
|
name = "getOrCreateTag",
|
|
type = Remap.Type.METHOD,
|
|
remappedName = "u")
|
|
public NBTTagCompound getOrCreateTag() {
|
|
return new NBTTagCompound(handle.u());
|
|
}
|
|
|
|
@Remap(classPath = "net.minecraft.world.item.ItemStack",
|
|
name = "getTag",
|
|
type = Remap.Type.METHOD,
|
|
remappedName = "t")
|
|
public NBTTagCompound getTag() {
|
|
return NBTTagCompound.ofNullable(handle.t());
|
|
}
|
|
|
|
}
|