updates
This commit is contained in:
parent
4298caf5cb
commit
2e6638b744
19 changed files with 484 additions and 185 deletions
|
|
@ -3,8 +3,9 @@ extends RefCounted
|
|||
## main menu over the paused farm; New vacation, Continue, and their questions; pausing freezes
|
||||
## the simulation tick; settings apply and persist from the pause menu; Restart the night and
|
||||
## Save & quit to menu put the farm back at the saved morning without touching the save; a
|
||||
## damaged save can't be continued; the failure screen and Retry; the farmers' return and the
|
||||
## final assessment; the first day's and night's tips; and the sounds hooked to the game.
|
||||
## damaged save can't be continued; quitting a hosted co-op game from the pause menu leaves the
|
||||
## scarecrow unfrozen; the failure screen and Retry; the farmers' return and the final
|
||||
## assessment; the first day's and night's tips; and the sounds hooked to the game.
|
||||
|
||||
const P := CampaignController.Phase
|
||||
const SAVE := "user://test_flow_save.json"
|
||||
|
|
@ -33,6 +34,7 @@ func run(p_r: GameTestRunner) -> void:
|
|||
await _settings()
|
||||
await _restart_and_quit_to_menu()
|
||||
await _continue_and_new()
|
||||
await _coop_quit_to_menu()
|
||||
await _tutorial()
|
||||
await _failure()
|
||||
await _ending()
|
||||
|
|
@ -196,6 +198,25 @@ func _continue_and_new() -> void:
|
|||
"New vacation doesn't ask about a damaged save and replaces it")
|
||||
|
||||
|
||||
## Hosting co-op, the pause menu freezes only this scarecrow; quitting to the menu from it must
|
||||
## unfreeze it, or the next game (hosting again, or joining a friend's) has no aim or buttons.
|
||||
func _coop_quit_to_menu() -> void:
|
||||
var links := CoopLink.pair()
|
||||
sim.coop.start_host(sim, links[0], "Ana", "Ben")
|
||||
main.pause()
|
||||
r.check(sim.local_frozen and not r.paused and sim.combat.remote != null, "hosting co-op, the pause menu freezes the scarecrow, not the farm")
|
||||
main.pause_menu.menu_button.pressed.emit()
|
||||
r.check(main.screen == Main.Screen.MENU and not sim.coop.is_active() and not sim.local_frozen and sim.combat.remote == null
|
||||
and sim.scarecrow.remote == null and sim.interactions.remote == null and sim.player.input_enabled,
|
||||
"quitting co-op to the menu unfreezes it")
|
||||
links[1].close()
|
||||
main.main_menu.continue_button.pressed.emit()
|
||||
sim.combat.aim_point = Vector3.ZERO
|
||||
await r.physics_frame
|
||||
await r.physics_frame
|
||||
r.check(main.screen == Main.Screen.PLAYING and sim.combat.aim_point != Vector3.ZERO, "and in the next game the aim follows the mouse again")
|
||||
|
||||
|
||||
func _tutorial() -> void:
|
||||
var t := sim.tutorial
|
||||
t.done = {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue