@@ -12,6 +12,127 @@ namespace PokemonAutomation{
1212namespace NintendoSwitch {
1313namespace PokemonSV {
1414
15+ // Does not include multiplayer quests
16+ const EnumDropdownDatabase<BBQuests>& BBQuests_database (){
17+ static EnumDropdownDatabase<BBQuests> database{
18+ {BBQuests::auto_10, " auto-10" , " Defeat 10 wild Pokemon using Auto Battle!" },
19+ {BBQuests::make_tm, " make-tm" , " Make yourself a TM!" },
20+ // {BBQuests::pickup_10, "pickup-10", "Pick up items on the ground 10 times!"},
21+ {BBQuests::sneak_up, " sneak-up" , " Successfully sneak up on 1 Pokemon and surprise them with a battle!" },
22+ {BBQuests::photo_fly, " photo-fly" , " Take a photo of a wild Pokemon in flight!" },
23+ {BBQuests::photo_swim, " photo-swim" , " Take a photo of a wild Pokemon that is swimming!" },
24+ {BBQuests::photo_canyon, " photo-canyon" , " Take a photo of a wild Pokemon in the Canyon Biome!" },
25+ {BBQuests::photo_coastal, " photo-coastal" , " Take a photo of a wild Pokemon in the Coastal Biome!" },
26+ {BBQuests::photo_polar, " photo-polar" , " Take a photo of a wild Pokemon in the Polar Biome!" },
27+ {BBQuests::photo_savanna, " photo-savanna" , " Take a photo of a wild Pokemon in the Savanna Biome!" },
28+ {BBQuests::tera_self_defeat," tera-self-defeat" , " Terastallize your Pokemon to defeat a wild Pokemon!" },
29+ {BBQuests::travel_500, " travel-500" , " Travel over 500 yards!" },
30+ {BBQuests::catch_any, " catch-any" , " Catch 1 Pokemon!" },
31+ {BBQuests::catch_normal, " catch-normal" , " Catch 1 Normal-type Pokemon!" },
32+ {BBQuests::catch_fighting, " catch-fighting" , " Catch 1 Fighting-type Pokemon!" },
33+ {BBQuests::catch_flying, " catch-flying" , " Catch 1 Flying-type Pokemon!" },
34+ {BBQuests::catch_poison, " catch-poison" , " Catch 1 Poison-type Pokemon!" },
35+ {BBQuests::catch_ground, " catch-ground" , " Catch 1 Ground-type Pokemon!" },
36+ {BBQuests::catch_rock, " catch-rock" , " Catch 1 Rock-type Pokemon!" },
37+ {BBQuests::catch_bug, " catch-bug" , " Catch 1 Bug-type Pokemon!" },
38+ {BBQuests::catch_ghost, " catch-ghost" , " Catch 1 Ghost-type Pokemon!" },
39+ {BBQuests::catch_steel, " catch-steel" , " Catch 1 Steel-type Pokemon!" },
40+ {BBQuests::catch_fire, " catch-fire" , " Catch 1 Fire-type Pokemon!" },
41+ {BBQuests::catch_water, " catch-water" , " Catch 1 Water-type Pokemon!" },
42+ {BBQuests::catch_grass, " catch-grass" , " Catch 1 Grass-type Pokemon!" },
43+ {BBQuests::catch_electric, " catch-electric" , " Catch 1 Electric-type Pokemon!" },
44+ {BBQuests::catch_psychic, " catch-psychic" , " Catch 1 Psychic-type Pokemon!" },
45+ {BBQuests::catch_ice, " catch-ice" , " Catch 1 Ice-type Pokemon!" },
46+ {BBQuests::catch_dragon, " catch-dragon" , " Catch 1 Dragon-type Pokemon!" },
47+ {BBQuests::catch_dark, " catch-dark" , " Catch 1 Dark-type Pokemon!" },
48+ {BBQuests::catch_fairy, " catch-fairy" , " Catch 1 Fairy-type Pokemon!" },
49+ {BBQuests::wash_pokemon, " wash-pokemon" , " Give your Pokemon a nice washing!" },
50+ {BBQuests::wild_tera, " wild-tera" , " Battle a wild Tera Pokemon!" },
51+ {BBQuests::auto_30, " auto-30" , " Defeat 30 wild Pokemon using Auto Battle!" },
52+ {BBQuests::tera_raid, " tera-raid" , " Claim victory in a Tera Raid Battle!" },
53+ {BBQuests::sandwich_three, " sandwich-three" , " Make a sandwich that uses at least 3 ingredients!" },
54+ {BBQuests::bitter_sandwich, " bitter-sandwich" , " Make a bitter sandwich!" },
55+ {BBQuests::sweet_sandwich, " sweet-sandwich" , " Make a sweet sandwich!" },
56+ {BBQuests::salty_sandwich, " salty-sandwich" , " Make a salty sandwich!" },
57+ {BBQuests::sour_sandwich, " sour-sandwich" , " Make a sour sandwich!" },
58+ {BBQuests::spicy_sandwich, " spicy-sandwich" , " Make a spicy sandwich!" },
59+ // {BBQuests::hatch_egg, "hatch-egg", "Hatch a Pokemon Egg!"},
60+ {BBQuests::photo_normal, " photo-normal" , " Take a photo of a wild Normal-type Pokemon!" },
61+ {BBQuests::photo_fighting, " photo-fighting" , " Take a photo of a wild Fighting-type Pokemon!" },
62+ {BBQuests::photo_flying, " photo-flying" , " Take a photo of a wild Flying-type Pokemon!" },
63+ {BBQuests::photo_poison, " photo-poison" , " Take a photo of a wild Poison-type Pokemon!" },
64+ {BBQuests::photo_ground, " photo-ground" , " Take a photo of a wild Ground-type Pokemon!" },
65+ {BBQuests::photo_rock, " photo-rock" , " Take a photo of a wild Rock-type Pokemon!" },
66+ {BBQuests::photo_bug, " photo-bug" , " Take a photo of a wild Bug-type Pokemon!" },
67+ {BBQuests::photo_ghost, " photo-ghost" , " Take a photo of a wild Ghost-type Pokemon!" },
68+ {BBQuests::photo_steel, " photo-steel" , " Take a photo of a wild Steel-type Pokemon!" },
69+ {BBQuests::photo_fire, " photo-fire" , " Take a photo of a wild Fire-type Pokemon!" },
70+ {BBQuests::photo_water, " photo-water" , " Take a photo of a wild Water-type Pokemon!" },
71+ {BBQuests::photo_grass, " photo-grass" , " Take a photo of a wild Grass-type Pokemon!" },
72+ {BBQuests::photo_electric, " photo-electric" , " Take a photo of a wild Electric-type Pokemon!" },
73+ {BBQuests::photo_psychic, " photo-psychic" , " Take a photo of a wild Psychic-type Pokemon!" },
74+ {BBQuests::photo_ice, " photo-ice" , " Take a photo of a wild Ice-type Pokemon!" },
75+ {BBQuests::photo_dragon, " photo-dragon" , " Take a photo of a wild Dragon-type Pokemon!" },
76+ {BBQuests::photo_dark, " photo-dark" , " Take a photo of a wild Dark-type Pokemon!" },
77+ {BBQuests::photo_fairy, " photo-fairy" , " Take a photo of a wild Fairy-type Pokemon!" },
78+ };
79+ return database;
80+ }
81+
82+ const EnumDropdownDatabase<BBQAction>& BBQAction_database (){
83+ static EnumDropdownDatabase<BBQAction> database{
84+ {BBQAction::run, " run" , " Run Quest" },
85+ {BBQAction::skip, " skip" , " Skip" },
86+ {BBQAction::reroll, " reroll" , " Reroll" },
87+ };
88+ return database;
89+ }
90+
91+ BBQuestTableRow::BBQuestTableRow (EditableTableOption& parent_table)
92+ : EditableTableRow(parent_table)
93+ , quest(BBQuests_database(), LockMode::UNLOCK_WHILE_RUNNING, BBQuests::auto_10)
94+ , action(BBQAction_database(), LockMode::UNLOCK_WHILE_RUNNING, BBQAction::skip)
95+ {
96+ PA_ADD_OPTION (quest);
97+ PA_ADD_OPTION (action);
98+ }
99+ std::unique_ptr<EditableTableRow> BBQuestTableRow::clone () const {
100+ std::unique_ptr<BBQuestTableRow> ret (new BBQuestTableRow (parent ()));
101+ ret->quest .set (quest);
102+ ret->action .set (action);
103+ return ret;
104+ }
105+
106+ BBQuestTable::BBQuestTable ()
107+ : EditableTableOption_t<BBQuestTableRow>(
108+ " <b>Quest Exclusions:</b><br>"
109+ " <b>Warning: Skipping Bonus quests will block the bonus slot.</b><br>"
110+ " Exclude the quests in the table. If you want to skip a quest, select it below. "
111+ " (Quests can be explicitly included, but this is not necessary.) "
112+ " Do not exclude too many quests, as rerolling costs BP. "
113+ " The program will automatically reroll all quests if none are possible, but will not handle being out of BP. "
114+ " Does not include egg hatching or pickup quests, as eggs are handled in other options and pickup is not possible. " ,
115+ // "Duplicates of the same quest",
116+ // duplicates will work in table order. might lead to weird behavior like rerolling and then marking a quest as complete.
117+ // won't break the program though.
118+ LockMode::LOCK_WHILE_RUNNING,
119+ make_defaults ()
120+ )
121+ {}
122+
123+ std::vector<std::string> BBQuestTable::make_header () const {
124+ return {
125+ " Quest" ,
126+ " Action" ,
127+ };
128+ }
129+ std::vector<std::unique_ptr<EditableTableRow>> BBQuestTable::make_defaults (){
130+ std::vector<std::unique_ptr<EditableTableRow>> ret;
131+ ret.emplace_back (new BBQuestTableRow (*this ));
132+ return ret;
133+ }
134+
135+
15136BBQOption::BBQOption (OCR::LanguageOCROption* language_option)
16137 : GroupOption(" Blueberry Quests" , LockMode::UNLOCK_WHILE_RUNNING)
17138 , m_language_owner(language_option == nullptr
@@ -81,6 +202,7 @@ BBQOption::BBQOption(OCR::LanguageOCROption* language_option)
81202 }
82203 PA_ADD_OPTION (NUM_QUESTS);
83204 PA_ADD_OPTION (SAVE_NUM_QUESTS);
205+ PA_ADD_OPTION (QUEST_EXCLUSIONS);
84206 PA_ADD_OPTION (INVERTED_FLIGHT);
85207 PA_ADD_OPTION (QUICKBALL);
86208 PA_ADD_OPTION (BALL_SELECT);
0 commit comments