ForeignItems
基本信息
| 属性 | 值 |
|---|---|
| 类名 | ...reactors.items.ForeignItems |
| 方法数 | 14 |
| 源码规模 | 254 行 |
| 启用版本 | 1.7.10 |
功能
外部 mod 反应堆物品接入:遍历 GregTech ItemList,把 GT 的冷却剂单元格、增殖电池、
燃料棒、中子反射层识别出来并注册对应适配器,使它们能装进本 mod 的反应堆。
实现要点
- 方法数 14、源码 254 行。
- 用
instanceof链匹配 GT 的ItemCoolantCellIC/ItemBreederCell/ItemRadioactiveCellIC/ItemCoolantCell, 再注册GTCoolantCellAdapter等适配器。 - ⚠️ 依赖 GregTech 的
ItemList.hasBeenSet()——GT 是未在@Mod声明的硬依赖(见 mod-entry)。 - 另有内部类
GTCoolantCellAdapter/ 其它*Adapter,均为本类的私有静态嵌套。
相关条目
- NHItemList - 自有物品枚举
- ComponentRegistry - 外部物品适配器的注册目标
- GregTech - 外部物品来源