diff --git a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlanGolden.h b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlanGolden.h new file mode 100644 index 0000000000..e63fe2d69b --- /dev/null +++ b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlanGolden.h @@ -0,0 +1,281 @@ +/* BDSP AutoStory Plan Golden + * + * From: https://github.com/PokemonAutomation/ + * + * The legs the planner plans for every ROUTE of the story simulation + * (PokemonBDSP_AutoStory_StorySimulation_Tests.cpp, "plans match the + * golden"): per route a header " costs= from + * to ", then one line per leg with the tiles it may end on. + * One string per line: MSVC caps a single literal at 16 KB. + * Regenerate from the test's failure log; see test_golden_plans(). + * + */ + +#ifndef PokemonAutomation_PokemonBDSP_AutoStory_PlanGolden_H +#define PokemonAutomation_PokemonBDSP_AutoStory_PlanGolden_H + +#include + +namespace PokemonAutomation{ +namespace NintendoSwitch{ +namespace PokemonBDSP{ + +// The stored plan lines, in the order the simulation plans them. +inline constexpr std::string_view BDSP_PLAN_GOLDEN[] = { + "00.01 below_the_flute costs=default from PlayerHouse2F (4, 6) to PlayerHouse2F (7, 5)", + "00.01 north 1 (to wall) -> PlayerHouse2F (4, 5)", + "00.01 east 3 (open) -> PlayerHouse2F (7, 5)", + "00.01 onto_the_flute_tile costs=default from PlayerHouse2F (7, 5) to PlayerHouse2F (8, 4)", + "00.01 north 1 (to wall) -> PlayerHouse2F (7, 4)", + "00.01 east 1 (to wall) -> PlayerHouse2F (8, 4)", + "00.01 above_the_door costs=default from PlayerHouse1F (10, 3) (10, 4) to PlayerHouse1F (6, 9)", + "00.01 south 7 (to wall) -> PlayerHouse1F (10, 10)", + "00.01 north 1 (open) -> PlayerHouse1F (10, 9)", + "00.01 west 4 (open) -> PlayerHouse1F (6, 9)", + "00.01 short_of_barrys_door costs=default from TwinleafTown (20, 22) to TwinleafTown (10, 12)", + "00.01 west 7 (open) -> Twinleaf Town (13, 22)", + "00.01 north 10 (to wall) -> Twinleaf Town (13, 12)", + "00.01 west 3 (open) -> Twinleaf Town (10, 12)", + "00.01 back_onto_barrys_doorstep costs=default from TwinleafTown (9, 13) to TwinleafTown (9, 12)", + "00.01 north 1 (open) -> Twinleaf Town (9, 12)", + "00.01 below_barrys_stairs costs=default from RivalHouse1F (6, 9) to RivalHouse1F (2, 3)", + "00.01 west 4 (to wall) -> RivalHouse1F (2, 9)", + "00.01 north 6 (to wall) -> RivalHouse1F (2, 3)", + "00.01 above_barrys_stairs costs=default from RivalHouse2F (3, 5) to RivalHouse2F (3, 4)", + "00.01 north 1 (to wall) -> RivalHouse2F (3, 4)", + "00.01 above_barrys_door costs=default from RivalHouse1F (2, 3) to RivalHouse1F (6, 9)", + "00.01 south 6 (open) -> RivalHouse1F (2, 9)", + "00.01 east 4 (open) -> RivalHouse1F (6, 9)", + "00.01 below_barrys_warning costs=default from TwinleafTown (9, 12) to Route201 (15, 19)", + "00.01 east 6 (open) -> Twinleaf Town (15, 12)", + "00.01 north 24 (to wall) -> Route 201 (15, 13)", + "00.01 south 6 (open) -> Route 201 (15, 19)", + "00.01 away_from_barry costs=default from Route201 (15, 18) to Route201 (12, 17)", + "00.01 north 1 (open) -> Route 201 (15, 17)", + "00.01 west 3 (open) -> Route 201 (12, 17)", + "00.01 below_the_lake_entrance costs=default from Route201 (12, 17) to VerityLakefront (17, 14)", + "00.01 north 1 (open) -> Route 201 (12, 16)", + "00.01 west 26 (to wall) -> Verity Lakefront (18, 23)", + "00.01 north 9 (to wall) -> Verity Lakefront (18, 14)", + "00.01 west 1 (open) -> Verity Lakefront (17, 14)", + "00.02 to_the_lake_entrance costs=default from VerityLakefront (17, 14) to VerityLakefront (17, 13)", + "00.02 north 1 (open) -> Verity Lakefront (17, 13)", + "00.03 short_of_rowan costs=default from VerityLakefront (17, 14) (17, 15) to Route201 (4, 14)", + "00.03 south 7 (to wall) -> Verity Lakefront (17, 21)", + "00.03 east 19 (open) -> Route 201 (4, 14)", + "00.03 by_the_counter costs=default from PlayerHouse1F (5, 8) (6, 8) to PlayerHouse1F (4, 8)", + "00.03 west 2 (to wall) -> PlayerHouse1F (4, 8)", + "00.03 above_the_door_again costs=default from PlayerHouse1F (4, 8) to PlayerHouse1F (6, 9)", + "00.03 east 2 (open) -> PlayerHouse1F (6, 8)", + "00.03 south 1 (open) -> PlayerHouse1F (6, 9)", + "00.03 short_of_dawn costs=default from TwinleafTown (20, 22) to Route201 (63, 5)", + "00.03 west 3 (open) -> Twinleaf Town (17, 22)", + "00.03 north 34 (to wall) -> Route 201 (17, 13)", + "00.03 east 40 (to wall) -> Route 201 (57, 13)", + "00.03 west 7 (open) -> Route 201 (50, 13)", + "00.03 north 10 (to wall) -> Route 201 (50, 3)", + "00.03 east 13 (to wall) -> Route 201 (63, 3)", + "00.03 south 2 (open) -> Route 201 (63, 5)", + "00.04 onto_the_path costs=town from SandgemTown (26, 11) (27, 11) (28, 11) (26, 12) (27, 12) (28, 12) to SandgemTown (29, 12)", + "00.04 east 3 (to wall) -> Sandgem Town (29, 11) Sandgem Town (29, 12)", + "00.04 north 1 (to wall) -> Sandgem Town (29, 11)", + "00.04 south 1 (open) -> Sandgem Town (29, 12)", + "00.04 home costs=default from Route201 (57, 5) (58, 5) (59, 5) (60, 5) (61, 5) (62, 5) (63, 5) to TwinleafTown (20, 22) (20, 23) (20, 24) (20, 25) (20, 26)", + "00.04 west 21 (to wall) -> Route 201 (42, 5)", + "00.04 south 4 (open) -> Route 201 (42, 9)", + "00.04 west 28 (to wall) -> Route 201 (14, 9)", + "00.04 south 42 (to wall) -> Twinleaf Town (14, 26)", + "00.04 east 6 (open) -> Twinleaf Town (20, 26)", + "00.04 beside_mom costs=default from PlayerHouse1F (6, 9) to PlayerHouse1F (6, 7)", + "00.04 north 2 (open) -> PlayerHouse1F (6, 7)", + "00.04 around_mom costs=default from PlayerHouse1F (6, 7) to PlayerHouse1F (5, 9)", + "00.04 south 2 (open) -> PlayerHouse1F (6, 9)", + "00.04 west 1 (to wall) -> PlayerHouse1F (5, 9)", + "00.04 short_of_the_catch_tutorial costs=default from TwinleafTown (19, 22) to Route202 (22, 27)", + "00.04 west 2 (open) -> Twinleaf Town (17, 22)", + "00.04 north 34 (to wall) -> Route 201 (17, 13)", + "00.04 east 40 (to wall) -> Route 201 (57, 13)", + "00.04 west 7 (open) -> Route 201 (50, 13)", + "00.04 north 7 (open) -> Route 201 (50, 6)", + "00.04 east 43 (to wall) -> Sandgem Town (29, 13)", + "00.04 west 5 (open) -> Sandgem Town (24, 13)", + "00.04 north 21 (to wall) -> Route 202 (25, 24)", + "00.04 west 3 (to wall) -> Route 202 (22, 24)", + "00.04 south 3 (open) -> Route 202 (22, 27)", + "00.04b to_catch_grass costs=default from Route202 (15, 25) (16, 25) (17, 25) (18, 25) (19, 25) (20, 25) (21, 25) (15, 26) (16, 26) (17, 26) (18, 26) (19, 26) (20, 26) (21, 26) (15, 27) (16, 27) (17, 27) (18, 27) (19, 27) (20, 27) (21, 27) (21, 28) (21, 29) to Route202 (18, 25) (19, 25) (20, 25) (18, 26) (19, 26) (20, 26) (18, 27) (19, 27) (20, 27)", + "00.04b east 15 (to wall) -> Route 202 (23, 25) Route 202 (30, 26) Route 202 (30, 27) Route 202 (30, 28) Route 202 (30, 29)", + "00.04b north 5 (to wall) -> Route 202 (23, 24) Route 202 (30, 24)", + "00.04b west 8 (to wall) -> Route 202 (22, 24)", + "00.04b south 1 (open) -> Route 202 (22, 25)", + "00.04b west 2 (open) -> Route 202 (20, 25)", + "00.04b into_sandgem costs=robust from Route202 (18, 25) (19, 25) (20, 25) (18, 26) (19, 26) (20, 26) (18, 27) (19, 27) (20, 27) to SandgemTown (29, 5)", + "00.04b south 2 (to wall) -> Route 202 (18, 27) Route 202 (19, 27) Route 202 (20, 27)", + "00.04b east 12 (to wall) -> Route 202 (30, 27)", + "00.04b south 10 (to wall) -> Sandgem Town (29, 5)", + "00.04b below_center_door costs=town from SandgemTown (29, 5) to SandgemTown (17, 11)", + "00.04b west 5 (open) -> Sandgem Town (24, 5)", + "00.04b south 6 (open) -> Sandgem Town (24, 11)", + "00.04b west 7 (open) -> Sandgem Town (17, 11)", + "00.04d north_to_jubilife costs=default from Route202 (30, 24) to Route202 (11, 0) (12, 0) (13, 0) (14, 0) (15, 0) (16, 0) (17, 0) (18, 0) (11, 1) (12, 1) (13, 1) (14, 1) (15, 1) (16, 1) (17, 1) (18, 1) (11, 2) (12, 2) (13, 2) (14, 2) (15, 2) (16, 2) (17, 2) (18, 2) (11, 3) (12, 3) (13, 3) (14, 3) (15, 3) (16, 3) (17, 3) (18, 3)", + "00.04d south 2 (open) -> Route 202 (30, 26)", + "00.04d west 27 (to wall) -> Route 202 (3, 26)", + "00.04d north 12 (to wall) -> Route 202 (3, 14)", + "00.04d east 14 (to wall) -> Route 202 (17, 14)", + "00.04d south 8 (to wall) -> Route 202 (17, 22)", + "00.04d east 13 (to wall) -> Route 202 (30, 22)", + "00.04d north 18 (to wall) -> Route 202 (30, 4)", + "00.04d south 1 (open) -> Route 202 (30, 5)", + "00.04d west 12 (open) -> Route 202 (18, 5)", + "00.04d north 2 (open) -> Route 202 (18, 3)", + "00.05 to_the_center costs=town from JubilifeCity (48, 62) to JubilifeCity (52, 41)", + "00.05 west 1 (open) -> Jubilife City (47, 62)", + "00.05 north 21 (open) -> Jubilife City (47, 41)", + "00.05 east 5 (open) -> Jubilife City (52, 41)", + "00.05 to_the_school costs=town from JubilifeCity (52, 41) to JubilifeCity (40, 41)", + "00.05 west 12 (open) -> Jubilife City (40, 41)", + "00.05b below_the_presidents_trigger costs=town from JubilifeCity (40, 41) to JubilifeCity (46, 41)", + "00.05b east 6 (open) -> Jubilife City (46, 41)", + "00.05b past_the_president costs=default from JubilifeCity (46, 40) to JubilifeCity (48, 40)", + "00.05b east 2 (open) -> Jubilife City (48, 40)", + "00.05b below_the_mart_clown costs=town from JubilifeCity (48, 40) to JubilifeCity (55, 34)", + "00.05b north 6 (open) -> Jubilife City (48, 34)", + "00.05b east 7 (open) -> Jubilife City (55, 34)", + "00.05b below_the_tv_clown costs=town from JubilifeCity (55, 34) to JubilifeCity (36, 17)", + "00.05b west 23 (to wall) -> Jubilife City (32, 34)", + "00.05b north 10 (open) -> Jubilife City (32, 24)", + "00.05b east 4 (open) -> Jubilife City (36, 24)", + "00.05b north 7 (open) -> Jubilife City (36, 17)", + "00.05b below_the_company_clown costs=town from JubilifeCity (36, 17) to JubilifeCity (15, 19)", + "00.05b south 4 (open) -> Jubilife City (36, 21)", + "00.05b west 21 (open) -> Jubilife City (15, 21)", + "00.05b north 2 (open) -> Jubilife City (15, 19)", + "00.05c below_the_president costs=town from JubilifeCity (15, 19) to JubilifeCity (46, 36)", + "00.05c south 5 (open) -> Jubilife City (15, 24)", + "00.05c east 29 (open) -> Jubilife City (44, 24)", + "00.05c south 12 (open) -> Jubilife City (44, 36)", + "00.05c east 2 (open) -> Jubilife City (46, 36)", + "00.05c to_the_route_203_street costs=town from JubilifeCity (46, 36) to JubilifeCity (58, 22)", + "00.05c east 1 (open) -> Jubilife City (47, 36)", + "00.05c north 14 (open) -> Jubilife City (47, 22)", + "00.05c east 11 (open) -> Jubilife City (58, 22)", + "01.01 west_of_barrys_trigger costs=town from JubilifeCity (58, 22) to Route203 (4, 18)", + "01.01 east 9 (open) -> Route 203 (4, 18)", + "01.02 south_to_the_cliff costs=default from Route203 (5, 17) (5, 18) (5, 19) (5, 20) to Route203 (5, 20)", + "01.02 south 3 (to wall) -> Route 203 (5, 20)", + "01.02 by_the_gate costs=default from Route203 (5, 20) to Route203 (55, 9)", + "01.02 north 2 (open) -> Route 203 (5, 18)", + "01.02 east 50 (to wall) -> Route 203 (55, 18)", + "01.02 north 9 (open) -> Route 203 (55, 9)", + "01.02 west_of_the_hikers_trigger costs=default from OreburghGate (4, 22) (5, 22) to OreburghGate (6, 22)", + "01.02 south 1 (to wall) -> OreburghGate (4, 23) OreburghGate (5, 23)", + "01.02 east 2 (to wall) -> OreburghGate (6, 23)", + "01.02 north 1 (open) -> OreburghGate (6, 22)", + "01.02 past_curtis costs=default from OreburghGate (7, 22) to OreburghGate (20, 22)", + "01.02 east 13 (open) -> OreburghGate (20, 22)", + "01.02 by_the_east_mouth costs=default from OreburghGate (20, 22) to OreburghGate (27, 22)", + "01.02 east 7 (open) -> OreburghGate (27, 22)", + "01.02 west_of_the_welcome costs=default from OreburghCity (2, 13) (3, 13) to OreburghCity (9, 13)", + "01.02 north 3 (to wall) -> Oreburgh City (2, 10) Oreburgh City (3, 10)", + "01.02 east 4 (to wall) -> Oreburgh City (6, 10)", + "01.02 south 3 (open) -> Oreburgh City (6, 13)", + "01.02 east 3 (open) -> Oreburgh City (9, 13)", + "01.03 below_the_centers_door costs=town from OreburghCity (43, 21) (44, 21) (45, 21) (43, 22) (44, 22) (45, 22) to OreburghCity (47, 21)", + "01.03 east 5 (to wall) -> Oreburgh City (48, 21) Oreburgh City (48, 22)", + "01.03 north 1 (to wall) -> Oreburgh City (48, 21)", + "01.03 west 1 (open) -> Oreburgh City (47, 21)", + "01.03 above_the_mine costs=town from OreburghCity (47, 21) to OreburghCity (46, 58)", + "01.03 west 3 (open) -> Oreburgh City (44, 21)", + "01.03 south 20 (to wall) -> Oreburgh City (44, 41)", + "01.03 east 2 (open) -> Oreburgh City (46, 41)", + "01.03 south 17 (open) -> Oreburgh City (46, 58)", + "01.03 below_roark costs=default from OreburghMine (15, 9) to OreburghMine (18, 29)", + "01.03 east 2 (to wall) -> OreburghMine (17, 9)", + "01.03 south 2 (to wall) -> OreburghMine (17, 11)", + "01.03 west 2 (to wall) -> OreburghMine (15, 11)", + "01.03 south 6 (to wall) -> OreburghMine (15, 17)", + "01.03 east 14 (to wall) -> OreburghMine (29, 17)", + "01.03 south 10 (to wall) -> OreburghMine (29, 27)", + "01.03 west 3 (to wall) -> OreburghMine (26, 27)", + "01.03 south 2 (to wall) -> OreburghMine (26, 29)", + "01.03 west 8 (open) -> OreburghMine (18, 29)", + "01.03 below_the_coal_rooms_warp costs=default from OreburghMine (18, 29) to OreburghMine (15, 2)", + "01.03 east 9 (to wall) -> OreburghMine (27, 29)", + "01.03 north 5 (to wall) -> OreburghMine (27, 24)", + "01.03 east 2 (to wall) -> OreburghMine (29, 24)", + "01.03 north 8 (to wall) -> OreburghMine (29, 16)", + "01.03 west 16 (to wall) -> OreburghMine (13, 16)", + "01.03 east 2 (open) -> OreburghMine (15, 16)", + "01.03 north 5 (to wall) -> OreburghMine (15, 11)", + "01.03 east 2 (to wall) -> OreburghMine (17, 11)", + "01.03 north 2 (to wall) -> OreburghMine (17, 9)", + "01.03 west 4 (to wall) -> OreburghMine (13, 9)", + "01.03 north 7 (to wall) -> OreburghMine (13, 2)", + "01.03 east 2 (open) -> OreburghMine (15, 2)", + "01.03 below_the_centers_door_again costs=town from OreburghCity (45, 57) to OreburghCity (47, 21)", + "01.03 west 2 (to wall) -> Oreburgh City (43, 57)", + "01.03 north 16 (to wall) -> Oreburgh City (43, 41)", + "01.03 east 1 (open) -> Oreburgh City (44, 41)", + "01.03 north 21 (to wall) -> Oreburgh City (44, 20)", + "01.03 south 1 (open) -> Oreburgh City (44, 21)", + "01.03 east 3 (open) -> Oreburgh City (47, 21)", + "01.05 east_of_barrys_trigger costs=town from OreburghCity (26, 21) (26, 22) to OreburghCity (7, 13)", + "01.05 west 17 (to wall) -> Oreburgh City (9, 21) Oreburgh City (9, 22)", + "01.05 north 5 (to wall) -> Oreburgh City (9, 17)", + "01.05 east 2 (open) -> Oreburgh City (11, 17)", + "01.05 north 4 (open) -> Oreburgh City (11, 13)", + "01.05 west 4 (open) -> Oreburgh City (7, 13)", + "01.05 by_the_gate costs=default from OreburghCity (5, 13) to OreburghCity (2, 13)", + "01.05 west 3 (open) -> Oreburgh City (2, 13)", + "01.05 through_the_gate costs=default from OreburghGate (27, 22) (26, 22) to OreburghGate (4, 22)", + "01.05 south 1 (open) -> OreburghGate (26, 23) OreburghGate (27, 23)", + "01.05 west 19 (to wall) -> OreburghGate (8, 23)", + "01.05 north 1 (to wall) -> OreburghGate (8, 22)", + "01.05 west 4 (open) -> OreburghGate (4, 22)", + "01.06 below_rowans_trigger costs=town from Route203 (55, 9) to JubilifeCity (47, 8)", + "01.06 south 10 (to wall) -> Route 203 (55, 19)", + "01.06 west 17 (to wall) -> Route 203 (38, 19)", + "01.06 north 1 (open) -> Route 203 (38, 18)", + "01.06 west 57 (open) -> Jubilife City (44, 22)", + "01.06 north 14 (to wall) -> Jubilife City (44, 8)", + "01.06 east 3 (to wall) -> Jubilife City (47, 8)", + "01.08 west_to_the_wall costs=default from JubilifeCity (46, 5) (47, 5) to JubilifeCity (44, 5)", + "01.08 west 3 (to wall) -> Jubilife City (44, 5)", + "01.08 below_the_ravaged_path costs=town from JubilifeCity (44, 5) to Route204South (11, 2)", + "01.08 east 2 (open) -> Jubilife City (46, 5)", + "01.08 north 19 (to wall) -> Route 204 (14, 18)", + "01.08 west 2 (open) -> Route 204 (12, 18)", + "01.08 north 16 (to wall) -> Route 204 (12, 2)", + "01.08 west 1 (to wall) -> Route 204 (11, 2)", + "01.09 west_of_the_rock costs=default from RavagedPath (19, 50) to RavagedPath (21, 43)", + "01.09 north 7 (open) -> RavagedPath (19, 43)", + "01.09 east 2 (open) -> RavagedPath (21, 43)", + "01.09 above_the_way_out costs=default from RavagedPath (21, 43) to RavagedPath (28, 44)", + "01.09 east 8 (to wall) -> RavagedPath (29, 43)", + "01.09 south 1 (to wall) -> RavagedPath (29, 44)", + "01.09 west 1 (open) -> RavagedPath (28, 44)", + "01.10 line_1 costs=line from Route204North (20, 26) to Route204North (20, 27)", + "01.10 south 1 (open) -> Route 204 (20, 27)", + "01.10 line_2 costs=line from Route204North (20, 27) to Route204North (11, 27)", + "01.10 west 9 (open) -> Route 204 (11, 27)", + "01.10 line_3 costs=line from Route204North (11, 27) to Route204North (11, 22)", + "01.10 north 5 (open) -> Route 204 (11, 22)", + "01.10 line_4 costs=line from Route204North (11, 22) to Route204North (19, 22)", + "01.10 east 8 (open) -> Route 204 (19, 22)", + "01.10 line_5 costs=line from Route204North (19, 22) to Route204North (19, 12)", + "01.10 north 10 (open) -> Route 204 (19, 12)", + "01.10 line_6 costs=line from Route204North (19, 12) to Route204North (11, 12)", + "01.10 west 8 (open) -> Route 204 (11, 12)", + "01.10 line_7 costs=line from Route204North (11, 12) to Route204North (11, 5)", + "01.10 north 7 (open) -> Route 204 (11, 5)", + "01.10 into_floaroma costs=line from Route204North (11, 5) to FloaromaTown (11, 29)", + "01.10 north 8 (open) -> Floaroma Town (11, 29)", + "01.11 west_along_the_field costs=default from FloaromaTown (11, 29) to FloaromaTown (3, 29)", + "01.11 west 8 (open) -> Floaroma Town (3, 29)", + "01.11 below_the_old_man costs=default from FloaromaTown (4, 26) to FloaromaTown (3, 26)", + "01.11 west 1 (open) -> Floaroma Town (3, 26)", +}; + +} // namespace PokemonBDSP +} // namespace NintendoSwitch +} // namespace PokemonAutomation +#endif diff --git a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlannedRoute_Tests.cpp b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlannedRoute_Tests.cpp index a03a4692b7..61d1d2ba92 100644 --- a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlannedRoute_Tests.cpp +++ b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlannedRoute_Tests.cpp @@ -16,13 +16,22 @@ #include #include "Common/Cpp/TestRunners/UnitTestDatabase.h" #include "Data/PokemonBDSP_AutoStory_Maps.h" +#include "Data/PokemonBDSP_AutoStory_PlanCosts.h" #include "Data/PokemonBDSP_AutoStory_RoutePlanner.h" #include "Data/PokemonBDSP_AutoStory_StoryMaps.h" #include "Data/PokemonBDSP_AutoStory_StoryTrainers.h" #include "Data/PokemonBDSP_AutoStory_TrainerSight.h" #include "Data/PokemonBDSP_AutoStory_WalkRules.h" +#include "Pokemon/AutoStory/Pokemon_BuiltinStoryActions.h" +#include "Pokemon/AutoStory/Pokemon_TilePose.h" +#include "Pokemon/AutoStory/Types/Pokemon_GridPose.h" +#include "PokemonBDSP_AutoStory_StoryExecutor.h" +#include "PokemonBDSP_AutoStory_StoryPlaces.h" +#include "PokemonBDSP_AutoStory_StoryTable.h" +#include "Utils/PokemonBDSP_AutoStory_StoryLanguage.h" #include "Utils/PokemonBDSP_AutoStory_PlannedRoute.h" #include "Utils/PokemonBDSP_AutoStory_RouteIO.h" +#include "Utils/PokemonBDSP_AutoStory_RouteTiming.h" #include "PokemonBDSP_AutoStory_PlannedRoute_Tests.h" #include "Utils/PokemonBDSP_AutoStory_WalkResult.h" @@ -35,6 +44,10 @@ namespace{ using namespace std::chrono_literals; using Pokemon::Direction; +using Pokemon::GridPose; +using Pokemon::Pose; +using Pokemon::StoryStep; +using Pokemon::StoryStepKind; using Pokemon::TilePos; @@ -357,6 +370,355 @@ UnitTestResult test_open_leg_known_trainer(Logger&){ } +// The console as a small simulator: the player stands on one tile of +// `world`, walls and `obstacles` stop them, and every walk and tap moves +// them. Fails the case after `max_calls` calls (a walker that loops). +class SimulatedRouteIO : public RouteIO{ +public: + SimulatedRouteIO(const StoryWorld& world, TilePos at, std::vector obstacles, std::vector& notes) + : m_world(world) + , m_at(at) + , m_obstacles(std::move(obstacles)) + , m_notes(notes) + {} + + const TilePos& at() const{ + return m_at; + } + size_t tiles_walked() const{ + return m_walked; + } + + virtual WalkResult walk_to_wall(const RouteWallWalk& walk) override{ + count_call(); + const Milliseconds per_tile = route_ms_per_tile(walk.direction, MoveSpeed::WALK); + if (m_overshoot && walk.limit > ROUTE_START_DELAY){ + // A hold timed for n tiles (ROUTE_START_DELAY, then half a + // tile under n) goes on past them until a wall stops it. + const size_t tiles = (size_t)((walk.limit - ROUTE_START_DELAY + per_tile / 2) / per_tile); + const size_t want = tiles + (tiles * 35 + 99) / 100; + const size_t moved = move(walk.direction, want); + return {.stop = moved < want ? WalkStop::BLOCKED : WalkStop::LIMIT, .walked = walk.limit, + .wild_battles = 0, .moved_chunks = moved}; + } + const size_t moved = move(walk.direction, SIZE_MAX); + return {.stop = WalkStop::BLOCKED, .walked = ROUTE_START_DELAY + 800ms + per_tile * moved + per_tile / 2, + .wild_battles = 0, .moved_chunks = moved}; + } + // Fault class "a timed hold overshoots": a stick hold timed for n + // tiles goes 0..ceil(0.35 n) tiles further, unseen, until a wall stops + // it (lab-B 2026-11-11, Jubilife: runs timed for 10 tiles went about 13, + // three of three). D-pad taps are tile-exact (5 to 20 taps, every one + // moved) and walks to a wall end at the wall, so neither has a fault. + void overshoot_timed_holds(bool overshoot){ + m_overshoot = overshoot; + } + virtual WalkResult walk_taps(Direction direction, size_t tiles, const std::string&) override{ + count_call(); + const size_t moved = move(direction, tiles); + return {.stop = moved < tiles ? WalkStop::BLOCKED : WalkStop::LIMIT, .walked = 250ms * tiles, + .wild_battles = 0, .moved_chunks = moved}; + } + virtual void press(const RouteInput& input) override{ + // arrive() pauses for up to 3 s for a location banner the sim never + // shows: those pauses are not a walker that loops. + if (input.kind != RouteInputKind::PAUSE){ + count_call(); + } + // A tap under 100 ms only turns (route_turn_tap()). + if (input.kind == RouteInputKind::DPAD && input.hold >= 100ms){ + move(input.direction, input.count); + } + // A stick hold is timed: route_open_hold() is half a tile under n. + if (input.kind == RouteInputKind::STICK){ + const Milliseconds per_tile = route_ms_per_tile(input.direction, MoveSpeed::WALK); + const size_t tiles = (size_t)((input.hold + per_tile / 2) / per_tile); + const size_t over = m_overshoot ? (tiles * 35 + 99) / 100 : 0; + for (size_t press = 0; press < input.count; press++){ + move(input.direction, tiles + over); + } + } + } + virtual bool dialog_within(Milliseconds, Color) override{ + count_call(); + return false; + } + virtual bool holding_against_wall(Direction, const std::string&) override{ + count_call(); + return true; + } + virtual void look(const std::function&) override{} + virtual void note(const std::string& text, RouteNote kind) override{ + m_notes.push_back(text); + if (kind == RouteNote::FAILURE){ + throw RouteFailed{text}; + } + } + +private: + void count_call(){ + if (++m_calls > MAX_CALLS){ + throw RouteFailed{"the walker made more than " + std::to_string(MAX_CALLS) + " calls."}; + } + } + size_t move(Direction direction, size_t tiles){ + size_t moved = 0; + while (moved < tiles){ + const std::optional next = step(m_world, m_at, direction); + if (!next || std::find(m_obstacles.begin(), m_obstacles.end(), *next) != m_obstacles.end()){ + break; + } + m_at = *next; + moved++; + } + m_walked += moved; + return moved; + } + + static constexpr size_t MAX_CALLS = 300; + const StoryWorld& m_world; + TilePos m_at; + std::vector m_obstacles; + std::vector& m_notes; + size_t m_calls = 0; + size_t m_walked = 0; + bool m_overshoot = false; +}; + +StoryWorld jubilife_world(){ + StoryWorld world; + world.add("Jubilife City", story_map("JubilifeCity"), {0, 0}); + return world; +} + +// lab-B 2026-11-11 11:17 (00.05 to_the_center): a walk east stopped about +// 13 tiles short of the wall, which left 15 possible tiles, (49..53, +// 41..43). Something the map lacks stood east of us; with several possible +// tiles nothing was marked, so every replan chose "east 7 (to wall)" again, +// walked 0 tiles five times and gave up on "too many plans". A walk that +// never moved from several possible tiles must route around the tiles just +// past them. +UnitTestResult test_blocked_from_several_tiles(Logger&){ + const StoryWorld world = jubilife_world(); + std::vector from; + for (int y = 41; y <= 43; y++){ + for (int x = 49; x <= 53; x++){ + from.push_back({x, y}); + } + } + const TilePos goal{52, 41}; + std::vector notes; + SimulatedRouteIO io(world, {53, 41}, {{54, 41}}, notes); + RouteTrainers trainers{.sights = {}, .fight = [](const std::string&){}}; + try{ + walk_route(io, world, from, trainers, { + .goal = [goal](const TilePos& pos){ return pos == goal; }, + .label = "T", + .avoid = {}, + .costs = town_plan_costs(), + .speed = MoveSpeed::WALK, + }); + }catch (const RouteFailed& e){ + return "failed: " + e.message; + } + if (io.at() != goal){ + return "ended at " + Pokemon::to_string(io.at()) + ", not at (52, 41)."; + } + return true; +} + +size_t tiles_of(const std::vector& legs){ + size_t tiles = 0; + for (const PlannedLeg& leg : legs){ + tiles += leg.leg.tiles; + } + return tiles; +} + +// The fewest tiles from `from` to `goal` on Jubilife, open legs exact. +size_t jubilife_shortest(const StoryWorld& world, TilePos from, TilePos goal){ + const auto plan = plan_robust_route(world, from, goal, waypoint_plan_costs()); + return plan ? tiles_of(*plan) : 0; +} + +// lab-B 2026-11-11 13:38 (00.05 to_the_center from (48, 62)): "north 20 +// (open)" walked as a held run (3175 ms) overshot, the west leg after it +// stopped 9 tiles in, the walker put walls at (54, 41..43) and "arrived" +// at (52, 41) nowhere near the Center. Timed holds overshoot by up to +// ceil(0.35 n) tiles (three runs of 10 went about 13); taps are exact. +// With every timed hold overshooting the walk still ends on the tile. +UnitTestResult test_jubilife_center_held_overshoot(Logger&){ + const StoryWorld world = jubilife_world(); + const TilePos from{48, 62}; + const TilePos goal{52, 41}; + std::vector notes; + SimulatedRouteIO io(world, from, {}, notes); + io.overshoot_timed_holds(true); + RouteTrainers trainers{.sights = {}, .fight = [](const std::string&){}}; + try{ + walk_route(io, world, {from}, trainers, { + .goal = [goal](const TilePos& pos){ return pos == goal; }, + .label = "T", + .avoid = {}, + .costs = town_plan_costs(), + .speed = MoveSpeed::WALK, + }); + }catch (const RouteFailed& e){ + return "failed: " + e.message; + } + if (io.at() != goal){ + return "ended at " + Pokemon::to_string(io.at()) + ", not at (52, 41)."; + } + return true; +} + +// The same walk on the console: the kids at (52, 46) and (54, 46) stop a +// walk north up their columns. The walker replans from where it stopped +// and reaches the Center without a long way round. +UnitTestResult test_jubilife_center_kids(Logger&){ + const StoryWorld world = jubilife_world(); + const TilePos from{48, 62}; + const TilePos goal{52, 41}; + std::vector notes; + SimulatedRouteIO io(world, from, {{52, 46}, {54, 46}}, notes); + RouteTrainers trainers{.sights = {}, .fight = [](const std::string&){}}; + try{ + walk_route(io, world, {from}, trainers, { + .goal = [goal](const TilePos& pos){ return pos == goal; }, + .label = "T", + .avoid = {}, + .costs = town_plan_costs(), + .speed = MoveSpeed::WALK, + }); + }catch (const RouteFailed& e){ + return "failed: " + e.message; + } + if (io.at() != goal){ + return "ended at " + Pokemon::to_string(io.at()) + ", not at (52, 41)."; + } + const size_t least = jubilife_shortest(world, from, goal); + if (io.tiles_walked() * 10 > least * 13 + 40){ + return std::format("walked {} tiles where {} would do.", io.tiles_walked(), least); + } + return true; +} + +// One ROUTE step of the story table, from where the steps before it end. +struct StoryRoute{ + std::string name; + Pose from; + Pose goal; + std::string costs; +}; + +// Every ROUTE step whose start the table knows: a row's start, a ROUTE's +// target or a step's pose_after. Steps after any other step start +// unknown and are left out. +void add_story_route(const std::string& row, const StoryStep& step, std::optional& at, std::vector& routes){ + if (step.kind == StoryStepKind::ROUTE){ + const Pose goal = Pokemon::pose_of(Pokemon::story_arg(step.args, "target")); + if (at){ + routes.push_back({std::format("{} {}", row, step.name), *at, goal, step.action}); + } + at = goal; + }else{ + at.reset(); + } + if (step.pose_after){ + at = Pokemon::pose_of(*step.pose_after); + } +} +std::vector story_routes(){ + std::vector routes; + for (const StoryCheckpoint& row : story_checkpoints()){ + std::optional at; + if (row.start){ + at = Pokemon::pose_of(*row.start); + } + for (const StoryStep& step : row.steps){ + add_story_route(row.id, step, at, routes); + } + } + return routes; +} + +// Walks `route` from each of its start tiles on the simulated console, +// every timed hold overshooting if `overshoot`. Returns the tiles walked +// from each start, or why it failed. +std::string sweep_story_route(const StoryRoute& route, bool overshoot, std::vector& walked){ + const StoryWorld* world = story_plan_world(route.from.map, route.goal.map); + const std::optional costs = story_route_costs(route.costs); + if (world == nullptr || !costs){ + return route.name + ": no world or costs."; + } + std::vector targets; + for (const TilePos& pos : Pokemon::tiles_of(route.goal)){ + targets.push_back(story_to_world(*world, route.goal.map, pos)); + } + std::vector start; + for (const TilePos& pos : Pokemon::tiles_of(route.from)){ + start.push_back(story_to_world(*world, route.from.map, pos)); + } + for (const TilePos& from : start){ + std::vector notes; + SimulatedRouteIO io(*world, from, {}, notes); + io.overshoot_timed_holds(overshoot); + RouteTrainers trainers{.sights = story_trainers(*world), .fight = [](const std::string&){}}; + try{ + walk_route(io, *world, start, trainers, { + .goal = [&](const TilePos& pos){ return std::find(targets.begin(), targets.end(), pos) != targets.end(); }, + .label = route.name, + .avoid = {}, + .costs = *costs, + .speed = MoveSpeed::WALK, + }); + }catch (const RouteFailed& e){ + std::string last; + for (size_t i = notes.size() > 4 ? notes.size() - 4 : 0; i < notes.size(); i++){ + last += "\n " + notes[i]; + } + return std::format("{} from {}{}: {}{}", route.name, Pokemon::to_string(from), overshoot ? ", holds overshooting" : "", e.message, last); + } + if (std::find(targets.begin(), targets.end(), io.at()) == targets.end()){ + return std::format("{} from {}{}: ended at {}.", route.name, Pokemon::to_string(from), overshoot ? ", holds overshooting" : "", Pokemon::to_string(io.at())); + } + walked.push_back(io.tiles_walked()); + } + return ""; +} + +// Fault sweep: every story route, walked with every timed hold +// overshooting, still ends on its target. The log line per route gives the +// most tiles walked from any of its start tiles, without the fault and with +// it. +UnitTestResult test_story_routes_holds_overshoot(Logger& logger){ + std::string failures; + const std::vector routes = story_routes(); + for (const StoryRoute& route : routes){ + std::string line = route.name + ":"; + for (bool overshoot : {false, true}){ + std::vector walked; + const std::string error = sweep_story_route(route, overshoot, walked); + if (!error.empty()){ + failures += "\n " + error; + line += " FAIL"; + continue; + } + size_t most = 0; + for (size_t tiles : walked){ + most = std::max(most, tiles); + } + line += " " + std::to_string(most); + } + logger.log("[timed holds overshoot: no, yes] " + line); + } + if (!failures.empty()){ + return std::format("{} routes swept:{}", routes.size(), failures); + } + return true; +} + + struct PlannedRouteInput{ std::string name; std::function body; @@ -404,6 +766,22 @@ const PlannedRouteCase PLANNED_ROUTE_CASES[] = { .input = {"a known trainer stops an open leg", test_open_leg_known_trainer}, .expectation = {}, }, + { + .input = {"blocked from several possible tiles routes around", test_blocked_from_several_tiles}, + .expectation = {}, + }, + { + .input = {"Jubilife to the Center with timed holds overshooting", test_jubilife_center_held_overshoot}, + .expectation = {}, + }, + { + .input = {"Jubilife to the Center past the kids", test_jubilife_center_kids}, + .expectation = {}, + }, + { + .input = {"fault sweep: every story route with timed holds overshooting", test_story_routes_holds_overshoot}, + .expectation = {}, + }, }; void add_tests_AutoStory_PlannedRoute(UnitTestDatabase& database){ diff --git a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_StorySimulation_Tests.cpp b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_StorySimulation_Tests.cpp index e9f15c0632..79bab21f0a 100644 --- a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_StorySimulation_Tests.cpp +++ b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_StorySimulation_Tests.cpp @@ -27,6 +27,7 @@ #include "Pokemon/AutoStory/Types/Pokemon_GridPose.h" #include "Pokemon/AutoStory/Pokemon_TilePose.h" #include "Data/PokemonBDSP_AutoStory_RobustRoute.h" +#include "PokemonBDSP_AutoStory_PlanGolden.h" #include "Data/PokemonBDSP_AutoStory_WalkRules.h" #include "Utils/PokemonBDSP_AutoStory_Location.h" #include "Data/PokemonBDSP_AutoStory_PlanCosts.h" @@ -78,6 +79,7 @@ struct Walked{ std::optional at; std::string error; std::string plan; + std::vector golden = {}; }; // The tiles a plan walks. @@ -132,6 +134,15 @@ Walked plan_route(const Pose& from, const StoryStep& step){ for (const PlannedLeg& leg : *plan){ walked.plan += " " + to_string(leg.leg); } + walked.golden.push_back(std::format("{} costs={} from{} to{}", step.name, step.action.empty() ? "default" : step.action, + describe(from.map, Pokemon::tiles_of(from)), describe(goal.map, Pokemon::tiles_of(goal)))); + for (const PlannedLeg& leg : *plan){ + std::string line = std::format(" {} ->", to_string(leg.leg)); + for (const TilePos& pos : leg.after){ + line += std::format(" {}", describe(*world, pos)); + } + walked.golden.push_back(line); + } const std::string detour = detour_error(*world, start, at_goal, *plan); if (!detour.empty()){ return {std::nullopt, step.name + ": " + detour, walked.plan}; @@ -233,6 +244,8 @@ class FakeGame : public Pokemon::StoryStepExecutor{ std::vector& trace; std::map failures; std::vector plans; + // Every ROUTE's legs, one header line per route, for the golden test. + std::vector golden; explicit FakeGame(std::vector& trace) : trace(trace) @@ -291,6 +304,9 @@ class FakeGame : public Pokemon::StoryStepExecutor{ if (!walked.plan.empty()){ plans.push_back(walked.plan); } + for (const std::string& line : walked.golden){ + golden.push_back(std::format("{} {}", m_row, line)); + } return walked.at ? Pokemon::outcome_ok(*walked.at) : Pokemon::outcome_ok(Pose{}); } @@ -381,6 +397,35 @@ UnitTestResult test_whole_table(Logger& logger){ return true; } +// The legs planned for every ROUTE of the whole story, against the stored +// copy in PokemonBDSP_AutoStory_PlanGolden.h. A change that should not +// alter any plan must leave this byte-identical. To regenerate after an +// intended plan change: run this suite, and replace the lines of +// BDSP_PLAN_GOLDEN with the lines the failure logs after "GOLDEN|". +UnitTestResult test_golden_plans(Logger& logger){ + Simulation sim; + const Pokemon::SegmentReport report = sim.run({}, Language::English); + if (!report.completed){ + return "expected the whole story through:" + joined(sim.lines); + } + const std::vector& actual = sim.game.golden; + const size_t stored = sizeof(BDSP_PLAN_GOLDEN) / sizeof(BDSP_PLAN_GOLDEN[0]); + size_t first_diff = 0; + while (first_diff < actual.size() && first_diff < stored && actual[first_diff] == BDSP_PLAN_GOLDEN[first_diff]){ + first_diff++; + } + if (first_diff == actual.size() && first_diff == stored){ + return true; + } + for (const std::string& line : actual){ + logger.log(std::format("GOLDEN|{}", line)); + } + return std::format("plans differ from the golden at line {} ({} lines now, {} stored): now \"{}\", stored \"{}\".", + first_diff + 1, actual.size(), stored, + first_diff < actual.size() ? std::string_view(actual[first_diff]) : std::string_view(), + first_diff < stored ? BDSP_PLAN_GOLDEN[first_diff] : std::string_view()); +} + UnitTestResult test_start_and_end(Logger&){ Simulation sim; Pokemon::SegmentReport report = sim.run({.from = "00.04b", .to = "00.04d"}); @@ -623,6 +668,10 @@ const AutoStoryStorySimulationCase AUTO_STORY_STORY_SIMULATION_CASES[] = { .input = {"no hand-written legs but the listed ones", test_no_hand_written_legs}, .expectation = {}, }, + { + .input = {"plans match the golden", test_golden_plans}, + .expectation = {}, + }, }; void add_tests_AutoStory_StorySimulation(UnitTestDatabase& database){ diff --git a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/Utils/PokemonBDSP_AutoStory_PlannedRoute.cpp b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/Utils/PokemonBDSP_AutoStory_PlannedRoute.cpp index 02cfac9207..2bbc5c993e 100644 --- a/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/Utils/PokemonBDSP_AutoStory_PlannedRoute.cpp +++ b/SerialPrograms/Source/PokemonBDSP/Programs/AutoStory/Utils/PokemonBDSP_AutoStory_PlannedRoute.cpp @@ -268,6 +268,7 @@ class RouteWalker{ void talk_to_blocker(const std::string& leg_label); LegNext replan_from(const LegWalk& walk, std::vector stopped, const std::string& why); void mark_blocker(const LegWalk& walk, const std::vector& stopped); + void mark_tiles_past(const LegWalk& walk, const std::vector& stopped); RouteIO& m_io; const StoryWorld& m_maps; @@ -516,6 +517,9 @@ LegNext RouteWalker::stopped_short_of_wall(LegWalk& walk, size_t walked_tiles){ fail(m_io, walk.label + ": stopped early, and no tile fits."); } mark_blocker(walk, stopped); + if (never_moved(walk.result, walked_tiles)){ + mark_tiles_past(walk, stopped); + } return replan_from(walk, std::move(stopped), "stopped early after about " + std::to_string(walked_tiles) + " tiles"); } @@ -654,6 +658,9 @@ LegNext RouteWalker::blocked_open_leg(LegWalk& walk, size_t moved){ } stopped = sorted_unique(std::move(stopped)); mark_blocker(walk, stopped); + if (moved == 0){ + mark_tiles_past(walk, stopped); + } return replan_from(walk, std::move(stopped), "blocked after " + std::to_string(moved) + " of " + std::to_string(walk.planned.leg.tiles) + " tiles"); } @@ -839,6 +846,31 @@ void RouteWalker::mark_blocker(const LegWalk& walk, const std::vector& describe(m_maps, blocker) + "; marked it.", RouteNote::WARNING); } +// A walk that never moved from several possible tiles: whatever stopped it +// stands just past one of them, so mark the tiles just past them all +// (but the goal and the tiles we may stand on), or the next plan takes the +// same leg into it again. On lab-B (2026-11-11, 00.05) "east 7 (to wall)" +// from 15 possible tiles below Jubilife's Center walked 0 tiles in five +// plans in a row, and the route gave up on "too many plans". +void RouteWalker::mark_tiles_past(const LegWalk& walk, const std::vector& stopped){ + if (stopped.size() < 2){ + return; + } + std::vector marked; + for (const TilePos& pos : stopped){ + const std::optional next = step(m_grid, pos, walk.planned.leg.direction); + if (!next || m_plan.goal(*next) || std::find(stopped.begin(), stopped.end(), *next) != stopped.end()){ + continue; + } + m_grid.block(*next); + marked.push_back(*next); + } + if (!marked.empty()){ + m_io.note("[Route] " + walk.label + ": nothing moved from " + std::to_string(stopped.size()) + + " possible tiles; marked the tiles past them: " + describe(m_maps, sorted_unique(std::move(marked))) + ".", RouteNote::WARNING); + } +} + LegNext RouteWalker::replan_from(const LegWalk& walk, std::vector stopped, const std::string& why){ m_io.note(std::format("{}{}", ROUTE_LOG_TAG, route_replan_line(m_plan.label, route_log_leg(walk.planned.leg), why, route_tiles(m_maps, stopped))), RouteNote::WARNING); m_facing = walk.planned.leg.direction; diff --git a/SerialPrograms/cmake/SourceFiles.cmake b/SerialPrograms/cmake/SourceFiles.cmake index acf34b6d01..74160b3be6 100644 --- a/SerialPrograms/cmake/SourceFiles.cmake +++ b/SerialPrograms/cmake/SourceFiles.cmake @@ -1743,6 +1743,7 @@ file(GLOB LIBRARY_SOURCES Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_Maps_Tests.cpp Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_Maps_Tests.h Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlannedRoute_Tests.cpp + Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlanGolden.h Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_PlannedRoute_Tests.h Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_RoutePlanner_Tests.cpp Source/PokemonBDSP/Programs/AutoStory/PokemonBDSP_AutoStory_RoutePlanner_Tests.h