
Fabric版群系编辑器
一个库模组,允许用户通过数据包轻松且兼容地修改生物群系。
查看大图Biome-Modifier-for-Fabric

摘要
这是一个库模组,允许用户利用数据包以简单且兼容的方式修改生物群系。
开发者使用说明
我们都知道,对于 Forge 整合包,开发者可以利用以下示例来修改生物群系:
{
"type": "forge:add_features",
"biomes": "#forge:is_plains",
"features": [
"emeraldcraft:wild_cabbage",
"emeraldcraft:wild_chili"
],
"step": "vegetal_decoration"
}
让我们让这也在 Fabric 上生效吧!
数据包开发者应将所有生物群系修改器(格式为 *.json)放在 data/<modid>/biome_modifiers/ 目录下。安装本模组后,所有生物群系修改器都将应用到每个生物群系。
所有生物群系修改器都应遵循以下格式:
{
"type": "<modifier type>",
"biomes": "<registry name of a single biome/list of registry names of biomes/a tag of biomes>",
"priority": priority,
"<other keys...>": "<other values...>"
}
其中 type 表示生物群系修改器的类型,biome 表示要修改的所有生物群系。
请注意 priority 字段是可选的。它的值越小,应用到生物群系的时间就越早(例如,优先级为 99 的修改器会比优先级为 100 的修改器更早应用)。默认值为 1000。
不同类型的生物群系修改器
我们目前提供 9 种不同类型的生物群系修改器:
biome_modifier:none
此类型允许开发者替换其他数据包中的其他生物群系修改器。
{
"type": "biome_modifier:none"
}
biome_modifier:add_features
此生物群系修改器将 features 字段中提到的所有已放置地物添加到目标生物群系。
如果注册表中缺失任何已放置地物,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:add_features",
"biomes": "<registry name(s) of biomes>",
"features": "<registry name of a single feature/list of registry names of features>",
"step": "<step of decoration generation>"
}
biome_modifier:remove_features
此生物群系修改器从目标生物群系中移除 features 字段中提到的所有已放置地物。
如果目标生物群系中缺失任何已放置地物,将记录一条警告日志,且不会使游戏崩溃。
如果注册表中缺失任何已放置地物,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:remove_features",
"biomes": "<registry name(s) of biomes>",
"features": "<registry name of a single feature/list of registry names of features>",
"step": "<step of decoration generation>"
}
biome_modifier:add_spawns
此生物群系修改器将 spawns 字段中提到的所有实体生成添加到目标生物群系。
如果注册表中缺失任何实体类型,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:add_spawns",
"biomes": "<registry name(s) of biomes>",
"spawners": [
{
"type": "<registry name of a single entity type>",
"weight": weight,
"minCount": minCount,
"maxCount": maxCount
}
//If you only add one spawner, you can also replace the list with the only object.
]
}
biome_modifier:remove_spawns
此生物群系修改器从目标生物群系中移除 entity_types 字段中提到的所有实体生成。
如果目标生物群系中缺失任何实体类型,将记录一条警告日志,且不会使游戏崩溃。
如果注册表中缺失任何实体类型,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:remove_spawns",
"biomes": "<registry name(s) of biomes>",
"entity_types": [
"<registry name of a single entity type>"
//If you only remove one spawner, you can also replace the list with the only string.
]
}
biome_modifier:add_spawn_costs
此生物群系修改器将 spawn_costs 字段中提到的所有实体生成添加到目标生物群系。
与 biome_modifier:add_spawns 不同,此修改器将生成添加到生成成本(即生成势、生成密度)中。
如果注册表中缺失任何实体类型,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:add_spawn_costs",
"biomes": "<registry name(s) of biomes>",
"spawn_costs": {
"<registry name of a single entity type>": {
"charge": charge,
"energy_budget": energy_budget
}
}
}
biome_modifier:remove_spawn_costs
此生物群系修改器从目标生物群系中移除 entity_types 字段中提到的所有实体生成。
与 biome_modifier:remove_spawns 不同,此修改器从生成成本(即生成势、生成密度)中移除生成。
如果目标生物群系中缺失任何实体类型,将记录一条警告日志,且不会使游戏崩溃。
如果注册表中缺失任何实体类型,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:remove_spawn_costs",
"biomes": "<registry name(s) of biomes>",
"entity_types": [
"<registry name of a single entity type>"
//If you only remove one spawner, you can also replace the list with the only string.
]
}
biome_modifier:add_carvers
此生物群系修改器将 carvers 字段中提到的所有雕刻器添加到目标生物群系。
如果注册表中缺失任何雕刻器,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:add_carvers",
"biomes": "<registry name(s) of biomes>",
"carvers": "<registry name of a single carver/list of registry names of carvers>",
"step": "<step of carver generation>"
}
biome_modifier:remove_carvers
此生物群系修改器从目标生物群系中移除 carvers 字段中提到的所有雕刻器。
如果目标生物群系中缺失任何雕刻器,将记录一条警告日志,且不会使游戏崩溃。
如果注册表中缺失任何雕刻器,将记录一条错误日志(在安全模式下不会使游戏崩溃)。
{
"type": "biome_modifier:remove_carvers",
"biomes": "<registry name(s) of biomes>",
"carvers": "<registry name of a single carver/list of registry names of carvers>",
"step": "<step of carver generation>"
}
示例
我们为本模组提供了 3 个示例数据包:
额外矿石
此数据包为主世界添加额外的矿石块。

主世界无矿石
此数据包移除主世界的所有矿石块,仅保留矿脉供玩家获取矿石。

下界中的僵尸
此数据包使僵尸能够在下界生成。

正在加载版本记录…



正在加载评论…
评论在新手盒子客户端中发表,这里同步展示。