#initializing a WriteView
8 messages · Page 1 of 1 (latest)
8 messages · Page 1 of 1 (latest)
WriteView nbt2 = new WriteView();
client.player.writeData(nbt2);
MyMod.LOGGER.info("======Start======");
MyMod.LOGGER.info(nbt2.get("XpTotal").toString());
MyMod.LOGGER.info("======Stop======");```
how can I initialize nbt2? cuz this doesn't work in 1.21.6.
are you doing this just to get the xp amount?
nah it's juste an exemple, I need the player's nbt datas
is there any reason you cant just grab it from the player directly rather than serialising it to nbt first