NBT-API

NBT-API

98.9k Downloads

Get value of NBTCompound as Object

CollidaCube opened this issue ยท 2 comments

commented

I don't care what type the value is, I just need the Object value of it. Is there a way I can do something like this?

NBTCompound comp = ...;
Object value = comp.getValue("somekey");
commented

I mean, the best it could return is the NBT-wrapped object, which wouldn't be of much help. You could make yourself a helper method that checks the type, and then grabs it.

commented

Closing as stale.