Pollen Collection Kit
基本信息
| 属性 | 值 |
|---|---|
| 注册名 | gendustry:PollenKit |
| 注册方式 | if (ForestryHelper.haveRoot("Trees")) regItem(PollenKit)(Items.scala:53-55) |
| 类 | net.bdew.gendustry.items.PollenKit |
| 本地化键 | item.gendustry.PollenKit.name(英文 Pollen Collection Kit,简中 花粉收集装备) |
| 创造标签 | GendustryCreativeTabs.main |
注册条件:仅在 Forestry 的 Trees(树木)模块启用时注册。items/PollenKit.scala 依赖 forestry.arboriculture.tiles.TileLeaves 与 ITreeRoot,模块关闭时无法工作。
功能
花粉收集装备右键一棵树(或原版树叶)直接产出一份花粉物品,一次性消耗自身。
onItemUse 流程:
- 玩家潜行时返回
false(让位给放置行为) - 取得目标方块的 Tile,若为
forestry.arboriculture.tiles.TileLeaves则取其getTree个体 - 若不是 Forestry 树叶,回退到
GeneticsHelper.getErsatzPollen(block, meta)处理原版树叶(Forestry 会把原版树叶转成自己的树叶,因此这条路可行) - 按物种根分派:
ITreeRoot→getMemberStack(individual, EnumGermlingType.POLLEN.ordinal())- 物种根 UID 为
"rootFlowers"→getMemberStack(individual, 2)(meta 2 的花产物) - 其他 →
None,不产出
- 成功则
dropItemToPlayer掉出花粉,并decrStackSize消耗 1 个本物品
数值
| 数值名 | 值 |
|---|---|
| 每次使用消耗 | 1 个(一次性) |
| 单次产出 | 1 份花粉物品 |
| 可产出对象 | Forestry 树木花粉(ITreeRoot)、rootFlowers 的 meta 2 产物 |
合成配方
无序合成(shapeless: LSP):
| 字符 | 物品 |
|---|---|
L |
Genetics Labware |
S |
minecraft:string |
P |
minecraft:paper |
相关条目
- Genetics Labware - 配方材料
- Hive Spawning Debugger - 另一件 Forestry 调试工具