牧野又白给了
如题~
一直想不明白什么是元数据...

美味的曲奇
ItemStack
-Represents a stack of items.
-代表一堆物品

ItemMeta
-This type represents the storage mechanism for auxiliary item data.
-An implementation will handle the creation and application for ItemMeta. This class should not be implemented by a plugin in a live environment.
-此类型表示辅助项数据的存储机制。
-一个实现将处理 ItemMeta 的创建和应用。此类不应由实时环境中的插件实现。

就是说你背包里一个位置放了附魔稿子,这稿子是一个ItemStack对象
而要修改稿子的附魔就需要得到这个ItemStack的ItemMeta ,修改后再设置回去

第一页 上一页 下一页 最后一页