NBT-API

NBT-API

98.9k Downloads

Caused by: de.tr7zw.nbtapi.NbtApiException: [Selfchecked]Method not loaded! 'COMPOUND_SET_UUID'

KingSavaqe opened this issue ยท 5 comments

commented

MC Version: 1.8.9
Plugin Version: v2.9.2 (latest)

[02:51:28 INFO]: prov: NBTAPI v2.9.2
getProvidingPlugin<NBTAPI.class> returns latest nbtapi version.

    <dependency>
        <groupId>de.tr7zw</groupId>
        <artifactId>item-nbt-api-plugin</artifactId>
        <version>2.9.2</version>
    </dependency>

^ dependency being used

Full error log:
[02:51:45 ERROR]: null
org.bukkit.command.CommandException: Unhandled exception executing command 'giftcard' in plugin JurassicGiftcards v1.0
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:47) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:146) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.dispatchCommand(CraftServer.java:666) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PlayerConnection.handleCommand(PlayerConnection.java:1189) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PlayerConnection.a(PlayerConnection.java:1001) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PacketPlayInChat.a(PacketPlayInChat.java:45) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PacketPlayInChat.a(PacketPlayInChat.java:1) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.PlayerConnectionUtils$1.run(SourceFile:13) [patched.jar:git-PaperSpigot-"4c7641d"]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_202]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_202]
at net.minecraft.server.v1_8_R3.SystemUtils.a(SourceFile:44) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:774) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:378) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:713) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:616) [patched.jar:git-PaperSpigot-"4c7641d"]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_202]
Caused by: de.tr7zw.nbtapi.NbtApiException: [Selfchecked]Method not loaded! 'COMPOUND_SET_UUID'
at de.tr7zw.nbtapi.utils.nmsmappings.ReflectionMethod.run(ReflectionMethod.java:176) ~[?:?]
at de.tr7zw.nbtapi.NBTReflectionUtil.setData(NBTReflectionUtil.java:611) ~[?:?]
at de.tr7zw.nbtapi.NBTCompound.setUUID(NBTCompound.java:484) ~[?:?]
at me.kingsavaqe.jurassicgiftcards.inventories.AdminGiftcardInventory.lambda$null$0(AdminGiftcardInventory.java:60) ~[?:?]
at java.util.ArrayList.forEach(ArrayList.java:1257) ~[?:1.8.0_202]
at me.kingsavaqe.jurassicgiftcards.inventories.AdminGiftcardInventory.lambda$setItems$1(AdminGiftcardInventory.java:49) ~[?:?]
at java.util.HashMap.forEach(HashMap.java:1289) ~[?:1.8.0_202]
at me.kingsavaqe.jurassicgiftcards.inventories.AdminGiftcardInventory.setItems(AdminGiftcardInventory.java:48) ~[?:?]
at me.kingsavaqe.jurassicgiftcards.utils.GUIBuilder.open(GUIBuilder.java:32) ~[?:?]
at me.kingsavaqe.jurassicgiftcards.commands.GiftcardsCommand.onCommand(GiftcardsCommand.java:40) ~[?:?]
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:45) ~[patched.jar:git-PaperSpigot-"4c7641d"]
... 15 more

commented

You are using Paper, make sure you are using spigot mapped paper, not mojang mapped.

commented

You are using Paper, make sure you are using spigot mapped paper, not mojang mapped.

I am using PaperSpigot if that's what you mean.
So how do I make sure the plugin handles Spigot Mapped, instead of mojang mapped?

commented

Ah wait, JurassicGiftcards tried to use setUUID in 1.8. That method is 1.14?+ only, when mojang switched from storing uuids as strings to 4 ints. So that plugin needs to use setString instead of setUUID.

Ah ok no worries. Ty :D

commented

Ah wait, JurassicGiftcards tried to use setUUID in 1.8. That method is 1.14?+ only, when mojang switched from storing uuids as strings to 4 ints. So that plugin needs to use setString instead of setUUID.

commented

I might change that in a 3.0 of the API, but currently the commands directly call the nms methods, and since 1.8 doesn't have a setUUID method it fails. 3.0 could maybe auto-use setString instead.