From d4055209e6c4cd11c37973ed9dc856b6945515bc Mon Sep 17 00:00:00 2001 From: bryanthaboi Date: Mon, 27 Jul 2026 06:54:18 -0400 Subject: [PATCH] pop up a fake save --- tests/drivers/popup_fake_save.lua | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 tests/drivers/popup_fake_save.lua diff --git a/tests/drivers/popup_fake_save.lua b/tests/drivers/popup_fake_save.lua new file mode 100644 index 00000000..39ebc8d5 --- /dev/null +++ b/tests/drivers/popup_fake_save.lua @@ -0,0 +1,23 @@ +-- Driver: drops a fake 3-mon party into the overworld and then gets out +-- of the way -- yields forever without ever touching input itself, so +-- real keyboard/controller play works normally from here on. This is +-- just a quick way to pop up a playable window with Pokemon already in +-- the party, not a scripted playthrough. +return function(game) + local U = dofile("tests/drivers/util.lua") + local Pokemon = require("src.pokemon.Pokemon") + + game.save.party = { + Pokemon.new(game.data, "CHARIZARD", 50), + Pokemon.new(game.data, "PIKACHU", 30), + Pokemon.new(game.data, "SNORLAX", 77), + } + game.save.player.name = "bryan" + + U.teleport(game, "PALLET_TOWN", 10, 8, "down") + U.log("popup_fake_save: party ready, handing off to real input") + + while true do + coroutine.yield() + end +end