Extend opening battle pacing
This commit is contained in:
@@ -299,6 +299,7 @@ func _check_opening_battle_event_dialogue_structure(failures: Array[String]) ->
|
||||
"turn_4_eastern_reserve",
|
||||
"turn_7_southern_raiders",
|
||||
"turn_9_western_reserve",
|
||||
"turn_11_last_rally",
|
||||
"zhang_mancheng_falls"
|
||||
]:
|
||||
var event := _event_by_id(state, event_id)
|
||||
@@ -732,14 +733,15 @@ func _check_opening_battle_story_beats(failures: Array[String]) -> void:
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 4)
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 7)
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 9)
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 11)
|
||||
|
||||
if dialogue_batches.size() < 4:
|
||||
if dialogue_batches.size() < 5:
|
||||
failures.append("opening battle should add dialogue beats for each major reinforcement phase")
|
||||
var victory_text := str(state.objectives.get("victory", ""))
|
||||
if not victory_text.contains("마지막 황건대"):
|
||||
failures.append("opening battle turn 9 event should update the victory objective after the final reserve arrives")
|
||||
if not state._condition_gate_open({"after_event": "turn_9_western_reserve"}):
|
||||
failures.append("opening battle final objective gate should open after the turn 9 story beat")
|
||||
if not victory_text.contains("마지막 황건 잔당"):
|
||||
failures.append("opening battle turn 11 event should update the victory objective after the final rally arrives")
|
||||
if not state._condition_gate_open({"after_event": "turn_11_last_rally"}):
|
||||
failures.append("opening battle final objective gate should open after the turn 11 story beat")
|
||||
|
||||
|
||||
func _check_sishui_gate_story_beats(failures: Array[String]) -> void:
|
||||
|
||||
@@ -35,7 +35,7 @@ func _init() -> void:
|
||||
failures,
|
||||
"001 late reserve gate",
|
||||
_progress_text("res://data/scenarios/001_yellow_turbans.json", false),
|
||||
"제9군령에 전공 갱신"
|
||||
"제11군령에 전공 갱신"
|
||||
)
|
||||
_check_contains(
|
||||
failures,
|
||||
@@ -351,8 +351,14 @@ func _check_opening_battle_requires_castle_capture(failures: Array[String]) -> v
|
||||
for enemy in state.get_living_units(BattleStateScript.TEAM_ENEMY):
|
||||
enemy["alive"] = false
|
||||
state._check_battle_status()
|
||||
if str(state.battle_status) != BattleStateScript.STATUS_ACTIVE:
|
||||
failures.append("opening battle should wait for the turn 11 last rally before victory, got %s" % str(state.battle_status))
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 11)
|
||||
for enemy in state.get_living_units(BattleStateScript.TEAM_ENEMY):
|
||||
enemy["alive"] = false
|
||||
state._check_battle_status()
|
||||
if str(state.battle_status) != BattleStateScript.STATUS_VICTORY:
|
||||
failures.append("opening battle should end after late reserve falls and castle is captured, got %s" % str(state.battle_status))
|
||||
failures.append("opening battle should end after the turn 11 last rally falls and castle is captured, got %s" % str(state.battle_status))
|
||||
|
||||
|
||||
func _check_log_contains(failures: Array[String], logs: Array, expected: String) -> void:
|
||||
@@ -404,15 +410,32 @@ func _check_opening_battle_extended_pressure(failures: Array[String]) -> void:
|
||||
failures.append("opening battle should allow play through turn 17, got limit %d" % state.get_turn_limit())
|
||||
if state.get_living_units(BattleStateScript.TEAM_ENEMY).size() != 12:
|
||||
failures.append("opening battle should start with 12 enemies, got %d" % state.get_living_units(BattleStateScript.TEAM_ENEMY).size())
|
||||
if state._condition_gate_open({"after_event": "turn_9_western_reserve"}):
|
||||
failures.append("opening battle final defeat-all condition should be gated until turn 9 reserve")
|
||||
if state._condition_gate_open({"after_event": "turn_11_last_rally"}):
|
||||
failures.append("opening battle final defeat-all condition should be gated until turn 11 last rally")
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 4)
|
||||
if state.get_living_units(BattleStateScript.TEAM_ENEMY).size() != 14:
|
||||
failures.append("opening battle should field 14 enemies after turn 4 reserve, got %d" % state.get_living_units(BattleStateScript.TEAM_ENEMY).size())
|
||||
if int(state.get_unit("xiahou_dun").get("ai_target_priority", 0)) < 9:
|
||||
failures.append("opening battle turn 4 reserve should pressure Xiahou Dun's vanguard")
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 7)
|
||||
if state.get_living_units(BattleStateScript.TEAM_ENEMY).size() != 16:
|
||||
failures.append("opening battle should field 16 enemies after turn 7 raiders, got %d" % state.get_living_units(BattleStateScript.TEAM_ENEMY).size())
|
||||
if int(state.get_unit("cao_cao").get("ai_target_priority", 0)) < 11:
|
||||
failures.append("opening battle turn 7 raiders should pressure Cao Cao")
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 9)
|
||||
if not state._condition_gate_open({"after_event": "turn_9_western_reserve"}):
|
||||
failures.append("opening battle final gate should open after turn 9 reserve event")
|
||||
if state.get_living_units(BattleStateScript.TEAM_ENEMY).size() != 19:
|
||||
failures.append("opening battle should field 19 enemies after late reserve, got %d" % state.get_living_units(BattleStateScript.TEAM_ENEMY).size())
|
||||
if int(state.get_unit("cao_cao").get("ai_target_priority", 0)) < 12:
|
||||
failures.append("opening battle turn 9 reserve should keep pressure on Cao Cao")
|
||||
if state._condition_gate_open({"after_event": "turn_11_last_rally"}):
|
||||
failures.append("opening battle should stay open-ended until the turn 11 last rally arrives")
|
||||
state._run_events("turn_start", BattleStateScript.TEAM_ENEMY, 11)
|
||||
if not state._condition_gate_open({"after_event": "turn_11_last_rally"}):
|
||||
failures.append("opening battle final gate should open after turn 11 last rally event")
|
||||
if state.get_living_units(BattleStateScript.TEAM_ENEMY).size() != 22:
|
||||
failures.append("opening battle should field 22 enemies after final rally, got %d" % state.get_living_units(BattleStateScript.TEAM_ENEMY).size())
|
||||
if int(state.get_unit("cao_cao").get("ai_target_priority", 0)) < 13 or int(state.get_unit("xiahou_dun").get("ai_target_priority", 0)) < 13:
|
||||
failures.append("opening battle turn 11 last rally should pressure both Cao Cao and Xiahou Dun")
|
||||
|
||||
|
||||
func _check_sishui_gate_extended_pressure(failures: Array[String]) -> void:
|
||||
|
||||
Reference in New Issue
Block a user