fix(boss): HUD 阶段提示改 tr(STATUS_BOSS_PHASE)+4语言 .po;register_boss 未知 boss_type push_error

This commit is contained in:
2026-07-23 11:07:52 +08:00
parent f8efdc639d
commit 95e5587049
6 changed files with 15 additions and 1 deletions
+1 -1
View File
@@ -744,7 +744,7 @@ func _on_charge_fired(_payload: Dictionary) -> void:
func _on_boss_phase_changed(payload: Dictionary) -> void:
if _lbl_status:
_lbl_status.text = "Boss 阶段 %d" % int(payload.get("phase", 0))
_lbl_status.text = tr("STATUS_BOSS_PHASE") % int(payload.get("phase", 0))
func _on_spell_depth_exceeded(_payload: Dictionary) -> void:
_lbl_status.text = tr("STATUS_DEPTH") % SpellEvaluator.MAX_TRIGGER_DEPTH
+2
View File
@@ -28,6 +28,8 @@ func _load_defs() -> void:
## wave_manager._spawn_boss 生成 SoA Boss 后调用
func register_boss(boss_id: int, boss_type: int, max_hp: float, wave: int) -> void:
if not _defs.has(boss_type):
push_error("BossManager: bosses.json 缺少 boss_type=%d 的配置(该 Boss 将无阶段/招式)" % boss_type)
var def: Dictionary = _defs.get(boss_type, {})
var phases: Array = def.get("phases", [])
_active[boss_id] = {
+3
View File
@@ -215,3 +215,6 @@ msgstr "Close"
msgid "UI_MANA"
msgstr "MP %d/%d"
msgid "STATUS_BOSS_PHASE"
msgstr "Boss Phase %d!"
+3
View File
@@ -215,3 +215,6 @@ msgstr "閉じる"
msgid "UI_MANA"
msgstr "MP %d/%d"
msgid "STATUS_BOSS_PHASE"
msgstr "ボス フェーズ %d"
+3
View File
@@ -215,3 +215,6 @@ msgstr "关闭"
msgid "UI_MANA"
msgstr "蓝 %d/%d"
msgid "STATUS_BOSS_PHASE"
msgstr "Boss 阶段 %d"
+3
View File
@@ -215,3 +215,6 @@ msgstr "關閉"
msgid "UI_MANA"
msgstr "藍 %d/%d"
msgid "STATUS_BOSS_PHASE"
msgstr "Boss 階段 %d"