zh_cn:tutorial:datagen_model
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | Last revisionBoth sides next revision | ||
zh_cn:tutorial:datagen_model [2023/02/20 05:17] – [添加物品模型] Please do not use machine translation solidblock | zh_cn:tutorial:datagen_model [2023/02/20 05:19] – [定向块的数据生成] solidblock | ||
---|---|---|---|
Line 71: | Line 71: | ||
FIXME // | FIXME // | ||
- | ====定向块的数据生成==== | + | ==== 为带有朝向的添加数据生成 ==== |
**快速警告**:这将非常复杂!!! | **快速警告**:这将非常复杂!!! | ||
- | 在本例中,我们将为 '' | + | 在本例中,我们将为 '' |
首先,添加方块自身并且注册它。 | 首先,添加方块自身并且注册它。 | ||
<code java> | <code java> | ||
- | // 在 Tutorial 类里 (或者你自己的 | + | // 在 Tutorial 类(或者你自己的模组的初始化类中) |
public static final Block MACHINE_BLOCK = new Block(FabricBlockSettings.copy(Blocks.BLAST_FURNACE)); | public static final Block MACHINE_BLOCK = new Block(FabricBlockSettings.copy(Blocks.BLAST_FURNACE)); | ||
@Override | @Override | ||
- | public void onInitialize() | + | public void onInitialize() { |
- | { | + | Registry.register(Registries.BLOCK, new Identifier(" |
- | Registry.register(Registry.BLOCK, new Identifier(" | + | |
} | } | ||
</ | </ |
zh_cn/tutorial/datagen_model.txt · Last modified: 2023/02/24 10:41 by hanatomizu