Skip to content

Commit 368005d

Browse files
committed
Try to fix bench reset interruptions.
1 parent c357ae8 commit 368005d

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

SerialPrograms/Source/CommonFramework/Globals.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ namespace PokemonAutomation{
2626
const bool IS_BETA_VERSION = true;
2727
const int PROGRAM_VERSION_MAJOR = 0;
2828
const int PROGRAM_VERSION_MINOR = 59;
29-
const int PROGRAM_VERSION_PATCH = 2;
29+
const int PROGRAM_VERSION_PATCH = 3;
3030

3131
const std::string PROGRAM_VERSION_BASE =
3232
"v" + std::to_string(PROGRAM_VERSION_MAJOR) +

SerialPrograms/Source/PokemonLZA/Programs/PokemonLZA_BasicNavigation.cpp

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#include "CommonTools/Async/InferenceRoutines.h"
99
#include "CommonTools/VisualDetectors/BlackScreenDetector.h"
1010
#include "NintendoSwitch/Commands/NintendoSwitch_Commands_PushButtons.h"
11+
#include "NintendoSwitch/Commands/NintendoSwitch_Commands_Superscalar.h"
1112
#include "PokemonLZA/Inference/PokemonLZA_ButtonDetector.h"
1213
#include "PokemonLZA/Inference/PokemonLZA_SelectionArrowDetector.h"
1314
#include "PokemonLZA/Inference/PokemonLZA_DialogDetector.h"
@@ -73,7 +74,12 @@ void sit_on_bench(
7374
int ret = run_until<ProControllerContext>(
7475
console, context,
7576
[](ProControllerContext& context){
76-
pbf_mash_button(context, BUTTON_A, 30000ms);
77+
pbf_mash_button(context, BUTTON_A, 5000ms);
78+
for (int c = 0; c < 3; c++){
79+
pbf_move_left_joystick(context, 128, 255, 1000ms, 0ms);
80+
pbf_mash_button(context, BUTTON_B, 1000ms);
81+
pbf_mash_button(context, BUTTON_A, 5000ms);
82+
}
7783
},
7884
{black_screen}
7985
);
@@ -85,7 +91,7 @@ void sit_on_bench(
8591
default:
8692
OperationFailedException::fire(
8793
ErrorReport::SEND_ERROR_REPORT,
88-
"sit_on_bench(): No transition deteted after 30 seconds of mashing A.",
94+
"sit_on_bench(): No transition detected after 4 attempts.",
8995
console
9096
);
9197
}

0 commit comments

Comments
 (0)