
LineageCore
LineageCore是由Hivemere制作的物种库。
LineageCore 是我专门制作的一个模组,用于创建能与各种内容兼容的物种(Species)。
无论你想使用 Java 还是纯 JSON,都可以用来制作物种。
这里有一些基础指南,以示例 JSON 文件的形式提供,你应该将其放入 “.minecraft/lineages/template.json” 或 “.minecraft/lineages/template/template.json” 中。 注意:artDirectory 仅在 lineages 文件夹及其子文件夹中搜索,不会在其他地方查找。
- 显示名称: 更改你的物种/亚种(Species/Subspecies)的标题
- 物种描述: 你的描述
- 物种 ID: 你的物种 ID,“id” 表示核心物种,“id_sub” 表示亚种。
- 排序 [可选]: 更改物种出现的位置顺序,默认值为 100,并会使其出现在最右侧。
- 拥有亚种 [可选]: 为 True 或 False,应该也可以与亚种一起使用。
- 是某物种的亚种 [可选]: 标明它是哪个物种的亚种,如果你的物种是核心物种,请不要使用此项。“human” 和 “normal_human” 是基础核心物种。
- 美术资源目录 [可选,但推荐]: 标明美术资源所在位置,会搜索 Lineage(血统)文件夹及其任何子文件夹。
- 选择时触发 [可选]: 在 Java 中,显然只支持 Java 代码。在 JSON 中,出于安全原因,仅支持如下所示的命令。
{
"displayName": "Template Species",
"speciesDescription": "This is an example species loaded dynamically from the lineages folder.",
"speciesID": "template_species_sub",
"order": 100,
"hasSubspecies": false,
"isSubspeciesOf": "human",
"artDirectory": "template/template_art.png",
"onSelect": {
"type": "command",
"command": [
"/give @s minecraft:bow 1",
"/give @s minecraft:arrow 64"
]
}
}
Java 代码示例:

public static final RegistryObject<Species> ELF = SPECIES.register(
"elf",
() -> new Species(
"Elf",
"Agile archers attuned with nature.",
"elf",
true,
player -> {
// Example 1: Add potion effects directly
player.addEffect(new MobEffectInstance(MobEffects.MOVEMENT_SPEED, 999999, 0, false, false));
// Example 2: Give an item directly
player.getInventory().add(new ItemStack(Items.BOW));
// Example 3: Send a message or play a sound
player.sendSystemMessage(Component.literal("You have attuned with nature!"));
},
null,
-1
)
);
由 Hivemere 制作,也就是我。
[仅限 FORGE - 1.20.1]
正在加载版本记录…
正在加载评论…
评论在新手盒子客户端中发表,这里同步展示。