Bighorn Sheep(大角山羊)

事实基准:/Users/evlos/a/mirror/twilightforest(minecraftVersion = 1.7.10)逐行读源码。

基本信息

属性 值 来源
注册实体名 TwilightForest:Bighorn Sheep TwilightForestMod.java:444
实体 ID 常量 idMobBighornSheep = 178 TwilightForestMod.java:1082
蛋色 主 0xdbceaf / 副 0xd7c771 TwilightForestMod.java:446-447
类 twilightforest.entity.passive.EntityTFBighorn(75 行) entity/passive/EntityTFBighorn.java:15
父类 net.minecraft.entity.passive.EntitySheep EntityTFBighorn.java:15
体型 setSize(0.9F, 1.3F) EntityTFBighorn.java:20
所在群系 暮色森林基础群系刷怪表,权重 12、4~4 只 biomes/TFBiomeBase.java:115

注册名是 “Bighorn Sheep”(大角羊),不是类名里的 Bighorn。 这是唯一带 Bighorn 字样的暮色森林实体。

数值

属性 值 来源
maxHealth 源码中未设置 —— 完全沿用 EntitySheep 的原版值 EntityTFBighorn.java 全文无 applyEntityAttributes
movementSpeed 源码中未设置 —— 沿用 EntitySheep 同上
羊毛颜色取值 random.nextInt(16)(0~15 均匀分布) EntityTFBighorn.java:34-36
体型宽 / 高 0.9 / 1.3 EntityTFBighorn.java:20

⚠️ 方法上的 javadoc 写的是「50% brown, 50% any other color」 (EntityTFBighorn.java:28-33),但方法体 random.nextInt(16)(第 35 行) 实际是 16 种颜色完全均匀,两者不一致。注释与代码不符,以代码为准。

机制

  • 繁殖:createChild 返回 EntityTFBighorn,幼羊随机继承父母其中一方的羊毛色 (EntityTFBighorn.java:52-61)。
  • 刷怪蛋生成:onSpawnWithEgg 覆写,在出生时用 getRandomFleeceColor 重设羊毛色 (EntityTFBighorn.java:42-46)。
  • 成就:在暮色森林维度内被玩家击杀触发 twilightHunter(EntityTFBighorn.java:67-73)。
  • 构造函数里有一行被注释掉的旧贴图赋值 // texture = ... "bighorn.png"(EntityTFBighorn.java:19)。

相关条目