Open KickHolse opened 2 years ago
constructor NBTContainer#
[Skript] method NBTItem#mergeCompound called with (null (Null)) threw a NullPointerException: null
?
No idea why, probably can be solved from the script file,
[Skript] method NBTItem#mergeCompound called with (null (Null)) threw a NullPointerException: null
how do you work?
I took a look and apparently the problem is with %string%, it must not be accepting strings, do you have any idea how to solve it?
expression %item% with [custom] nbt %string%:
return type: item
get:
if expr-1 = air:
return
set {_nbti} to new NBTItem(expr-1)
{_nbti}.mergeCompound(new NBTContainer(expr-2))
return {_nbti}.getItem()
public NBTContainer(Object nbt) {
super(null, null);
if (nbt == null) {
throw new NullPointerException("The NBT-Object can't be null!");
}
if (!ClassWrapper.NMS_NBTTAGCOMPOUND.getClazz().isAssignableFrom(nbt.getClass())) {
throw new NbtApiException("The object '" + nbt.getClass() + "' is not a valid NBT-Object!");
}
this.nbt = nbt;
}
Hello! Could you update the NBT Api within the plugin? when I try to use it says it needs to update and I can't :(