From 9313571610a7556330a6f3558624f91294b6ac74 Mon Sep 17 00:00:00 2001 From: Philippe Symons Date: Thu, 1 Aug 2024 10:11:24 +0200 Subject: [PATCH] Also add an option to Unlock the Unown doll in gen 2 --- include/menu/MenuFunctions.h | 1 + src/menu/MenuEntries.cpp | 10 ++++++++++ src/menu/MenuFunctions.cpp | 1 + 3 files changed, 12 insertions(+) diff --git a/include/menu/MenuFunctions.h b/include/menu/MenuFunctions.h index de53012..1ec0e19 100755 --- a/include/menu/MenuFunctions.h +++ b/include/menu/MenuFunctions.h @@ -10,6 +10,7 @@ extern const Move MOVE_SURF; extern const Move MOVE_FLY; extern const uint16_t GEN2_EVENTFLAG_DECORATION_PIKACHU_BED; +extern const uint16_t GEN2_EVENTFLAG_DECORATION_UNOWN_DOLL; extern const uint16_t GEN2_EVENTFLAG_DECORATION_TENTACOOL_DOLL; void activateFrameLog(void* context, const void* param); diff --git a/src/menu/MenuEntries.cpp b/src/menu/MenuEntries.cpp index c5489a1..f0921c5 100755 --- a/src/menu/MenuEntries.cpp +++ b/src/menu/MenuEntries.cpp @@ -34,6 +34,11 @@ MenuItemData gen2MenuEntries[] = { .onConfirmAction = gen2SetEventFlag, .itemParam = &GEN2_EVENTFLAG_DECORATION_PIKACHU_BED }, + { + .title = "Unlock Unown Doll", + .onConfirmAction = gen2SetEventFlag, + .itemParam = &GEN2_EVENTFLAG_DECORATION_UNOWN_DOLL + }, { .title = "Unlock Tentacool Doll", .onConfirmAction = gen2SetEventFlag, @@ -61,6 +66,11 @@ MenuItemData gen2CrystalMenuEntries[] = { .onConfirmAction = gen2SetEventFlag, .itemParam = &GEN2_EVENTFLAG_DECORATION_PIKACHU_BED }, + { + .title = "Unlock Unown Doll", + .onConfirmAction = gen2SetEventFlag, + .itemParam = &GEN2_EVENTFLAG_DECORATION_UNOWN_DOLL + }, { .title = "Unlock Tentacool Doll", .onConfirmAction = gen2SetEventFlag, diff --git a/src/menu/MenuFunctions.cpp b/src/menu/MenuFunctions.cpp index 9821aba..7de778a 100755 --- a/src/menu/MenuFunctions.cpp +++ b/src/menu/MenuFunctions.cpp @@ -15,6 +15,7 @@ const Move MOVE_FLY = Move::FLY; // based on https://github.com/kwsch/PKHeX/blob/master/PKHeX.Core/Resources/text/script/gen2/flags_c_en.txt const uint16_t GEN2_EVENTFLAG_DECORATION_PIKACHU_BED = 679; +const uint16_t GEN2_EVENTFLAG_DECORATION_UNOWN_DOLL = 712; const uint16_t GEN2_EVENTFLAG_DECORATION_TENTACOOL_DOLL = 715; typedef struct Gen1TeachPikachuParams