Colored Comb

基本信息

属性 值
注册名 gendustry:HoneyComb
注册方式 Items.regItem(CustomHoneyComb)(Items.scala:42)
类 net.bdew.gendustry.custom.CustomHoneyComb
本地化键 item.gendustry.HoneyComb.name(英文 Colored Comb,简中语言文件保留英文原文)
子物品名 gendustry.honeycomb.<name>(按 meta)
meta 范围 10–25(16 种)
有子类型 是(setHasSubtypes(true) + setMaxDamage(-1))
多渲染通道 是(requiresMultipleRenderPasses() = true)
物品字典 16 种全部注册为 beeComb(bees_color.cfg 与 recipes.cfg 各写一遍)

功能

染色蜂巢是 Gendustry 蜂种的主要产物 —— 16 种染色蜂各自掉落一种颜色的蜂巢。

CustomHoneyComb 是一个 多渲染通道 + 逐 meta 染色的物品:

  • 数据来自 Tuning 的 HoneyCombs 段,每项含 ID、PrimaryColor、SecondaryColor
  • getColorFromItemStack(stack, pass) 逐通道返回颜色(pass 0 = 主色,pass 1 = 副色)
  • 图标复用 Forestry 的两张贴图(forestry:beeCombs.0 / beeCombs.1),因此不需要自己的贴图文件
  • 16 种全部 PrimaryColor = 0xE8D56A(蜂蜡黄)、SecondaryColor = <对应蜂种的颜色>。注意蜂种自身写的是 PrimaryColor = <颜色> / SecondaryColor = 0xE8D56A(见 染色蜂种)—— 也就是说 蜂种的颜色被写成了蜂巢的副色位,两处十六进制值一一对应
  • getUnlocalizedName 查不到 meta 时返回字符串 invalid

16 种蜂巢与蜂种的对应关系见 染色蜂种 的颜色对照表。

转化配方

Forestry 离心机(bees_color.cfg 的 centrifuge 段,16 种各一条,形如):

centrifuge: S:gendustry:"HoneyComb.white", 10 cycles => {
    100% S:gendustry:"HoneyDrop.white"
    30%  I:Forestry:honeyDrop
    50%  I:Forestry:beeswax
}

即 10 周期产出 1 个对应颜色的 Colored Honey Drop + 30% 原版蜂蜜 + 50% 蜂蜡。

相关条目