SeriousCreeper's Loot Chests

模组

· 作者 SeriousCreeper

可包含物品的宝箱

3 本站下载 0 关注 更新于 7 年前

最新 lootchests-1.2.5.jar · 1.12.2

一键开服(送7天)

此模组添加了 4 种箱子物品,打开后可以获取由战利品表定义的物品。

默认情况下,这些箱子在游戏世界中除了创造模式菜单外无法通过任何方式获得,因此你需要借助其他模组将它们添加到怪物掉落、随机宝箱战利品或任务奖励中。

要添加你自己的战利品,只需覆盖战利品表 "lootchests:serious_loot" 即可。

它包含 4 个表条目:"common"(普通)、"uncommon"(稀有)、"rare"(史诗)和 "mythic"(传说)。

想了解原版战利品表的工作原理,请查看此处:

你可以将自己的战利品表文件添加到世界保存文件夹中,或者使用可以修改它的模组。个人推荐使用 LootTweaker。

原版示例:

{
"pools": [
{
"name": "common",
"rolls": {
"min": 1,
"max": 3
},
"entries": [
{
"type": "item",
"name": "minecraft:stone",
"weight": 1
}
]
},
{
"name": "uncommon",
"rolls": {
"min": 1,
"max": 3
},
"entries": [
{
"type": "item",
"name": "minecraft:apple",
"weight": 1
}
]
},
{
"name": "rare",
"rolls": {
"min": 1,
"max": 3
},
"entries": [
{
"type": "item",
"name": "minecraft:diamond",
"weight": 1
}
]
},
{
"name": "mythic",
"rolls": {
"min": 1,
"max": 3
},
"entries": [
{
"type": "item",
"name": "minecraft:nether_star",
"weight": 1
}
]
}
]
}

LootTweaker 示例:

import loottweaker.vanilla.loot.LootTables;
import loottweaker.vanilla.loot.LootTable;
import loottweaker.vanilla.loot.LootPool;
import loottweaker.vanilla.loot.Conditions;
import loottweaker.vanilla.loot.Functions;

val table = LootTables.getTable("lootchests:serious_loot");

// 获取所有现有的池
val common = table.getPool("common");
val uncommon = table.getPool("uncommon");
val rare = table.getPool("rare");
val mythic = table.getPool("mythic");

// 设置抽取次数。默认情况下,每个池的 minRoll 为 1,maxRoll 为 3
common.setRolls(3, 10);

// 向池中添加入战利品
common.addItemEntryHelper(<minecraft:stone> * 16, 50, 1, [Functions.setCount(8, 16)], []);
uncommon.addItemEntryHelper(<minecraft:cooked_chicken> * 4, 50, 1, [], []);
rare.addItemEntryHelper(<minecraft:diamond> * 4, 20, 1, [], []);
mythic.addItemEntryHelper(<minecraft:nether_star>, 1, 1, [], []);

你是这个资源的作者?登录后可认领此资源。

评论 0

0.0
暂无评分
5 星
0
4 星
0
3 星
0
2 星
0
1 星
0
我的评分

登录后参与评分

还没有评论,来抢沙发吧

评论配图

相似资源