fix(boss): HUD 阶段提示改 tr(STATUS_BOSS_PHASE)+4语言 .po;register_boss 未知 boss_type push_error
This commit is contained in:
@@ -744,7 +744,7 @@ func _on_charge_fired(_payload: Dictionary) -> void:
|
|||||||
|
|
||||||
func _on_boss_phase_changed(payload: Dictionary) -> void:
|
func _on_boss_phase_changed(payload: Dictionary) -> void:
|
||||||
if _lbl_status:
|
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:
|
func _on_spell_depth_exceeded(_payload: Dictionary) -> void:
|
||||||
_lbl_status.text = tr("STATUS_DEPTH") % SpellEvaluator.MAX_TRIGGER_DEPTH
|
_lbl_status.text = tr("STATUS_DEPTH") % SpellEvaluator.MAX_TRIGGER_DEPTH
|
||||||
|
|||||||
@@ -28,6 +28,8 @@ func _load_defs() -> void:
|
|||||||
|
|
||||||
## wave_manager._spawn_boss 生成 SoA Boss 后调用
|
## wave_manager._spawn_boss 生成 SoA Boss 后调用
|
||||||
func register_boss(boss_id: int, boss_type: int, max_hp: float, wave: int) -> void:
|
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 def: Dictionary = _defs.get(boss_type, {})
|
||||||
var phases: Array = def.get("phases", [])
|
var phases: Array = def.get("phases", [])
|
||||||
_active[boss_id] = {
|
_active[boss_id] = {
|
||||||
|
|||||||
@@ -215,3 +215,6 @@ msgstr "Close"
|
|||||||
|
|
||||||
msgid "UI_MANA"
|
msgid "UI_MANA"
|
||||||
msgstr "MP %d/%d"
|
msgstr "MP %d/%d"
|
||||||
|
|
||||||
|
msgid "STATUS_BOSS_PHASE"
|
||||||
|
msgstr "Boss Phase %d!"
|
||||||
|
|||||||
@@ -215,3 +215,6 @@ msgstr "閉じる"
|
|||||||
|
|
||||||
msgid "UI_MANA"
|
msgid "UI_MANA"
|
||||||
msgstr "MP %d/%d"
|
msgstr "MP %d/%d"
|
||||||
|
|
||||||
|
msgid "STATUS_BOSS_PHASE"
|
||||||
|
msgstr "ボス フェーズ %d!"
|
||||||
|
|||||||
@@ -215,3 +215,6 @@ msgstr "关闭"
|
|||||||
|
|
||||||
msgid "UI_MANA"
|
msgid "UI_MANA"
|
||||||
msgstr "蓝 %d/%d"
|
msgstr "蓝 %d/%d"
|
||||||
|
|
||||||
|
msgid "STATUS_BOSS_PHASE"
|
||||||
|
msgstr "Boss 阶段 %d!"
|
||||||
|
|||||||
@@ -215,3 +215,6 @@ msgstr "關閉"
|
|||||||
|
|
||||||
msgid "UI_MANA"
|
msgid "UI_MANA"
|
||||||
msgstr "藍 %d/%d"
|
msgstr "藍 %d/%d"
|
||||||
|
|
||||||
|
msgid "STATUS_BOSS_PHASE"
|
||||||
|
msgstr "Boss 階段 %d!"
|
||||||
|
|||||||
Reference in New Issue
Block a user