| 
 
| 赞 | 36 |  
| VIP | 0 |  
| 好人卡 | 0 |  
| 积分 | 96 |  
| 经验 | 0 |  
| 最后登录 | 2025-10-26 |  
| 在线时间 | 462 小时 |  
 Lv4.逐梦者 
	梦石2 星屑7638 在线时间462 小时注册时间2021-12-4帖子492 
 | 
| Battle_Hud.prototype.create_face = function() { if (String(Moghunter.bhud_face_visible) != "true") {return};
 this.removeChild(this._face);
 if (!this._battler) {return};
 this._face = new Sprite(ImageManager.loadBHud(Moghunter.actFace_list[this._battler._actorId])); // 关键在于这一行,也就是BattleHud.js的第3849行
 this._face.anchor.x = 0.5;
 this._face.anchor.y = 0.5;
 this._face_data = [0,0,false,false,false,-1];
 if (String(Moghunter.bhud_face_shake) === "true") {this._face_data[2] = true}
 if (String(Moghunter.bhud_face_animated) === "true") {this._face_data[4] = true}
 this._battler._bhud_face_data = [0,0,0,0]
 this.addChild(this._face);
 };
 
 如上,Moghunter.actFace_list[this._battler._actorId]中记录了图片文件名(不含.png后缀),且因为是插件的全局参数所以它是绝对不可能在游戏中途动态变化的。
 因此应该把上面的函数整个改成下面的样子:
 
 Battle_Hud.prototype.create_face = function() {
 if (String(Moghunter.bhud_face_visible) != "true") {return};
 this.removeChild(this._face);
 if (!this._battler) {return};
 
 var a = $dataActors[this._battler._actorId], b = a.faceName, c = a.faceIndex; // c的范围是0-7
 var file = Moghunter.actFace_list[this._battler._actorId] || (b + '_' + c); // 当插件全局参数中该项【留空】时,使用名为 b_c.png 的文件
 this._face = new Sprite(ImageManager.loadBHud(file));
 
 this._face.anchor.x = 0.5;
 this._face.anchor.y = 0.5;
 this._face_data = [0,0,false,false,false,-1];
 if (String(Moghunter.bhud_face_shake) === "true") {this._face_data[2] = true}
 if (String(Moghunter.bhud_face_animated) === "true") {this._face_data[4] = true}
 this._battler._bhud_face_data = [0,0,0,0]
 this.addChild(this._face);
 };
 | 
 |