方块实体的NBT保存问题 #104
方块实体的NBT保存问题
#104
Replies: 2 comments 7 replies
-
|
你注册了吗? |
Beta Was this translation helpful? Give feedback.
3 replies
-
请保证 TileEntity 类型含有一个零参数构造器。 |
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
SeraphJACK
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
我按照教程对
readFromNBT和writeToNBT进行了覆写,但重新载入地图后nbt还是会被清空。我开始尝试各种方法找原因,我先是尝试了数据同步,结果还是不行。之后我通过调试发现
writeToNBT虽然能正常调用但每次tag都是空的,我开始怀疑问题的原因是writeToNBT没有保存,但我没办法确认他是不是真的没有保存 因为我不知道成功的情况下tag是否也是空的,这是我的代码:Beta Was this translation helpful? Give feedback.
All reactions