User Tools

Site Tools


zh_cn:tutorial:datagen_model

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revisionBoth sides next revision
zh_cn:tutorial:datagen_model [2023/02/20 05:16] – [严格验证] solidblockzh_cn:tutorial:datagen_model [2023/02/20 05:17] – [添加物品模型] Please do not use machine translation solidblock
Line 56: Line 56:
 ''ItemModelGenerator'' 包含了多种创建物品模型的方法。 ''ItemModelGenerator'' 包含了多种创建物品模型的方法。
  
-在这个例子中,我们重写上一个例子中的 ''SIMPLE_BLOCK'' 方块模型生成的项目模型。我们将从 ''SIMPLE_BLOCK_ITEM''生成一个项目模型。+在这个例子中,我们重写上一个例子中的 ''SIMPLE_BLOCK'' 方块模型生成的物品模型。我们将从 ''SIMPLE_BLOCK_ITEM'' 生成一个物品模型。
  
 <code java> <code java>
-public static Block SIMPLE_BLOCK = Registry.register(Registry.BLOCK, new Identifier("mymod", "simple_block"), new Block(...)); +public static Block SIMPLE_BLOCK = Registry.register(Registries.BLOCK, new Identifier("tutorial", "simple_block"), new Block(...)); 
-public static BlockItem SIMPLE_BLOCK_ITEM = Registry.register(Registry.ITEM, ..., new BlockItem(SIMPLE_BLOCK, ...));+public static BlockItem SIMPLE_BLOCK_ITEM = Registry.register(Registries.ITEM, ..., new BlockItem(SIMPLE_BLOCK, ...));
 // ... // ...
  
zh_cn/tutorial/datagen_model.txt · Last modified: 2023/02/24 10:41 by hanatomizu