summaryrefslogtreecommitdiff
path: root/src/data
diff options
context:
space:
mode:
Diffstat (limited to 'src/data')
-rwxr-xr-xsrc/data/field_event_obj/event_object_graphics_info_pointers.h14
-rwxr-xr-xsrc/data/field_event_obj/movement_action_func_tables.h20
-rw-r--r--src/data/party_menu.h1255
-rw-r--r--src/data/script_menu.h8
-rw-r--r--src/data/trade.h1197
-rw-r--r--src/data/union_room.h1044
-rwxr-xr-xsrc/data/wild_encounters.json7
-rwxr-xr-xsrc/data/wild_encounters.json.txt14
8 files changed, 3536 insertions, 23 deletions
diff --git a/src/data/field_event_obj/event_object_graphics_info_pointers.h b/src/data/field_event_obj/event_object_graphics_info_pointers.h
index 0b8aa79b2..661539d57 100755
--- a/src/data/field_event_obj/event_object_graphics_info_pointers.h
+++ b/src/data/field_event_obj/event_object_graphics_info_pointers.h
@@ -489,11 +489,11 @@ const struct EventObjectGraphicsInfo *const gEventObjectGraphicsInfoPointers[] =
};
const struct EventObjectGraphicsInfo *const gMauvilleOldManGraphicsInfoPointers[] = {
- &gEventObjectGraphicsInfo_Bard,
- &gEventObjectGraphicsInfo_Hipster,
- &gEventObjectGraphicsInfo_Trader,
- &gEventObjectGraphicsInfo_Storyteller,
- &gEventObjectGraphicsInfo_Giddy,
- &gEventObjectGraphicsInfo_UnusedMauvilleOldMan1,
- &gEventObjectGraphicsInfo_UnusedMauvilleOldMan2,
+ [MAUVILLE_MAN_BARD] = &gEventObjectGraphicsInfo_Bard,
+ [MAUVILLE_MAN_HIPSTER] = &gEventObjectGraphicsInfo_Hipster,
+ [MAUVILLE_MAN_TRADER] = &gEventObjectGraphicsInfo_Trader,
+ [MAUVILLE_MAN_STORYTELLER] = &gEventObjectGraphicsInfo_Storyteller,
+ [MAUVILLE_MAN_GIDDY] = &gEventObjectGraphicsInfo_Giddy,
+ [MAUVILLE_MAN_UNUSED1] = &gEventObjectGraphicsInfo_UnusedMauvilleOldMan1,
+ [MAUVILLE_MAN_UNUSED2] = &gEventObjectGraphicsInfo_UnusedMauvilleOldMan2,
};
diff --git a/src/data/field_event_obj/movement_action_func_tables.h b/src/data/field_event_obj/movement_action_func_tables.h
index 712988f5e..8e136b58b 100755
--- a/src/data/field_event_obj/movement_action_func_tables.h
+++ b/src/data/field_event_obj/movement_action_func_tables.h
@@ -170,8 +170,8 @@ u8 MovementAction_SetFixedPriority_Step0(struct EventObject *, struct Sprite *);
u8 MovementAction_ClearFixedPriority_Step0(struct EventObject *, struct Sprite *);
u8 MovementAction_InitAffineAnim_Step0(struct EventObject *, struct Sprite *);
u8 MovementAction_ClearAffineAnim_Step0(struct EventObject *, struct Sprite *);
-u8 MovementAction_Unknown1_Step0(struct EventObject *, struct Sprite *);
-u8 MovementAction_Unknown2_Step0(struct EventObject *, struct Sprite *);
+u8 MovementAction_HideReflection_Step0(struct EventObject *, struct Sprite *);
+u8 MovementAction_ShowReflection_Step0(struct EventObject *, struct Sprite *);
u8 MovementAction_WalkDownStartAffine_Step0(struct EventObject *, struct Sprite *);
u8 MovementAction_WalkDownStartAffine_Step1(struct EventObject *, struct Sprite *);
u8 MovementAction_WalkDownAffine_Step0(struct EventObject *, struct Sprite *);
@@ -358,8 +358,8 @@ u8 (*const gMovementActionFuncs_SetFixedPriority[])(struct EventObject *, struct
u8 (*const gMovementActionFuncs_ClearFixedPriority[])(struct EventObject *, struct Sprite *);
u8 (*const gMovementActionFuncs_InitAffineAnim[])(struct EventObject *, struct Sprite *);
u8 (*const gMovementActionFuncs_ClearAffineAnim[])(struct EventObject *, struct Sprite *);
-u8 (*const gMovementActionFuncs_Unknown1[])(struct EventObject *, struct Sprite *);
-u8 (*const gMovementActionFuncs_Unknown2[])(struct EventObject *, struct Sprite *);
+u8 (*const gMovementActionFuncs_HideReflection[])(struct EventObject *, struct Sprite *);
+u8 (*const gMovementActionFuncs_ShowReflection[])(struct EventObject *, struct Sprite *);
u8 (*const gMovementActionFuncs_WalkDownStartAffine[])(struct EventObject *, struct Sprite *);
u8 (*const gMovementActionFuncs_WalkDownAffine[])(struct EventObject *, struct Sprite *);
u8 (*const gMovementActionFuncs_AcroWheelieFaceDown[])(struct EventObject *, struct Sprite *);
@@ -518,8 +518,8 @@ u8 (*const *const gMovementActionFuncs[])(struct EventObject *, struct Sprite *)
[MOVEMENT_ACTION_CLEAR_FIXED_PRIORITY] = gMovementActionFuncs_ClearFixedPriority,
[MOVEMENT_ACTION_INIT_AFFINE_ANIM] = gMovementActionFuncs_InitAffineAnim,
[MOVEMENT_ACTION_CLEAR_AFFINE_ANIM] = gMovementActionFuncs_ClearAffineAnim,
- [MOVEMENT_ACTION_UNKNOWN1] = gMovementActionFuncs_Unknown1,
- [MOVEMENT_ACTION_UNKNOWN2] = gMovementActionFuncs_Unknown2,
+ [MOVEMENT_ACTION_HIDE_REFLECTION] = gMovementActionFuncs_HideReflection,
+ [MOVEMENT_ACTION_SHOW_REFLECTION] = gMovementActionFuncs_ShowReflection,
[MOVEMENT_ACTION_WALK_DOWN_START_AFFINE] = gMovementActionFuncs_WalkDownStartAffine,
[MOVEMENT_ACTION_WALK_DOWN_AFFINE] = gMovementActionFuncs_WalkDownAffine,
[MOVEMENT_ACTION_ACRO_WHEELIE_FACE_DOWN] = gMovementActionFuncs_AcroWheelieFaceDown,
@@ -1197,13 +1197,13 @@ u8 (*const gMovementActionFuncs_ClearAffineAnim[])(struct EventObject *, struct
MovementAction_Finish,
};
-u8 (*const gMovementActionFuncs_Unknown1[])(struct EventObject *, struct Sprite *) = {
- MovementAction_Unknown1_Step0,
+u8 (*const gMovementActionFuncs_HideReflection[])(struct EventObject *, struct Sprite *) = {
+ MovementAction_HideReflection_Step0,
MovementAction_Finish,
};
-u8 (*const gMovementActionFuncs_Unknown2[])(struct EventObject *, struct Sprite *) = {
- MovementAction_Unknown2_Step0,
+u8 (*const gMovementActionFuncs_ShowReflection[])(struct EventObject *, struct Sprite *) = {
+ MovementAction_ShowReflection_Step0,
MovementAction_Finish,
};
diff --git a/src/data/party_menu.h b/src/data/party_menu.h
new file mode 100644
index 000000000..6af8ee2a6
--- /dev/null
+++ b/src/data/party_menu.h
@@ -0,0 +1,1255 @@
+static const struct BgTemplate sPartyMenuBgTemplates[] =
+{
+ {
+ .bg = 0,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 31,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 1,
+ .baseTile = 0
+ },
+ {
+ .bg = 1,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 30,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 2,
+ .baseTile = 0
+ },
+ {
+ .bg = 2,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 28,
+ .screenSize = 1,
+ .paletteMode = 0,
+ .priority = 0,
+ .baseTile = 0
+ },
+};
+
+enum
+{
+ PARTY_BOX_LEFT_COLUMN,
+ PARTY_BOX_RIGHT_COLUMN
+};
+
+static const struct PartyMenuBoxInfoRects sPartyBoxInfoRects[] =
+{
+ [PARTY_BOX_LEFT_COLUMN] =
+ {
+ BlitBitmapToPartyWindow_LeftColumn,
+ {
+ //The below are the x, y, width, and height for each of the following info
+ 24, 11, 40, 13, // Nickname
+ 32, 20, 32, 8, // Level
+ 64, 20, 8, 8, // Gender
+ 38, 37, 24, 8, // HP
+ 53, 37, 24, 8, // Max HP
+ 24, 35, 48, 3 // HP bar
+ },
+ 12, 34, 64, 16 // Description text (e.g. NO USE)
+ },
+ [PARTY_BOX_RIGHT_COLUMN] =
+ {
+ BlitBitmapToPartyWindow_RightColumn,
+ {
+ // See above comment
+ 22, 3, 40, 13, // Nickname
+ 30, 12, 32, 8, // Level
+ 62, 12, 8, 8, // Gender
+ 102, 12, 24, 8, // HP
+ 117, 12, 24, 8, // Max HP
+ 88, 10, 48, 3 // HP bar
+ },
+ 77, 4, 64, 16 // Description text
+ },
+};
+
+
+// Each layout array has an array for each of the 6 party slots
+// The array for each slot has the sprite coords of its various sprites in the following order
+// Pokemon icon (x, y), held item (x, y), status condition (x, y), menu pokeball (x, y)
+static const u8 sPartyMenuSpriteCoords[PARTY_LAYOUT_COUNT][PARTY_SIZE][4 * 2] =
+{
+ [PARTY_LAYOUT_SINGLE] =
+ {
+ { 16, 40, 20, 50, 50, 52, 16, 34},
+ {104, 18, 108, 28, 136, 27, 102, 25},
+ {104, 42, 108, 52, 136, 51, 102, 49},
+ {104, 66, 108, 76, 136, 75, 102, 73},
+ {104, 90, 108, 100, 136, 99, 102, 97},
+ {104, 114, 108, 124, 136, 123, 102, 121},
+ },
+ [PARTY_LAYOUT_DOUBLE] =
+ {
+ {16, 24, 20, 34, 50, 36, 16, 18},
+ {16, 80, 20, 90, 50, 92, 16, 74},
+ {104, 18, 108, 28, 136, 27, 102, 25},
+ {104, 50, 108, 60, 136, 59, 102, 57},
+ {104, 82, 108, 92, 136, 91, 102, 89},
+ {104, 114, 108, 124, 136, 123, 102, 121},
+ },
+ [PARTY_LAYOUT_MULTI] =
+ {
+ {16, 24, 20, 34, 50, 36, 16, 18},
+ {16, 80, 20, 90, 50, 92, 16, 74},
+ {104, 26, 106, 36, 136, 35, 102, 33},
+ {104, 50, 106, 60, 136, 59, 102, 57},
+ {104, 82, 106, 92, 136, 91, 102, 89},
+ {104, 106, 106, 116, 136, 115, 102, 113},
+ },
+ [PARTY_LAYOUT_MULTI_SHOWCASE] =
+ {
+ {16, 32, 20, 42, 50, 44, 16, 26},
+ {104, 34, 106, 44, 136, 43, 102, 41},
+ {104, 58, 106, 68, 136, 67, 102, 65},
+ {16, 104, 20, 114, 50, 116, 16, 98},
+ {104, 106, 106, 116, 136, 115, 102, 113},
+ {104, 130, 106, 140, 136, 139, 102, 137},
+ },
+};
+
+// Used only when both Cancel and Confirm are present
+static const u32 sConfirmButton_Tilemap[] = INCBIN_U32("graphics/interface/party_menu_confirm_button.bin");
+static const u32 sCancelButton_Tilemap[] = INCBIN_U32("graphics/interface/party_menu_cancel_button.bin");
+
+// Text colors for BG, FG, and Shadow in that order
+static const u8 sFontColorTable[][3] =
+{
+ {TEXT_COLOR_TRANSPARENT, TEXT_COLOR_LIGHT_GREY, TEXT_COLOR_DARK_GREY}, // Default
+ {TEXT_COLOR_TRANSPARENT, TEXT_COLOR_WHITE, TEXT_COLOR_GREEN}, // Unused
+ {TEXT_COLOR_TRANSPARENT, TEXT_DYNAMIC_COLOR_2, TEXT_DYNAMIC_COLOR_3}, // Gender symbol
+ {TEXT_COLOR_WHITE, TEXT_COLOR_DARK_GREY, TEXT_COLOR_LIGHT_GREY}, // Selection actions
+ {TEXT_COLOR_WHITE, TEXT_COLOR_BLUE, TEXT_COLOR_LIGHT_BLUE}, // Field moves
+ {TEXT_COLOR_TRANSPARENT, TEXT_COLOR_WHITE, TEXT_COLOR_DARK_GREY}, // Unused
+};
+
+static const struct WindowTemplate sSinglePartyMenuWindowTemplate[] =
+{
+ {
+ .bg = 0,
+ .tilemapLeft = 1,
+ .tilemapTop = 3,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 3,
+ .baseBlock = 0x63,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 1,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 4,
+ .baseBlock = 0xA9,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 4,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 5,
+ .baseBlock = 0xDF,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 7,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 6,
+ .baseBlock = 0x115,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 10,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 7,
+ .baseBlock = 0x14B,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 13,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 8,
+ .baseBlock = 0x181,
+ },
+ {
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 15,
+ .width = 28,
+ .height = 4,
+ .paletteNum = 14,
+ .baseBlock = 0x1DF,
+ },
+ DUMMY_WIN_TEMPLATE
+};
+
+static const struct WindowTemplate sDoublePartyMenuWindowTemplate[] =
+{
+ {
+ .bg = 0,
+ .tilemapLeft = 1,
+ .tilemapTop = 1,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 3,
+ .baseBlock = 0x63,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 1,
+ .tilemapTop = 8,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 4,
+ .baseBlock = 0xA9,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 1,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 5,
+ .baseBlock = 0xEF,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 5,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 6,
+ .baseBlock = 0x125,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 9,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 7,
+ .baseBlock = 0x15B,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 13,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 8,
+ .baseBlock = 0x191,
+ },
+ {
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 15,
+ .width = 28,
+ .height = 4,
+ .paletteNum = 14,
+ .baseBlock = 0x1DF,
+ },
+ DUMMY_WIN_TEMPLATE
+};
+
+static const struct WindowTemplate sMultiPartyMenuWindowTemplate[] =
+{
+ {
+ .bg = 0,
+ .tilemapLeft = 1,
+ .tilemapTop = 1,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 3,
+ .baseBlock = 0x63,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 1,
+ .tilemapTop = 8,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 4,
+ .baseBlock = 0xA9,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 2,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 5,
+ .baseBlock = 0xEF,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 5,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 6,
+ .baseBlock = 0x125,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 9,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 7,
+ .baseBlock = 0x15B,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 12,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 8,
+ .baseBlock = 0x191,
+ },
+ {
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 15,
+ .width = 28,
+ .height = 4,
+ .paletteNum = 14,
+ .baseBlock = 0x1DF,
+ },
+ DUMMY_WIN_TEMPLATE
+};
+
+static const struct WindowTemplate sShowcaseMultiPartyMenuWindowTemplate[] =
+{
+ {
+ .bg = 0,
+ .tilemapLeft = 1,
+ .tilemapTop = 2,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 3,
+ .baseBlock = 0x63,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 3,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 5,
+ .baseBlock = 0xA9,
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 12,
+ .tilemapTop = 6,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 6,
+ .baseBlock = 0xDF,
+ },
+ {
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 11,
+ .width = 10,
+ .height = 7,
+ .paletteNum = 4,
+ .baseBlock = 0x115,
+ },
+ {
+ .bg = 2,
+ .tilemapLeft = 12,
+ .tilemapTop = 12,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 7,
+ .baseBlock = 0x16B,
+ },
+ {
+ .bg = 2,
+ .tilemapLeft = 12,
+ .tilemapTop = 15,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 8,
+ .baseBlock = 0x1A1,
+ },
+ DUMMY_WIN_TEMPLATE
+};
+
+static const struct WindowTemplate sCancelButtonWindowTemplate =
+{
+ .bg = 0,
+ .tilemapLeft = 24,
+ .tilemapTop = 17,
+ .width = 6,
+ .height = 2,
+ .paletteNum = 3,
+ .baseBlock = 0x1C7,
+};
+
+static const struct WindowTemplate sMultiCancelButtonWindowTemplate =
+{
+ .bg = 0,
+ .tilemapLeft = 24,
+ .tilemapTop = 18,
+ .width = 6,
+ .height = 2,
+ .paletteNum = 3,
+ .baseBlock = 0x1C7,
+};
+
+static const struct WindowTemplate sConfirmButtonWindowTemplate =
+{
+ .bg = 0,
+ .tilemapLeft = 24,
+ .tilemapTop = 16,
+ .width = 6,
+ .height = 2,
+ .paletteNum = 3,
+ .baseBlock = 0x1D3,
+};
+
+static const struct WindowTemplate sDefaultPartyMsgWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 17,
+ .width = 21,
+ .height = 2,
+ .paletteNum = 15,
+ .baseBlock = 0x24F,
+};
+
+static const struct WindowTemplate sDoWhatWithMonMsgWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 17,
+ .width = 16,
+ .height = 2,
+ .paletteNum = 15,
+ .baseBlock = 0x279,
+};
+
+static const struct WindowTemplate sDoWhatWithItemMsgWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 17,
+ .width = 20,
+ .height = 2,
+ .paletteNum = 15,
+ .baseBlock = 0x299,
+};
+
+static const struct WindowTemplate sDoWhatWithMailMsgWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 17,
+ .width = 18,
+ .height = 2,
+ .paletteNum = 15,
+ .baseBlock = 0x299,
+};
+
+static const struct WindowTemplate sWhichMoveMsgWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 17,
+ .width = 16,
+ .height = 2,
+ .paletteNum = 15,
+ .baseBlock = 0x299,
+};
+
+static const struct WindowTemplate sAlreadyHoldingOneMsgWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 1,
+ .tilemapTop = 15,
+ .width = 20,
+ .height = 4,
+ .paletteNum = 15,
+ .baseBlock = 0x299,
+};
+
+static const struct WindowTemplate sItemGiveTakeWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 23,
+ .tilemapTop = 13,
+ .width = 6,
+ .height = 6,
+ .paletteNum = 14,
+ .baseBlock = 0x39D,
+};
+
+static const struct WindowTemplate sMailReadTakeWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 21,
+ .tilemapTop = 13,
+ .width = 8,
+ .height = 6,
+ .paletteNum = 14,
+ .baseBlock = 0x39D,
+};
+
+static const struct WindowTemplate sMoveSelectWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 19,
+ .tilemapTop = 11,
+ .width = 10,
+ .height = 8,
+ .paletteNum = 14,
+ .baseBlock = 0x2E9,
+};
+
+static const struct WindowTemplate sPartyMenuYesNoWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 21,
+ .tilemapTop = 9,
+ .width = 5,
+ .height = 4,
+ .paletteNum = 14,
+ .baseBlock = 0x2E9,
+};
+
+static const struct WindowTemplate sLevelUpStatsWindowTemplate =
+{
+ .bg = 2,
+ .tilemapLeft = 19,
+ .tilemapTop = 1,
+ .width = 10,
+ .height = 11,
+ .paletteNum = 14,
+ .baseBlock = 0x2E9,
+};
+
+static const struct WindowTemplate sUnusedWindowTemplate_08615978 =
+{
+ .bg = 2,
+ .tilemapLeft = 2,
+ .tilemapTop = 15,
+ .width = 27,
+ .height = 4,
+ .paletteNum = 14,
+ .baseBlock = 0x1DF,
+};
+
+static const struct WindowTemplate sUnusedWindowTemplate_08615980 =
+{
+ .bg = 2,
+ .tilemapLeft = 0,
+ .tilemapTop = 13,
+ .width = 18,
+ .height = 3,
+ .paletteNum = 12,
+ .baseBlock = 0x39D,
+};
+
+// Tile nums
+static const u8 sMainSlotTileNums[] = {24, 25, 25, 25, 25, 25, 25, 25, 25, 26,
+ 32, 33, 33, 33, 33, 33, 33, 33, 33, 34,
+ 32, 33, 33, 33, 33, 33, 33, 33, 33, 34,
+ 32, 33, 33, 33, 33, 33, 33, 33, 33, 34,
+ 40, 59, 60, 58, 58, 58, 58, 58, 58, 61,
+ 15, 16, 16, 16, 16, 16, 16, 16, 16, 17,
+ 46, 47, 47, 47, 47, 47, 47, 47, 47, 48};
+
+static const u8 sMainSlotTileNums_Egg[] = {24, 25, 25, 25, 25, 25, 25, 25, 25, 26,
+ 32, 33, 33, 33, 33, 33, 33, 33, 33, 34,
+ 32, 33, 33, 33, 33, 33, 33, 33, 33, 34,
+ 32, 33, 33, 33, 33, 33, 33, 33, 33, 34,
+ 40, 41, 41, 41, 41, 41, 41, 41, 41, 42,
+ 15, 16, 16, 16, 16, 16, 16, 16, 16, 17,
+ 46, 47, 47, 47, 47, 47, 47, 47, 47, 48};
+
+static const u8 sOtherSlotsTileNums[] = {43, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 45,
+ 49, 33, 33, 33, 33, 33, 33, 33, 33, 52, 53, 51, 51, 51, 51, 51, 51, 54,
+ 55, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 57};
+
+static const u8 sOtherSlotsTileNums_Egg[] = {43, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 44, 45,
+ 49, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, 50,
+ 55, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 57};
+
+static const u8 sEmptySlotTileNums[] = {21, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 22, 23,
+ 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 31,
+ 37, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 38, 39};
+
+// Palette offsets
+static const u8 sGenderPalOffsets[] = {11, 12};
+static const u8 sHPBarPalOffsets[] = {9, 10};
+static const u8 sPartyBoxPalOffsets1[] = {4, 5, 6};
+static const u8 sPartyBoxPalOffsets2[] = {1, 7, 8};
+static const u8 sPartyBoxNoMonPalOffsets[] = {1, 11, 12};
+
+// Palette ids
+static const u8 sGenderMalePalIds[] = {59, 60};
+static const u8 sGenderFemalePalIds[] = {75, 76};
+static const u8 sHPBarGreenPalIds[] = {57, 58};
+static const u8 sHPBarYellowPalIds[] = {73, 74};
+static const u8 sHPBarRedPalIds[] = {89, 90};
+static const u8 sPartyBoxEmptySlotPalIds1[] = {52, 53, 54};
+static const u8 sPartyBoxMultiPalIds1[] = {68, 69, 70};
+static const u8 sPartyBoxFaintedPalIds1[] = {84, 85, 86};
+static const u8 sPartyBoxCurrSelectionPalIds1[] = {116, 117, 118};
+static const u8 sPartyBoxCurrSelectionMultiPalIds[] = {132, 133, 134};
+static const u8 sPartyBoxCurrSelectionFaintedPalIds[] = {148, 149, 150};
+static const u8 sPartyBoxSelectedForActionPalIds1[] = {100, 101, 102};
+static const u8 sPartyBoxEmptySlotPalIds2[] = {49, 55, 56};
+static const u8 sPartyBoxMultiPalIds2[] = {65, 71, 72};
+static const u8 sPartyBoxFaintedPalIds2[] = {81, 87, 88};
+static const u8 sPartyBoxCurrSelectionPalIds2[] = {97, 103, 104};
+static const u8 sPartyBoxSelectedForActionPalIds2[] = {161, 167, 168};
+static const u8 sPartyBoxNoMonPalIds[] = {17, 27, 28};
+
+static const u8 *const sActionStringTable[] =
+{
+ [PARTY_MSG_CHOOSE_MON] = gText_ChoosePokemon,
+ [PARTY_MSG_CHOOSE_MON_OR_CANCEL] = gText_ChoosePokemonCancel,
+ [PARTY_MSG_CHOOSE_MON_AND_CONFIRM] = gText_ChoosePokemonConfirm,
+ [PARTY_MSG_MOVE_TO_WHERE] = gText_MoveToWhere,
+ [PARTY_MSG_TEACH_WHICH_MON] = gText_TeachWhichPokemon,
+ [PARTY_MSG_USE_ON_WHICH_MON] = gText_UseOnWhichPokemon,
+ [PARTY_MSG_GIVE_TO_WHICH_MON] = gText_GiveToWhichPokemon,
+ [PARTY_MSG_NOTHING_TO_CUT] = gText_NothingToCut,
+ [PARTY_MSG_CANT_SURF_HERE] = gText_CantSurfHere,
+ [PARTY_MSG_ALREADY_SURFING] = gText_AlreadySurfing,
+ [PARTY_MSG_CURRENT_TOO_FAST] = gText_CurrentIsTooFast,
+ [PARTY_MSG_ENJOY_CYCLING] = gText_EnjoyCycling,
+ [PARTY_MSG_ALREADY_IN_USE] = gText_InUseAlready_PM,
+ [PARTY_MSG_CANT_USE_HERE] = gText_CantUseHere,
+ [PARTY_MSG_NO_MON_FOR_BATTLE] = gText_NoPokemonForBattle,
+ [PARTY_MSG_CHOOSE_MON_2] = gText_ChoosePokemon2,
+ [PARTY_MSG_NOT_ENOUGH_HP] = gText_NotEnoughHp,
+ [PARTY_MSG_X_MONS_ARE_NEEDED] = gText_PokemonAreNeeded,
+ [PARTY_MSG_MONS_CANT_BE_SAME] = gText_PokemonCantBeSame,
+ [PARTY_MSG_NO_SAME_HOLD_ITEMS] = gText_NoIdenticalHoldItems,
+ [PARTY_MSG_UNUSED] = gText_EmptyString2,
+ [PARTY_MSG_DO_WHAT_WITH_MON] = gText_DoWhatWithPokemon,
+ [PARTY_MSG_RESTORE_WHICH_MOVE] = gText_RestoreWhichMove,
+ [PARTY_MSG_BOOST_PP_WHICH_MOVE] = gText_BoostPp,
+ [PARTY_MSG_DO_WHAT_WITH_ITEM] = gText_DoWhatWithItem,
+ [PARTY_MSG_DO_WHAT_WITH_MAIL] = gText_DoWhatWithMail,
+ [PARTY_MSG_ALREADY_HOLDING_ONE] = gText_AlreadyHoldingOne,
+};
+
+static const u8 *const sDescriptionStringTable[] =
+{
+ [PARTYBOX_DESC_NO_USE] = gText_NoUse,
+ [PARTYBOX_DESC_ABLE_3] = gText_Able,
+ [PARTYBOX_DESC_FIRST] = gText_First_PM,
+ [PARTYBOX_DESC_SECOND] = gText_Second_PM,
+ [PARTYBOX_DESC_THIRD] = gText_Third_PM,
+ [PARTYBOX_DESC_FOURTH] = gText_Fourth,
+ [PARTYBOX_DESC_ABLE] = gText_Able2,
+ [PARTYBOX_DESC_NOT_ABLE] = gText_NotAble,
+ [PARTYBOX_DESC_ABLE_2] = gText_Able3,
+ [PARTYBOX_DESC_NOT_ABLE_2] = gText_NotAble2,
+ [PARTYBOX_DESC_LEARNED] = gText_Learned,
+ [PARTYBOX_DESC_HAVE] = gText_Have,
+ [PARTYBOX_DESC_DONT_HAVE] = gText_DontHave,
+};
+
+static const u16 sUnused_08615B94[] =
+{
+ 0x0108, 0x0151, 0x0160, 0x015b, 0x002e, 0x005c, 0x0102, 0x0153, 0x014b, 0x00ed, 0x00f1, 0x010d, 0x003a, 0x003b, 0x003f, 0x0071,
+ 0x00b6, 0x00f0, 0x00ca, 0x00db, 0x00da, 0x004c, 0x00e7, 0x0055, 0x0057, 0x0059, 0x00d8, 0x005b, 0x005e, 0x00f7, 0x0118, 0x0068,
+ 0x0073, 0x015f, 0x0035, 0x00bc, 0x00c9, 0x007e, 0x013d, 0x014c, 0x0103, 0x0107, 0x0122, 0x009c, 0x00d5, 0x00a8, 0x00d3, 0x011d,
+ 0x0121, 0x013b, 0x000f, 0x0013, 0x0039, 0x0046, 0x0094, 0x00f9, 0x007f, 0x0123,
+};
+
+enum
+{
+ MENU_SUMMARY,
+ MENU_SWITCH,
+ MENU_CANCEL1,
+ MENU_ITEM,
+ MENU_GIVE,
+ MENU_TAKE_ITEM,
+ MENU_MAIL,
+ MENU_TAKE_MAIL,
+ MENU_READ,
+ MENU_CANCEL2,
+ MENU_SHIFT,
+ MENU_SEND_OUT,
+ MENU_ENTER,
+ MENU_NO_ENTRY,
+ MENU_STORE,
+ MENU_REGISTER,
+ MENU_TRADE1,
+ MENU_TRADE2,
+ MENU_TOSS,
+ MENU_FIELD_MOVES,
+};
+
+enum
+{
+ FIELD_MOVE_CUT,
+ FIELD_MOVE_FLASH,
+ FIELD_MOVE_ROCK_SMASH,
+ FIELD_MOVE_STRENGTH,
+ FIELD_MOVE_SURF,
+ FIELD_MOVE_FLY,
+ FIELD_MOVE_DIVE,
+ FIELD_MOVE_WATERFALL,
+ FIELD_MOVE_TELEPORT,
+ FIELD_MOVE_DIG,
+ FIELD_MOVE_SECRET_POWER,
+ FIELD_MOVE_MILK_DRINK,
+ FIELD_MOVE_SOFT_BOILED,
+ FIELD_MOVE_SWEET_SCENT,
+};
+
+// What a weird choice of table termination;
+#define FIELD_MOVE_TERMINATOR MOVE_SWORDS_DANCE
+
+struct
+{
+ const u8 *text;
+ TaskFunc func;
+} static const sCursorOptions[] =
+{
+ [MENU_SUMMARY] = {gText_Summary5, CursorCb_Summary},
+ [MENU_SWITCH] = {gText_Switch2, CursorCb_Switch},
+ [MENU_CANCEL1] = {gText_Cancel2, CursorCb_Cancel1},
+ [MENU_ITEM] = {gText_Item, CursorCb_Item},
+ [MENU_GIVE] = {gMenuText_Give, CursorCb_Give},
+ [MENU_TAKE_ITEM] = {gText_Take, CursorCb_TakeItem},
+ [MENU_MAIL] = {gText_Mail, CursorCb_Mail},
+ [MENU_TAKE_MAIL] = {gText_Take2, CursorCb_TakeMail},
+ [MENU_READ] = {gText_Read2, CursorCb_Read},
+ [MENU_CANCEL2] = {gText_Cancel2, CursorCb_Cancel2},
+ [MENU_SHIFT] = {gText_Shift, CursorCb_SendMon},
+ [MENU_SEND_OUT] = {gText_SendOut, CursorCb_SendMon},
+ [MENU_ENTER] = {gText_Enter, CursorCb_Enter},
+ [MENU_NO_ENTRY] = {gText_NoEntry, CursorCb_NoEntry},
+ [MENU_STORE] = {gText_Store, CursorCb_Store},
+ [MENU_REGISTER] = {gText_Register, CursorCb_Register},
+ [MENU_TRADE1] = {gText_Trade4, CursorCb_Trade1},
+ [MENU_TRADE2] = {gText_Trade4, CursorCb_Trade2},
+ [MENU_TOSS] = {gMenuText_Toss, CursorCb_Toss},
+ [MENU_FIELD_MOVES + FIELD_MOVE_CUT] = {gMoveNames[MOVE_CUT], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_FLASH] = {gMoveNames[MOVE_FLASH], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_ROCK_SMASH] = {gMoveNames[MOVE_ROCK_SMASH], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_STRENGTH] = {gMoveNames[MOVE_STRENGTH], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_SURF] = {gMoveNames[MOVE_SURF], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_FLY] = {gMoveNames[MOVE_FLY], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_DIVE] = {gMoveNames[MOVE_DIVE], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_WATERFALL] = {gMoveNames[MOVE_WATERFALL], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_TELEPORT] = {gMoveNames[MOVE_TELEPORT], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_DIG] = {gMoveNames[MOVE_DIG], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_SECRET_POWER] = {gMoveNames[MOVE_SECRET_POWER], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_MILK_DRINK] = {gMoveNames[MOVE_MILK_DRINK], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_SOFT_BOILED] = {gMoveNames[MOVE_SOFT_BOILED], CursorCb_FieldMove},
+ [MENU_FIELD_MOVES + FIELD_MOVE_SWEET_SCENT] = {gMoveNames[MOVE_SWEET_SCENT], CursorCb_FieldMove},
+};
+
+static const u8 sPartyMenuAction_SummarySwitchCancel[] = {MENU_SUMMARY, MENU_SWITCH, MENU_CANCEL1};
+static const u8 sPartyMenuAction_ShiftSummaryCancel[] = {MENU_SHIFT, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_SendOutSummaryCancel[] = {MENU_SEND_OUT, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_SummaryCancel[] = {MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_EnterSummaryCancel[] = {MENU_ENTER, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_NoEntrySummaryCancel[] = {MENU_NO_ENTRY, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_StoreSummaryCancel[] = {MENU_STORE, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_GiveTakeItemCancel[] = {MENU_GIVE, MENU_TAKE_ITEM, MENU_CANCEL2};
+static const u8 sPartyMenuAction_ReadTakeMailCancel[] = {MENU_READ, MENU_TAKE_MAIL, MENU_CANCEL2};
+static const u8 sPartyMenuAction_RegisterSummaryCancel[] = {MENU_REGISTER, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_TradeSummaryCancel1[] = {MENU_TRADE1, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_TradeSummaryCancel2[] = {MENU_TRADE2, MENU_SUMMARY, MENU_CANCEL1};
+static const u8 sPartyMenuAction_TakeItemTossCancel[] = {MENU_TAKE_ITEM, MENU_TOSS, MENU_CANCEL1};
+
+// IDs for the action lists that appear when a party mon is selected
+enum
+{
+ ACTIONS_NONE,
+ ACTIONS_SWITCH,
+ ACTIONS_SHIFT,
+ ACTIONS_SEND_OUT,
+ ACTIONS_ENTER,
+ ACTIONS_NO_ENTRY,
+ ACTIONS_STORE,
+ ACTIONS_SUMMARY_ONLY,
+ ACTIONS_ITEM,
+ ACTIONS_MAIL,
+ ACTIONS_REGISTER,
+ ACTIONS_TRADE,
+ ACTIONS_SPIN_TRADE,
+ ACTIONS_TAKEITEM_TOSS
+};
+
+static const u8 *const sPartyMenuActions[] =
+{
+ [ACTIONS_NONE] = NULL,
+ [ACTIONS_SWITCH] = sPartyMenuAction_SummarySwitchCancel,
+ [ACTIONS_SHIFT] = sPartyMenuAction_ShiftSummaryCancel,
+ [ACTIONS_SEND_OUT] = sPartyMenuAction_SendOutSummaryCancel,
+ [ACTIONS_ENTER] = sPartyMenuAction_EnterSummaryCancel,
+ [ACTIONS_NO_ENTRY] = sPartyMenuAction_NoEntrySummaryCancel,
+ [ACTIONS_STORE] = sPartyMenuAction_StoreSummaryCancel,
+ [ACTIONS_SUMMARY_ONLY] = sPartyMenuAction_SummaryCancel,
+ [ACTIONS_ITEM] = sPartyMenuAction_GiveTakeItemCancel,
+ [ACTIONS_MAIL] = sPartyMenuAction_ReadTakeMailCancel,
+ [ACTIONS_REGISTER] = sPartyMenuAction_RegisterSummaryCancel,
+ [ACTIONS_TRADE] = sPartyMenuAction_TradeSummaryCancel1,
+ [ACTIONS_SPIN_TRADE] = sPartyMenuAction_TradeSummaryCancel2,
+ [ACTIONS_TAKEITEM_TOSS] = sPartyMenuAction_TakeItemTossCancel,
+};
+
+static const u8 sPartyMenuActionCounts[] =
+{
+ [ACTIONS_NONE] = 0,
+ [ACTIONS_SWITCH] = ARRAY_COUNT(sPartyMenuAction_SummarySwitchCancel),
+ [ACTIONS_SHIFT] = ARRAY_COUNT(sPartyMenuAction_ShiftSummaryCancel),
+ [ACTIONS_SEND_OUT] = ARRAY_COUNT(sPartyMenuAction_SendOutSummaryCancel),
+ [ACTIONS_ENTER] = ARRAY_COUNT(sPartyMenuAction_EnterSummaryCancel),
+ [ACTIONS_NO_ENTRY] = ARRAY_COUNT(sPartyMenuAction_NoEntrySummaryCancel),
+ [ACTIONS_STORE] = ARRAY_COUNT(sPartyMenuAction_StoreSummaryCancel),
+ [ACTIONS_SUMMARY_ONLY] = ARRAY_COUNT(sPartyMenuAction_SummaryCancel),
+ [ACTIONS_ITEM] = ARRAY_COUNT(sPartyMenuAction_GiveTakeItemCancel),
+ [ACTIONS_MAIL] = ARRAY_COUNT(sPartyMenuAction_ReadTakeMailCancel),
+ [ACTIONS_REGISTER] = ARRAY_COUNT(sPartyMenuAction_RegisterSummaryCancel),
+ [ACTIONS_TRADE] = ARRAY_COUNT(sPartyMenuAction_TradeSummaryCancel1),
+ [ACTIONS_SPIN_TRADE] = ARRAY_COUNT(sPartyMenuAction_TradeSummaryCancel2),
+ [ACTIONS_TAKEITEM_TOSS] = ARRAY_COUNT(sPartyMenuAction_TakeItemTossCancel)
+};
+
+static const u16 sFieldMoves[] =
+{
+ MOVE_CUT, MOVE_FLASH, MOVE_ROCK_SMASH, MOVE_STRENGTH, MOVE_SURF, MOVE_FLY, MOVE_DIVE, MOVE_WATERFALL, MOVE_TELEPORT,
+ MOVE_DIG, MOVE_SECRET_POWER, MOVE_MILK_DRINK, MOVE_SOFT_BOILED, MOVE_SWEET_SCENT, FIELD_MOVE_TERMINATOR
+};
+
+struct
+{
+ bool8 (*fieldMoveFunc)(void);
+ u8 msgId;
+} static const sFieldMoveCursorCallbacks[] =
+{
+ [FIELD_MOVE_CUT] = {SetUpFieldMove_Cut, PARTY_MSG_NOTHING_TO_CUT},
+ [FIELD_MOVE_FLASH] = {SetUpFieldMove_Flash, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_ROCK_SMASH] = {SetUpFieldMove_RockSmash, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_STRENGTH] = {SetUpFieldMove_Strength, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_SURF] = {SetUpFieldMove_Surf, PARTY_MSG_CANT_SURF_HERE},
+ [FIELD_MOVE_FLY] = {SetUpFieldMove_Fly, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_DIVE] = {SetUpFieldMove_Dive, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_WATERFALL] = {SetUpFieldMove_Waterfall, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_TELEPORT] = {SetUpFieldMove_Teleport, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_DIG] = {SetUpFieldMove_Dig, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_SECRET_POWER] = {SetUpFieldMove_SecretPower, PARTY_MSG_CANT_USE_HERE},
+ [FIELD_MOVE_MILK_DRINK] = {SetUpFieldMove_SoftBoiled, PARTY_MSG_NOT_ENOUGH_HP},
+ [FIELD_MOVE_SOFT_BOILED] = {SetUpFieldMove_SoftBoiled, PARTY_MSG_NOT_ENOUGH_HP},
+ [FIELD_MOVE_SWEET_SCENT] = {SetUpFieldMove_SweetScent, PARTY_MSG_CANT_USE_HERE},
+};
+
+static const u8 *const sUnionRoomTradeMessages[] =
+{
+ [UR_TRADE_MSG_NOT_MON_PARTNER_WANTS - 1] = gText_NotPkmnOtherTrainerWants,
+ [UR_TRADE_MSG_NOT_EGG - 1] = gText_ThatIsntAnEgg,
+ [UR_TRADE_MSG_MON_CANT_BE_TRADED_1 - 1] = gText_PkmnCantBeTradedNow,
+ [UR_TRADE_MSG_MON_CANT_BE_TRADED_2 - 1] = gText_PkmnCantBeTradedNow,
+ [UR_TRADE_MSG_PARTNERS_MON_CANT_BE_TRADED - 1] = gText_OtherTrainersPkmnCantBeTraded,
+ [UR_TRADE_MSG_EGG_CANT_BE_TRADED -1] = gText_EggCantBeTradedNow,
+ [UR_TRADE_MSG_PARTNER_CANT_ACCEPT_MON - 1] = gText_OtherTrainerCantAcceptPkmn,
+ [UR_TRADE_MSG_CANT_TRADE_WITH_PARTNER_1 - 1] = gText_CantTradeWithTrainer,
+ [UR_TRADE_MSG_CANT_TRADE_WITH_PARTNER_2 - 1] = gText_CantTradeWithTrainer,
+};
+
+static const u32 sHeldItemGfx[] = INCBIN_U32("graphics/interface/hold_icons.4bpp");
+static const u16 sHeldItemPalette[] = INCBIN_U16("graphics/interface/hold_icons.gbapal");
+
+static const struct OamData sOamData_HeldItem =
+{
+ .y = 0,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = SPRITE_SHAPE(8x8),
+ .x = 0,
+ .matrixNum = 0,
+ .size = SPRITE_SIZE(8x8),
+ .tileNum = 0,
+ .priority = 1,
+ .paletteNum = 0,
+ .affineParam = 0,
+};
+
+static const union AnimCmd sSpriteAnim_HeldItem[] =
+{
+ ANIMCMD_FRAME(0, 1),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_HeldMail[] =
+{
+ ANIMCMD_FRAME(1, 1),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const sSpriteAnimTable_HeldItem[] =
+{
+ sSpriteAnim_HeldItem,
+ sSpriteAnim_HeldMail,
+};
+
+static const struct SpriteSheet sSpriteSheet_HeldItem =
+{
+ sHeldItemGfx, sizeof(sHeldItemGfx), 0xd750
+};
+
+static const struct SpritePalette sSpritePalette_HeldItem =
+{
+ sHeldItemPalette, 0xd750
+};
+
+static const struct SpriteTemplate sSpriteTemplate_HeldItem =
+{
+ 0xd750,
+ 0xd750,
+ &sOamData_HeldItem,
+ sSpriteAnimTable_HeldItem,
+ NULL,
+ gDummySpriteAffineAnimTable,
+ SpriteCallbackDummy
+};
+
+static const struct OamData sOamData_MenuPokeball =
+{
+ .y = 0,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = SPRITE_SHAPE(32x32),
+ .x = 0,
+ .matrixNum = 0,
+ .size = SPRITE_SIZE(32x32),
+ .tileNum = 0,
+ .priority = 1,
+ .paletteNum = 0,
+ .affineParam = 0
+};
+
+static const union AnimCmd sPokeballAnim_Closed[] =
+{
+ ANIMCMD_FRAME(0, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sPokeballAnim_Open[] =
+{
+ ANIMCMD_FRAME(16, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const sSpriteAnimTable_MenuPokeball[] =
+{
+ sPokeballAnim_Closed,
+ sPokeballAnim_Open
+};
+
+static const struct CompressedSpriteSheet sSpriteSheet_MenuPokeball =
+{
+ gPartyMenuPokeball_Gfx, 0x400, 0x04b0
+};
+
+static const struct CompressedSpritePalette sSpritePalette_MenuPokeball =
+{
+ gPartyMenuPokeball_Pal, 0x04b0
+};
+
+// Used for the pokeball sprite on each party slot / Cancel button
+static const struct SpriteTemplate sSpriteTemplate_MenuPokeball =
+{
+ .tileTag = 0x04b0,
+ .paletteTag = 0x04b0,
+ .oam = &sOamData_MenuPokeball,
+ .anims = sSpriteAnimTable_MenuPokeball,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCallbackDummy,
+};
+
+static const struct OamData sOamData_MenuPokeballSmall =
+{
+ .y = 0,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = SPRITE_SHAPE(16x16),
+ .x = 0,
+ .matrixNum = 0,
+ .size = SPRITE_SIZE(16x16),
+ .tileNum = 0,
+ .priority = 2,
+ .paletteNum = 0,
+ .affineParam = 0
+};
+
+static const union AnimCmd sSmallPokeballAnim_Closed[] =
+{
+ ANIMCMD_FRAME(0, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSmallPokeballAnim_Open[] =
+{
+ ANIMCMD_FRAME(4, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSmallPokeballAnim_Blank1[] =
+{
+ ANIMCMD_FRAME(8, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSmallPokeballAnim_Blank2[] =
+{
+ ANIMCMD_FRAME(12, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSmallPokeballAnim_Blank3[] =
+{
+ ANIMCMD_FRAME(16, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSmallPokeballAnim_Blank4[] =
+{
+ ANIMCMD_FRAME(20, 0),
+ ANIMCMD_END
+};
+
+// The blanks below are never used. See SpriteCB_BounceConfirmCancelButton, where they were intended to be used
+static const union AnimCmd *const sSpriteAnimTable_MenuPokeballSmall[] =
+{
+ sSmallPokeballAnim_Closed,
+ sSmallPokeballAnim_Open,
+ sSmallPokeballAnim_Blank1,
+ sSmallPokeballAnim_Blank2,
+ sSmallPokeballAnim_Blank3,
+ sSmallPokeballAnim_Blank4
+};
+
+static const struct CompressedSpriteSheet sSpriteSheet_MenuPokeballSmall =
+{
+ gPartyMenuPokeballSmall_Gfx, 0x0300, 0x04b1
+};
+
+// Used for the pokeball sprite next to Cancel and Confirm when both are present, otherwise sSpriteTemplate_MenuPokeball is used
+static const struct SpriteTemplate sSpriteTemplate_MenuPokeballSmall =
+{
+ .tileTag = 1201,
+ .paletteTag = 1200,
+ .oam = &sOamData_MenuPokeballSmall,
+ .anims = sSpriteAnimTable_MenuPokeballSmall,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCallbackDummy,
+};
+
+static const struct OamData sOamData_StatusCondition =
+{
+ .y = 0,
+ .affineMode = 0,
+ .objMode = 0,
+ .mosaic = 0,
+ .bpp = 0,
+ .shape = SPRITE_SHAPE(32x8),
+ .x = 0,
+ .matrixNum = 0,
+ .size = SPRITE_SIZE(32x8),
+ .tileNum = 0,
+ .priority = 1,
+ .paletteNum = 0,
+ .affineParam = 0
+};
+
+static const union AnimCmd sSpriteAnim_StatusPoison[] =
+{
+ ANIMCMD_FRAME(0, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_StatusParalyzed[] =
+{
+ ANIMCMD_FRAME(4, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_StatusSleep[] =
+{
+ ANIMCMD_FRAME(8, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_StatusFrozen[] =
+{
+ ANIMCMD_FRAME(12, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_StatusBurn[] =
+{
+ ANIMCMD_FRAME(16, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_StatusPokerus[] =
+{
+ ANIMCMD_FRAME(20, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_StatusFaint[] =
+{
+ ANIMCMD_FRAME(24, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd sSpriteAnim_Blank[] =
+{
+ ANIMCMD_FRAME(28, 0),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const sSpriteTemplate_StatusCondition[] =
+{
+ sSpriteAnim_StatusPoison,
+ sSpriteAnim_StatusParalyzed,
+ sSpriteAnim_StatusSleep,
+ sSpriteAnim_StatusFrozen,
+ sSpriteAnim_StatusBurn,
+ sSpriteAnim_StatusPokerus,
+ sSpriteAnim_StatusFaint,
+ sSpriteAnim_Blank
+};
+
+static const struct CompressedSpriteSheet sSpriteSheet_StatusIcons =
+{
+ gStatusGfx_Icons, 0x400, 1202
+};
+
+static const struct CompressedSpritePalette sSpritePalette_StatusIcons =
+{
+ gStatusPal_Icons, 1202
+};
+
+static const struct SpriteTemplate sSpriteTemplate_StatusIcons =
+{
+ .tileTag = 1202,
+ .paletteTag = 1202,
+ .oam = &sOamData_StatusCondition,
+ .anims = sSpriteTemplate_StatusCondition,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCallbackDummy,
+};
+
+// Mask for the partners party in a multi battle. TRUE if in the partners party, FALSE otherwise
+// The 7th slot is Cancel, and the 8th slot is unreachable
+// Used only to determine whether or not to show the Deoxys form icon sprite
+static const bool8 sMultiBattlePartnersPartyMask[PARTY_SIZE + 2] =
+{
+ FALSE,
+ TRUE,
+ FALSE,
+ FALSE,
+ TRUE,
+ TRUE,
+ FALSE
+};
+
+static const u8 *const sUnused_StatStrings[] =
+{
+ gText_HP4,
+ gText_Attack3,
+ gText_Defense3,
+ gText_SpAtk4,
+ gText_SpDef4,
+ gText_Speed2
+};
+
+static const u16 sTMHMMoves[] =
+{
+ MOVE_FOCUS_PUNCH,
+ MOVE_DRAGON_CLAW,
+ MOVE_WATER_PULSE,
+ MOVE_CALM_MIND,
+ MOVE_ROAR,
+ MOVE_TOXIC,
+ MOVE_HAIL,
+ MOVE_BULK_UP,
+ MOVE_BULLET_SEED,
+ MOVE_HIDDEN_POWER,
+ MOVE_SUNNY_DAY,
+ MOVE_TAUNT,
+ MOVE_ICE_BEAM,
+ MOVE_BLIZZARD,
+ MOVE_HYPER_BEAM,
+ MOVE_LIGHT_SCREEN,
+ MOVE_PROTECT,
+ MOVE_RAIN_DANCE,
+ MOVE_GIGA_DRAIN,
+ MOVE_SAFEGUARD,
+ MOVE_FRUSTRATION,
+ MOVE_SOLAR_BEAM,
+ MOVE_IRON_TAIL,
+ MOVE_THUNDERBOLT,
+ MOVE_THUNDER,
+ MOVE_EARTHQUAKE,
+ MOVE_RETURN,
+ MOVE_DIG,
+ MOVE_PSYCHIC,
+ MOVE_SHADOW_BALL,
+ MOVE_BRICK_BREAK,
+ MOVE_DOUBLE_TEAM,
+ MOVE_REFLECT,
+ MOVE_SHOCK_WAVE,
+ MOVE_FLAMETHROWER,
+ MOVE_SLUDGE_BOMB,
+ MOVE_SANDSTORM,
+ MOVE_FIRE_BLAST,
+ MOVE_ROCK_TOMB,
+ MOVE_AERIAL_ACE,
+ MOVE_TORMENT,
+ MOVE_FACADE,
+ MOVE_SECRET_POWER,
+ MOVE_REST,
+ MOVE_ATTRACT,
+ MOVE_THIEF,
+ MOVE_STEEL_WING,
+ MOVE_SKILL_SWAP,
+ MOVE_SNATCH,
+ MOVE_OVERHEAT,
+ MOVE_CUT,
+ MOVE_FLY,
+ MOVE_SURF,
+ MOVE_STRENGTH,
+ MOVE_FLASH,
+ MOVE_ROCK_SMASH,
+ MOVE_WATERFALL,
+ MOVE_DIVE,
+};
diff --git a/src/data/script_menu.h b/src/data/script_menu.h
index b64146a5d..3880c3c0c 100644
--- a/src/data/script_menu.h
+++ b/src/data/script_menu.h
@@ -31,7 +31,7 @@ static const struct MenuAction MultichoiceList_ContestType[] =
{gText_Exit},
};
-static const struct MenuAction MultichoiceList_DecorRegistry[] =
+static const struct MenuAction MultichoiceList_BasePCWithRegistry[] =
{
{gText_Decoration2},
{gText_PackUp},
@@ -39,7 +39,7 @@ static const struct MenuAction MultichoiceList_DecorRegistry[] =
{gText_Exit},
};
-static const struct MenuAction MultichoiceList_DecorNoRegistry[] =
+static const struct MenuAction MultichoiceList_BasePCNoRegistry[] =
{
{gText_Decoration2},
{gText_PackUp},
@@ -789,8 +789,8 @@ static const struct MultichoiceListStruct sMultichoiceLists[] =
[MULTI_ENTERINFO] = MULTICHOICE(MultichoiceList_EnterInfo),
[MULTI_CONTEST_INFO] = MULTICHOICE(MultichoiceList_ContestInfo),
[MULTI_CONTEST_TYPE] = MULTICHOICE(MultichoiceList_ContestType),
- [MULTI_DECOR_NOREGISTRY] = MULTICHOICE(MultichoiceList_DecorNoRegistry),
- [MULTI_DECOR_REGISTRY] = MULTICHOICE(MultichoiceList_DecorRegistry),
+ [MULTI_BASE_PC_NO_REGISTRY] = MULTICHOICE(MultichoiceList_BasePCNoRegistry),
+ [MULTI_BASE_PC_WITH_REGISTRY] = MULTICHOICE(MultichoiceList_BasePCWithRegistry),
[MULTI_REGISTER_MENU] = MULTICHOICE(MultichoiceList_RegisterMenu),
[MULTI_SSTIDAL_LILYCOVE] = MULTICHOICE(MultichoiceList_Exit),
[MULTI_UNUSED_9] = MULTICHOICE(MultichoiceList_Exit),
diff --git a/src/data/trade.h b/src/data/trade.h
new file mode 100644
index 000000000..9e96a54dd
--- /dev/null
+++ b/src/data/trade.h
@@ -0,0 +1,1197 @@
+// Exists unused in RS as well
+static const u32 sUnusedStructSizes[] =
+{
+ sizeof(struct SaveBlock2),
+ sizeof(struct SaveBlock1),
+ sizeof(struct MapHeader),
+ // 0x00000530, in RS
+ sizeof(struct MailStruct), //or EventObject / EventObjectGraphicsInfo
+ sizeof(struct Pokemon), //or TrainerCard
+ 0x00000528 // 0x000004D8, in RS
+};
+
+static const u16 sTradeMovesBoxTilemap[] = INCBIN_U16("graphics/trade/moves_box_map.bin");
+static const u16 sTradePartyBoxTilemap[] = INCBIN_U16("graphics/trade/party_box_map.bin");
+static const u8 sTradeStripesBG2Tilemap[] = INCBIN_U8("graphics/trade/stripes_bg2_map.bin");
+static const u8 sTradeStripesBG3Tilemap[] = INCBIN_U8("graphics/trade/stripes_bg3_map.bin");
+static const u8 sText_EmptyString[] = _("");
+static const u8 sText_UnusedTextFormat[] = _("{COLOR WHITE}{HIGHLIGHT TRANSPARENT}{SHADOW DARK_GREY}");
+const u8 gText_MaleSymbol4[] = _("♂");
+const u8 gText_FemaleSymbol4[] = _("♀");
+const u8 gText_GenderlessSymbol[] = _("");
+static const u8 sText_SpaceMove[] = _(" MOVE"); // unused
+static const u8 sText_NewLine[] = _("\n");
+static const u8 sText_Slash[] = _("/");
+static const u8 sText_Lv[] = _("Lv. ");
+static const u8 sText_ThreeDashes[] = _("---");
+static const u8 sText_FourQuestionMarks[] = _("????");
+static const u8 sText_832DAE4[] = _("");
+static const u8 sText_IsThisTradeOkay[] = _("Is this trade okay?");
+static const u8 sText_Cancel[] = _("CANCEL");
+static const u8 sText_ChooseAPkmn[] = _("Choose a POKéMON.");
+static const u8 sText_Summary[] = _("SUMMARY");
+static const u8 sText_Trade[] = _("TRADE");
+static const u8 sText_CancelTrade[] = _("Cancel trade?");
+static const u8 sJPText_PressBButtonToQuit[] = _("Bボタン で もどります");
+static const u8 sText_Summary2[] = _("SUMMARY");
+static const u8 sText_Trade2[] = _("TRADE");
+static const u8 sText_CommunicationStandby[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}Communication standby…\nPlease wait.");
+static const u8 sText_TheTradeHasBeenCanceled[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}The trade has\nbeen canceled.");
+static const u8 sText_OnlyPkmnForBattle[] = _("That's your only\nPOKéMON for battle.");
+static const u8 sText_WaitingForYourFriend[] = _("{COLOR DARK_GREY}{HIGHLIGHT WHITE}{SHADOW LIGHT_GREY}Waiting for your friend\nto finish…");
+static const u8 sText_YourFriendWantsToTrade[] = _("Your friend wants\nto trade POKéMON.");
+
+static const struct OamData sTradeOamData_32x16 =
+{
+ .shape = SPRITE_SHAPE(32x16),
+ .size = SPRITE_SIZE(32x16),
+ .priority = 1
+};
+
+static const struct OamData sTradeOamData_64x32 =
+{
+ .shape = SPRITE_SHAPE(64x32),
+ .size = SPRITE_SIZE(64x32),
+ .priority = 1
+};
+
+static const union AnimCmd gSpriteAnim_832DC24[] =
+{
+ ANIMCMD_FRAME(0, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_832DC2C[] =
+{
+ ANIMCMD_FRAME(32, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_832DC34[] =
+{
+ gSpriteAnim_832DC24,
+ gSpriteAnim_832DC2C
+};
+
+static const struct SpriteSheet sTradeButtonsSpriteSheet =
+{
+ .data = gTradeButtons_Gfx,
+ .size = 0x800,
+ .tag = 300
+};
+
+static const struct SpritePalette gUnknown_0832DC44 =
+{
+ .data = gUnknown_08DDB444,
+ .tag = 2345
+};
+
+static const union AnimCmd gSpriteAnim_832DC4C[] =
+{
+ ANIMCMD_FRAME(0, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_832DC54[] =
+{
+ ANIMCMD_FRAME(8, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_832DC5C[] =
+{
+ ANIMCMD_FRAME(16, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_832DC64[] =
+{
+ ANIMCMD_FRAME(24, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_832DC6C[] =
+{
+ ANIMCMD_FRAME(32, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_832DC74[] =
+{
+ ANIMCMD_FRAME(40, 5),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_832DC7C[] =
+{
+ gSpriteAnim_832DC4C,
+ gSpriteAnim_832DC54,
+ gSpriteAnim_832DC5C,
+ gSpriteAnim_832DC64,
+ gSpriteAnim_832DC6C,
+ gSpriteAnim_832DC74
+};
+
+static const struct SpriteTemplate gSpriteTemplate_832DC94 =
+{
+ .tileTag = 300,
+ .paletteTag = 2345,
+ .oam = &sTradeOamData_64x32,
+ .anims = gSpriteAnimTable_832DC34,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCallbackDummy,
+};
+
+static const struct SpriteTemplate gSpriteTemplate_832DCAC =
+{
+ .tileTag = 200,
+ .paletteTag = 4925,
+ .oam = &sTradeOamData_32x16,
+ .anims = gSpriteAnimTable_832DC7C,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = SpriteCallbackDummy,
+};
+
+static const u16 TradeScreenTextPalette[] = INCBIN_U16("graphics/trade/text.gbapal");
+static const struct SpritePalette gSpritePalette_TradeScreenText =
+{
+ .data = TradeScreenTextPalette,
+ .tag = 4925
+};
+
+// This is used to determine the next mon to select when the D-Pad is
+// pressed in a given direction.
+// Note that the mons are laid out like this.
+// 0-5 are the player's party and 6-11 are the trading partner's party.
+// 12 is the cancel button.
+// 0 1 6 7
+// 2 3 8 9
+// 4 5 10 11
+// 12
+// 1st array is the current positions
+// 2nd array is directions of input
+// 3rd array is the next positions to go to (unoccupied spaces are skipped over)
+static const u8 sTradeNextSelectedMonTable[(PARTY_SIZE * 2) + 1][4][PARTY_SIZE] =
+{
+ {
+ {4, 2, 12, 12, 0, 0}, // UP
+ {2, 4, 12, 12, 0, 0}, // DOWN
+ {7, 6, 1, 0, 0, 0}, // LEFT
+ {1, 6, 7, 0, 0, 0} // RIGHT
+ },
+ {
+ {5, 3, 12, 12, 0, 0},
+ {3, 5, 12, 12, 0, 0},
+ {0, 7, 6, 1, 0, 0},
+ {6, 7, 0, 1, 0, 0}
+ },
+ {
+ {0, 0, 0, 0, 0, 0},
+ {4, 0, 0, 0, 0, 0},
+ {9, 8, 7, 6, 0, 0},
+ {3, 1, 0, 0, 0, 0}
+ },
+ {
+ {1, 1, 1, 1, 0, 0},
+ {5, 1, 1, 1, 0, 0},
+ {2, 9, 8, 7, 0, 0},
+ {8, 9, 6, 6, 0, 0}
+ },
+ {
+ {2, 2, 2, 2, 0, 0},
+ {0, 0, 0, 0, 0, 0},
+ {11, 10, 9, 8, 7, 6},
+ {5, 3, 1, 0, 0, 0}
+ },
+ {
+ {3, 3, 3, 3, 0, 0},
+ {1, 1, 1, 1, 0, 0},
+ {4, 4, 4, 4, 0, 0},
+ {10, 8, 6, 0, 0, 0}
+ },
+ {
+ {10, 8, 12, 0, 0, 0},
+ {8, 10, 12, 0, 0, 0},
+ {1, 0, 0, 0, 0, 0},
+ {7, 0, 1, 0, 0, 0}
+ },
+ {
+ {12, 0, 0, 0, 0, 0},
+ {9, 12, 0, 0, 0, 0},
+ {6, 0, 0, 0, 0, 0},
+ {0, 0, 0, 0, 0, 0}
+ },
+ {
+ {6, 0, 0, 0, 0, 0},
+ {10, 6, 0, 0, 0, 0},
+ {3, 2, 1, 0, 0, 0},
+ {9, 7, 0, 0, 0, 0}
+ },
+ {
+ {7, 0, 0, 0, 0, 0},
+ {11, 12, 0, 0, 0, 0},
+ {8, 0, 0, 0, 0, 0},
+ {2, 1, 0, 0, 0, 0}
+ },
+ {
+ {8, 0, 0, 0, 0, 0},
+ {6, 0, 0, 0, 0, 0},
+ {5, 4, 3, 2, 1, 0},
+ {11, 9, 7, 0, 0, 0}
+ },
+ {
+ {9, 0, 0, 0, 0, 0},
+ {12, 0, 0, 0, 0, 0},
+ {10, 0, 0, 0, 0, 0},
+ {4, 2, 0, 0, 0, 0}
+ },
+ {
+ {11, 9, 7, 6, 0, 0},
+ {7, 6, 0, 0, 0, 0},
+ {12, 0, 0, 0, 0, 0},
+ {12, 0, 0, 0, 0, 0}
+ }
+};
+
+static const u8 sTradeMonSpriteCoords[(PARTY_SIZE * 2) + 1][2] =
+{
+ // Your party
+ {1, 5 },
+ {8, 5 },
+ {1, 10},
+ {8, 10},
+ {1, 15},
+ {8, 15},
+
+ // Friend's party
+ {16, 5 },
+ {23, 5 },
+ {16, 10},
+ {23, 10},
+ {16, 15},
+ {23, 15},
+
+ {23, 18} // CANCEL
+};
+
+static const u8 sTradeMonLevelCoords[][PARTY_SIZE][2] =
+{
+ {
+ // Your party
+ {5, 4},
+ {12, 4},
+ {5, 9},
+ {12, 9},
+ {5, 14},
+ {12, 14},
+ },
+ {
+ // Friend's party
+ {20, 4},
+ {27, 4},
+ {20, 9},
+ {27, 9},
+ {20, 14},
+ {27, 14}
+ }
+};
+
+static const u8 sTradeMonBoxCoords[][PARTY_SIZE][2] =
+{
+ {
+ // Your party
+ {1, 3},
+ {8, 3},
+ {1, 8},
+ {8, 8},
+ {1, 13},
+ {8, 13},
+ },
+ {
+ // Friend's party
+ {16, 3},
+ {23, 3},
+ {16, 8},
+ {23, 8},
+ {16, 13},
+ {23, 13}
+ }
+};
+
+static const u8 sUnref_0832DE6E[] =
+{
+ 0x00, 0x0e,
+ 0x0f, 0x1d,
+ 0x03, 0x05,
+ 0x03, 0x07,
+ 0x12, 0x05,
+ 0x12, 0x07,
+ 0x08, 0x07,
+ 0x16, 0x0c,
+ 0x08, 0x07,
+ 0x16, 0x0c,
+ 0x06, 0x07,
+ 0x18, 0x0c,
+ 0x06, 0x07,
+ 0x18, 0x0c,
+ 0x08, 0x07,
+ 0x16, 0x0c,
+ 0x07, 0x07,
+ 0x17, 0x0c
+};
+
+static const u8 *const sTradeActionTexts[] =
+{
+ [TRADE_TEXT_CANCEL] = sText_Cancel,
+ [TRADE_TEXT_CHOOSE_MON] = sText_ChooseAPkmn,
+ [TRADE_TEXT_SUMMARY] = sText_Summary,
+ [TRADE_TEXT_TRADE] = sText_Trade,
+ [TRADE_TEXT_CANCEL_TRADE] = sText_CancelTrade,
+ [TRADE_TEXT_JP_QUIT] = sJPText_PressBButtonToQuit
+};
+
+static const struct MenuAction sSelectTradeMonActions[] =
+{
+ {sText_Summary2, Task_DrawSelectionSummary},
+ {sText_Trade2, Task_DrawSelectionTrade}
+};
+
+static const u8 *const sTradeMessages[] =
+{
+ [TRADE_MSG_STANDBY] = sText_CommunicationStandby,
+ [TRADE_MSG_CANCELED] = sText_TheTradeHasBeenCanceled,
+ [TRADE_MSG_ONLY_MON1] = sText_OnlyPkmnForBattle,
+ [TRADE_MSG_ONLY_MON2] = gText_OnlyPkmnForBattle, //identical text to above
+ [TRADE_MSG_WAITING_FOR_FRIEND] = sText_WaitingForYourFriend,
+ [TRADE_MSG_FRIEND_WANTS_TO_TRADE] = sText_YourFriendWantsToTrade,
+ [TRADE_MSG_MON_CANT_BE_TRADED] = gText_PkmnCantBeTradedNow,
+ [TRADE_MSG_EGG_CANT_BE_TRADED] = gText_EggCantBeTradedNow,
+ [TRADE_MSG_FRIENDS_MON_CANT_BE_TRADED] = gText_OtherTrainersPkmnCantBeTraded
+};
+
+static const u8 sTradeTextColors[] =
+{
+ TEXT_COLOR_TRANSPARENT, //bg color
+ TEXT_COLOR_WHITE, //fg color
+ TEXT_COLOR_DARK_GREY //shadow color
+};
+
+static const struct BgTemplate sTradeMenuBgTemplates[] =
+{
+ {
+ .bg = 0,
+ .charBaseIndex = 2,
+ .mapBaseIndex = 31,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 0,
+ .baseTile = 0
+ },
+ {
+ .bg = 1,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 5,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 1,
+ .baseTile = 0
+ },
+ {
+ .bg = 2,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 6,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 2,
+ .baseTile = 0
+ },
+ {
+ .bg = 3,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 7,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 3,
+ .baseTile = 0
+ },
+};
+
+static const struct WindowTemplate sTradeMenuWindowTemplates[] =
+{
+ {
+ .bg = 0,
+ .tilemapLeft = 4,
+ .tilemapTop = 7,
+ .width = 22,
+ .height = 4,
+ .paletteNum = 15,
+ .baseBlock = 30
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 19,
+ .tilemapTop = 15,
+ .width = 10,
+ .height = 4,
+ .paletteNum = 15,
+ .baseBlock = 118
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 0,
+ .tilemapTop = 5,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 158
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 7,
+ .tilemapTop = 5,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 174
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 0,
+ .tilemapTop = 10,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 190
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 7,
+ .tilemapTop = 10,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 206
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 0,
+ .tilemapTop = 15,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 222
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 7,
+ .tilemapTop = 15,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 238
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 15,
+ .tilemapTop = 5,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 254
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 22,
+ .tilemapTop = 5,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 270
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 15,
+ .tilemapTop = 10,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 286
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 22,
+ .tilemapTop = 10,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 302
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 15,
+ .tilemapTop = 15,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 318
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 22,
+ .tilemapTop = 15,
+ .width = 8,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 334
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 2,
+ .tilemapTop = 5,
+ .width = 14,
+ .height = 2,
+ .paletteNum = 13,
+ .baseBlock = 350
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 3,
+ .tilemapTop = 8,
+ .width = 11,
+ .height = 8,
+ .paletteNum = 15,
+ .baseBlock = 378
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 17,
+ .tilemapTop = 5,
+ .width = 14,
+ .height = 2,
+ .paletteNum = 15,
+ .baseBlock = 466
+ },
+ {
+ .bg = 0,
+ .tilemapLeft = 18,
+ .tilemapTop = 8,
+ .width = 11,
+ .height = 8,
+ .paletteNum = 15,
+ .baseBlock = 494
+ },
+ DUMMY_WIN_TEMPLATE,
+};
+
+static const struct WindowTemplate sTradeYesNoWindowTemplate =
+{
+ .bg = 0,
+ .tilemapLeft = 23,
+ .tilemapTop = 13,
+ .width = 5,
+ .height = 4,
+ .paletteNum = 15,
+ .baseBlock = 582
+};
+
+static const u8 sJPText_Shedinja[] = _("ヌケニン");
+static const u8 sTradeMenuPartyMonBoxDimensions[3][2] =
+{
+ [TRADE_PLAYER] = {4, 3},
+ [TRADE_PARTNER] = {19, 3}
+};
+
+static const u16 sTradePal_PokeBall[] = INCBIN_U16("graphics/trade/pokeball.gbapal");
+static const u8 sTradeGfx_PokeBall[] = INCBIN_U8("graphics/trade/pokeball.4bpp");
+static const u8 sTradeGfx_PokeBallSymbol[] = INCBIN_U8("graphics/trade/pokeball_symbol.8bpp"); // unused?
+static const u16 sTradeTilemap_Cable[] = INCBIN_U16("graphics/trade/cable_closeup_map.bin");
+static const u16 sTradeTilemap_PokeBallSymbol[] = INCBIN_U16("graphics/trade/pokeball_symbol_map.bin"); // unused?
+static const u16 sUnref_083308C0[] = INCBIN_U16("graphics/trade/unknown_3308C0.gbapal");
+static const u16 sTradePal_Gba[] = INCBIN_U16("graphics/trade/gba.gbapal");
+static const u16 sTradePal_ShadowUnused[] = INCBIN_U16("graphics/trade/shadow.gbapal");
+static const u16 sTradePal_BlackUnused[] = INCBIN_U16("graphics/trade/black.gbapal");
+static const u16 sTradePal_Misc[] = INCBIN_U16("graphics/trade/misc.gbapal");
+static const u8 sTradeGfx_Glow1[] = INCBIN_U8("graphics/trade/glow1.4bpp");
+static const u8 sTradeGfx_Glow2[] = INCBIN_U8("graphics/trade/glow2.4bpp");
+static const u8 sTradeGfx_CableEnd[] = INCBIN_U8("graphics/trade/cable_end.4bpp");
+static const u8 sTradeGfx_GbaScreen[] = INCBIN_U8("graphics/trade/gba_screen.4bpp");
+const u16 gUnknown_08331F60[] = INCBIN_U16("graphics/trade/shadow_map.bin");
+static const u8 sTradeAffine_Gba[] = INCBIN_U8("graphics/trade/gba_affine.8bpp");
+static const u8 sFiller_08335760[64] = {};
+static const u8 sTradeAffineMap_GbaCable[] = INCBIN_U8("graphics/trade/gba_affine_map_cable.bin");
+static const u8 sTradeAffineMap_GbaWireless[] = INCBIN_U8("graphics/trade/gba_affine_map_wireless.bin");
+static const u16 sTradeTilemap_GbaWireless[] = INCBIN_U16("graphics/trade/gba_map_wireless.bin");
+static const u16 sTradeTilemap_GbaCable[] = INCBIN_U16("graphics/trade/gba_map_cable.bin");
+static const u32 gUnknown_083379A0[] = INCBIN_U32("graphics/trade/unknown_3379A0.bin.lz"); //some wireless tilemap
+static const u16 sTradePal_WirelessSignalSend[] = INCBIN_U16("graphics/trade/wireless_signal_send.gbapal");
+static const u16 sTradePal_WirelessSignalReceive[] = INCBIN_U16("graphics/trade/wireless_signal_receive.gbapal");
+static const u16 sTradePal_Black[] = INCBIN_U16("graphics/trade/black.gbapal");
+static const u32 sTradeGfx_WirelessSignal[] = INCBIN_U32("graphics/trade/wireless_signal.4bpp.lz");
+static const u32 sTradeTilemap_WirelessSignal[] = INCBIN_U32("graphics/trade/wireless_signal.bin.lz");
+
+static const struct OamData sTradeOamData_16x16 =
+{
+ .affineMode = 1,
+ .shape = SPRITE_SHAPE(16x16),
+ .size = SPRITE_SIZE(16x16)
+};
+
+static const union AnimCmd gSpriteAnim_8338C4C[] =
+{
+ ANIMCMD_FRAME( 0, 3),
+ ANIMCMD_FRAME( 4, 3),
+ ANIMCMD_FRAME( 8, 3),
+ ANIMCMD_FRAME(12, 3),
+ ANIMCMD_FRAME(16, 3),
+ ANIMCMD_FRAME(20, 3),
+ ANIMCMD_FRAME(24, 3),
+ ANIMCMD_FRAME(28, 3),
+ ANIMCMD_FRAME(32, 3),
+ ANIMCMD_FRAME(36, 3),
+ ANIMCMD_FRAME(40, 3),
+ ANIMCMD_FRAME(44, 3),
+ ANIMCMD_LOOP(1),
+ ANIMCMD_FRAME( 0, 3),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_8338C88[] =
+{
+ ANIMCMD_FRAME( 0, 3),
+ ANIMCMD_FRAME( 4, 3),
+ ANIMCMD_FRAME( 8, 3),
+ ANIMCMD_FRAME(12, 3),
+ ANIMCMD_FRAME(16, 3),
+ ANIMCMD_FRAME(20, 3),
+ ANIMCMD_FRAME(24, 3),
+ ANIMCMD_FRAME(28, 3),
+ ANIMCMD_FRAME(32, 3),
+ ANIMCMD_FRAME(36, 3),
+ ANIMCMD_FRAME(40, 3),
+ ANIMCMD_FRAME(44, 3),
+ ANIMCMD_LOOP(2),
+ ANIMCMD_FRAME( 0, 3),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_8338C88[] =
+{
+ gSpriteAnim_8338C4C,
+ gSpriteAnim_8338C88
+};
+
+static const union AffineAnimCmd gSpriteAffineAnim_8338CCC[] =
+{
+ AFFINEANIMCMD_FRAME(0, 0, 0, 1),
+ AFFINEANIMCMD_END
+};
+
+static const union AffineAnimCmd gSpriteAffineAnim_8338CDC[] =
+{
+ AFFINEANIMCMD_FRAME(-8, 0, 0, 20),
+ AFFINEANIMCMD_END
+};
+
+static const union AffineAnimCmd gSpriteAffineAnim_8338CEC[] =
+{
+ AFFINEANIMCMD_FRAME(0x60, 0x100, 0, 0),
+ AFFINEANIMCMD_FRAME( 0, 0, 0, 5),
+ AFFINEANIMCMD_FRAME( 8, 0, 0, 20),
+ AFFINEANIMCMD_END
+};
+
+static const union AffineAnimCmd *const gSpriteAffineAnimTable_8338D0C[] =
+{
+ gSpriteAffineAnim_8338CCC,
+ gSpriteAffineAnim_8338CDC,
+ gSpriteAffineAnim_8338CEC
+};
+
+static const struct SpriteSheet sPokeBallSpriteSheet =
+{
+ .data = sTradeGfx_PokeBall,
+ .size = 0x600,
+ .tag = 5557
+};
+
+static const struct SpritePalette sPokeBallSpritePalette =
+{
+ .data = sTradePal_PokeBall,
+ .tag = 5558
+};
+
+static const struct SpriteTemplate gSpriteTemplate_8338D28 =
+{
+ .tileTag = 5557,
+ .paletteTag = 5558,
+ .oam = &sTradeOamData_16x16,
+ .anims = gSpriteAnimTable_8338C88,
+ .images = NULL,
+ .affineAnims = gSpriteAffineAnimTable_8338D0C,
+ .callback = sub_807E55C
+};
+
+static const struct OamData sTradeOamData_32x32 =
+{
+ .affineMode = 1,
+ .objMode = 1,
+ .shape = SPRITE_SHAPE(32x32),
+ .size = SPRITE_SIZE(32x32),
+ .priority = 1
+};
+
+static const union AnimCmd gSpriteAnim_8338D48[] =
+{
+ ANIMCMD_FRAME(0, 5, .hFlip = TRUE, .vFlip = TRUE),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_8338D50[] =
+{
+ gSpriteAnim_8338D48
+};
+
+static const union AffineAnimCmd gSpriteAffineAnim_8338D54[] =
+{
+ AFFINEANIMCMD_FRAME(-10, -10, 0, 5),
+ AFFINEANIMCMD_FRAME(10, 10, 0, 5),
+ AFFINEANIMCMD_JUMP(0)
+};
+
+static const union AffineAnimCmd *const gSpriteAffineAnimTable_8338D6C[] =
+{
+ gSpriteAffineAnim_8338D54
+};
+
+static const struct SpriteSheet sGlow1SpriteSheet =
+{
+ .data = sTradeGfx_Glow1,
+ .size = 0x200,
+ .tag = 5550
+};
+
+static const struct SpritePalette sMiscTradeSpritePalette =
+{
+ .data = sTradePal_Misc,
+ .tag = 5551
+};
+
+static const struct SpritePalette sGbaSpritePalette =
+{
+ .data = sTradePal_Gba,
+ .tag = 5555
+};
+
+static const struct SpriteTemplate gUnknown_08338D88 =
+{
+ .tileTag = 5550,
+ .paletteTag = 5551,
+ .oam = &sTradeOamData_32x32,
+ .anims = gSpriteAnimTable_8338D50,
+ .images = NULL,
+ .affineAnims = gSpriteAffineAnimTable_8338D6C,
+ .callback = sub_807AA28
+};
+
+static const struct OamData sTradeOamData_16x32 =
+{
+ .shape = SPRITE_SHAPE(16x32),
+ .size = SPRITE_SIZE(16x32),
+ .priority = 1
+};
+
+static const union AnimCmd gSpriteAnim_8338DA8[] =
+{
+ ANIMCMD_FRAME(0, 5, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_8338DB0[] =
+{
+ ANIMCMD_FRAME(8, 5, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_8338DB8[] =
+{
+ gSpriteAnim_8338DA8,
+ gSpriteAnim_8338DB0
+};
+
+static const struct SpriteSheet sGlow2SpriteSheet =
+{
+ .data = sTradeGfx_Glow2,
+ .size = 0x300,
+ .tag = 5552
+};
+
+static const struct SpriteTemplate sGlowBallSpriteTemplate =
+{
+ .tileTag = 5552,
+ .paletteTag = 5551,
+ .oam = &sTradeOamData_16x32,
+ .anims = gSpriteAnimTable_8338DB8,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_807AA7C
+};
+
+static const struct OamData sTradeOamData_16x32_2 =
+{
+ .shape = SPRITE_SHAPE(16x32),
+ .size = SPRITE_SIZE(16x32),
+ .priority = 1
+};
+
+static const union AnimCmd gSpriteAnim_8338DE8[] =
+{
+ ANIMCMD_FRAME(0, 10),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_8338DF0[] =
+{
+ gSpriteAnim_8338DE8
+};
+
+static const struct SpriteSheet sCableEndSpriteSheet =
+{
+ .data = sTradeGfx_CableEnd,
+ .size = 0x100,
+ .tag = 5554
+};
+
+static const struct SpriteTemplate gSpriteTemplate_8338DFC =
+{
+ .tileTag = 5554,
+ .paletteTag = 5555,
+ .oam = &sTradeOamData_16x32_2,
+ .anims = gSpriteAnimTable_8338DF0,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_807AABC
+};
+
+static const struct OamData sTradeOamData_64x32_2 =
+{
+ .shape = SPRITE_SHAPE(64x32),
+ .size = SPRITE_SIZE(64x32),
+ .priority = 1
+};
+
+static const union AnimCmd gSpriteAnim_8338E1C[] =
+{
+ ANIMCMD_FRAME( 0, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(32, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(64, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(96, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(64, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(32, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME( 0, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_LOOP(8),
+ ANIMCMD_END
+};
+
+static const union AnimCmd gSpriteAnim_8338E40[] =
+{
+ ANIMCMD_FRAME( 0, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(32, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(64, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(96, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(64, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME(32, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_FRAME( 0, 2, .vFlip = TRUE, .hFlip = TRUE),
+ ANIMCMD_LOOP(2),
+ ANIMCMD_END
+};
+
+static const union AnimCmd *const gSpriteAnimTable_8338E64[] =
+{
+ gSpriteAnim_8338E1C
+};
+
+static const union AnimCmd *const gSpriteAnimTable_8338E68[] =
+{
+ gSpriteAnim_8338E40
+};
+
+static const struct SpriteSheet sGbaScreenSpriteSheet =
+{
+ .data = sTradeGfx_GbaScreen,
+ .size = 0x1000,
+ .tag = 5556
+};
+
+static const struct SpriteTemplate gSpriteTemplate_8338E74 =
+{
+ .tileTag = 5556,
+ .paletteTag = 5555,
+ .oam = &sTradeOamData_64x32_2,
+ .anims = gSpriteAnimTable_8338E64,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_807AB04
+};
+
+static const struct SpriteTemplate gSpriteTemplate_8338E8C =
+{
+ .tileTag = 5556,
+ .paletteTag = 5555,
+ .oam = &sTradeOamData_64x32_2,
+ .anims = gSpriteAnimTable_8338E68,
+ .images = NULL,
+ .affineAnims = gDummySpriteAffineAnimTable,
+ .callback = sub_807AB04
+};
+
+static const u16 gUnknown_08338EA4[] = INCBIN_U16("graphics/trade/unknown_338EA4.gbapal");
+
+static const union AffineAnimCmd gSpriteAffineAnim_8338EBC[] =
+{
+ AFFINEANIMCMD_FRAME(-0x100, 0x100, 0, 0),
+ AFFINEANIMCMD_JUMP(0)
+};
+
+static const union AffineAnimCmd *const gSpriteAffineAnimTable_8338ECC[] =
+{
+ gSpriteAffineAnim_8338EBC
+};
+
+static const struct InGameTrade sIngameTrades[] =
+{
+ [INGAME_TRADE_SEEDOT] =
+ {
+ .nickname = _("DOTS"),
+ .species = SPECIES_SEEDOT,
+ .ivs = {5, 4, 5, 4, 4, 4},
+ .abilityNum = 1,
+ .otId = 38726,
+ .conditions = {30, 5, 5, 5, 5},
+ .personality = 0x84,
+ .heldItem = ITEM_CHESTO_BERRY,
+ .mailNum = -1,
+ .otName = _("KOBE"),
+ .otGender = MALE,
+ .sheen = 10,
+ .requestedSpecies = SPECIES_RALTS
+ },
+ [INGAME_TRADE_PLUSLE] =
+ {
+ .nickname = _("PLUSES"),
+ .species = SPECIES_PLUSLE,
+ .ivs = {4, 4, 4, 5, 5, 4},
+ .abilityNum = 0,
+ .otId = 73996,
+ .conditions = {5, 5, 30, 5, 5},
+ .personality = 0x6F,
+ .heldItem = ITEM_WOOD_MAIL,
+ .mailNum = 0,
+ .otName = _("ROMAN"),
+ .otGender = MALE,
+ .sheen = 10,
+ .requestedSpecies = SPECIES_VOLBEAT
+ },
+ [INGAME_TRADE_HORSEA] =
+ {
+ .nickname = _("SEASOR"),
+ .species = SPECIES_HORSEA,
+ .ivs = {5, 4, 4, 4, 5, 4},
+ .abilityNum = 0,
+ .otId = 46285,
+ .conditions = {5, 5, 5, 5, 30},
+ .personality = 0x7F,
+ .heldItem = ITEM_WAVE_MAIL,
+ .mailNum = 1,
+ .otName = _("SKYLAR"),
+ .otGender = MALE,
+ .sheen = 10,
+ .requestedSpecies = SPECIES_BAGON
+ },
+ [INGAME_TRADE_MEOWTH] =
+ {
+ .nickname = _("MEOWOW"),
+ .species = SPECIES_MEOWTH,
+ .ivs = {4, 5, 4, 5, 4, 4},
+ .abilityNum = 0,
+ .otId = 91481,
+ .conditions = {5, 5, 5, 30, 5},
+ .personality = 0x8B,
+ .heldItem = ITEM_RETRO_MAIL,
+ .mailNum = 2,
+ .otName = _("ISIS"),
+ .otGender = FEMALE,
+ .sheen = 10,
+ .requestedSpecies = SPECIES_SKITTY
+ }
+};
+
+static const u16 sIngameTradeMail[][MAIL_WORDS_COUNT + 1] =
+{
+ {
+ EC_WORD_BE,
+ EC_WORD_NICE,
+ EC_WORD_TO,
+ EC_POKEMON(PLUSLE),
+ EC_WORD_EXCL,
+ EC_POKEMON(VOLBEAT),
+ EC_WORD_WILL,
+ EC_WORD_BE,
+ EC_WORD_FANTASTIC
+ }, {
+ EC_WORD_I,
+ EC_WORD_WILL,
+ EC_WORD_MAKE,
+ EC_POKEMON(BAGON),
+ EC_WORD_TOUGH,
+ EC_WORD_PLEASE,
+ EC_WORD_TRAIN,
+ EC_POKEMON(HORSEA),
+ EC_WORD_WELL
+ }, {
+ EC_WORD_THANK_YOU,
+ EC_WORD_FOR,
+ EC_POKEMON(SKITTY),
+ EC_POKEMON2(MEOWTH),
+ EC_WORD_CRIES,
+ EC_WORD_IN,
+ EC_WORD_A,
+ EC_WORD_CUTE,
+ EC_WORD_WAY
+ }
+};
+
+static const struct WindowTemplate sTradeSequenceWindowTemplates[] =
+{
+ {
+ .bg = 0,
+ .tilemapLeft = 2,
+ .tilemapTop = 15,
+ .width = 26,
+ .height = 4,
+ .paletteNum = 0,
+ .baseBlock = 64
+ },
+ DUMMY_WIN_TEMPLATE
+};
+
+const struct WindowTemplate gTradeEvolutionSceneYesNoWindowTemplate =
+{
+ .bg = 0,
+ .tilemapLeft = 21,
+ .tilemapTop = 9,
+ .width = 5,
+ .height = 4,
+ .paletteNum = 15,
+ .baseBlock = 188
+};
+
+static const struct BgTemplate sTradeSequenceBgTemplates[] =
+{
+ {
+ .bg = 0,
+ .charBaseIndex = 3,
+ .mapBaseIndex = 31,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 0,
+ .baseTile = 0
+ },
+ {
+ .bg = 1,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 5,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 2,
+ .baseTile = 0
+ },
+ {
+ .bg = 2,
+ .charBaseIndex = 1,
+ .mapBaseIndex = 18,
+ .screenSize = 1,
+ .paletteMode = 0,
+ .priority = 2,
+ .baseTile = 0
+ },
+ {
+ .bg = 3,
+ .charBaseIndex = 0,
+ .mapBaseIndex = 6,
+ .screenSize = 0,
+ .paletteMode = 0,
+ .priority = 3,
+ .baseTile = 0
+ },
+};
+
+static const s8 sTradeBallVerticalVelocityTable[] =
+{
+ 0, 0, 1, 0,
+ 1, 0, 1, 1,
+ 1, 1, 2, 2,
+ 2, 2, 3, 3,
+ 3, 3, 4, 4,
+ 4, 4, -4, -4,
+ -4, -3, -3, -3,
+ -3, -2, -2, -2,
+ -2, -1, -1, -1,
+ -1, 0, -1, 0,
+ -1, 0, 0, 0,
+ 0, 0, 1, 0,
+ 1, 0, 1, 1,
+ 1, 1, 2, 2,
+ 2, 2, 3, 3,
+ 3, 3, 4, 4,
+ 4, 4, -4, -3,
+ -3, -2, -2, -1,
+ -1, -1, 0, -1,
+ 0, 0, 0, 0,
+ 0, 0, 1, 0,
+ 1, 1, 1, 2,
+ 2, 3, 3, 4,
+ -4, -3, -2, -1,
+ -1, -1, 0, 0,
+ 0, 0, 1, 0,
+ 1, 1, 2, 3
+};
+
+static const u8 sWirelessSignalTiming[][2] =
+{
+ {0, 1},
+ {1, 1},
+ {2, 1},
+ {3, 1},
+ {4, 1},
+ {5, 2},
+ {6, 2},
+ {7, 2},
+ {8, 2},
+ {9, 2},
+ {10, 3},
+ {11, 3},
+ {12, 3},
+ {13, 4},
+ {14, 5},
+ {15, 2},
+ {0, 1},
+ {1, 1},
+ {2, 1},
+ {3, 1},
+ {4, 1},
+ {5, 2},
+ {6, 2},
+ {7, 2},
+ {8, 2},
+ {9, 2},
+ {10, 3},
+ {11, 3},
+ {12, 3},
+ {13, 4},
+ {14, 5},
+ {16, 1},
+ {16, 255},
+ {0, 0}
+};
diff --git a/src/data/union_room.h b/src/data/union_room.h
new file mode 100644
index 000000000..abe91b010
--- /dev/null
+++ b/src/data/union_room.h
@@ -0,0 +1,1044 @@
+// const rom data
+
+ALIGNED(4) const u8 gText_EmptyString[] = _("");
+ALIGNED(4) const u8 gText_Colon[] = _(":");
+ALIGNED(4) const u8 gText_UnkCtrlCodeF907[] = _("{ID}");
+ALIGNED(4) const u8 gText_PleaseStartOver[] = _("Please start over from the beginning.");
+ALIGNED(4) const u8 gText_WirelessSearchCanceled[] = _("The WIRELESS COMMUNICATION\nSYSTEM search has been canceled.");
+ALIGNED(4) const u8 unref_text_union_room_0[] = _("Awaiting communication\nfrom another player.");
+ALIGNED(4) const u8 gText_AwaitingCommunication[] = _("{STR_VAR_1}! Awaiting\ncommunication from another player.");
+ALIGNED(4) const u8 gText_AwaitingLink[] = _("{STR_VAR_1}! Awaiting link!\nPress START when everyone's ready.");
+ALIGNED(4) const u8 gJPText_SingleBattle[] = _("シングルバトルを かいさいする");
+ALIGNED(4) const u8 gJPText_DoubleBattle[] = _("ダブルバトルを かいさいする");
+ALIGNED(4) const u8 gJPText_MultiBattle[] = _("マルチバトルを かいさいする");
+ALIGNED(4) const u8 gJPText_TradePokemon[] = _("ポケモンこうかんを かいさいする");
+ALIGNED(4) const u8 gJPText_Chat[] = _("チャットを かいさいする");
+ALIGNED(4) const u8 gJPText_DistWonderCard[] = _("ふしぎなカードをくばる");
+ALIGNED(4) const u8 gJPText_DistWonderNews[] = _("ふしぎなニュースをくばる");
+ALIGNED(4) const u8 unref_text_union_room_1[] = _("ふしぎなできごとを かいさいする");
+ALIGNED(4) const u8 gJPText_HoldPokemonJump[] = _("なわとびを かいさいする");
+ALIGNED(4) const u8 gJPText_HoldBerryCrush[] = _("きのみマッシャーを かいさいする");
+ALIGNED(4) const u8 gJPText_HoldBerryPicking[] = _("きのみどりを かいさいする");
+ALIGNED(4) const u8 gJPText_HoldSpinTrade[] = _("ぐるぐるこうかんを かいさいする");
+ALIGNED(4) const u8 gJPText_HoldSpinShop[] = _("ぐるぐるショップを かいさいする");
+
+const u8 *const unref_text_ptrs_union_room_0[] = {
+ gJPText_SingleBattle,
+ gJPText_DoubleBattle,
+ gJPText_MultiBattle,
+ gJPText_TradePokemon,
+ gJPText_Chat,
+ gJPText_DistWonderCard,
+ gJPText_DistWonderNews,
+ gJPText_DistWonderCard,
+ gJPText_HoldPokemonJump,
+ gJPText_HoldBerryCrush,
+ gJPText_HoldBerryPicking,
+ gJPText_HoldBerryPicking,
+ gJPText_HoldSpinTrade,
+ gJPText_HoldSpinShop
+};
+
+const u8 gText_1PlayerNeeded[] = _("1 player\nneeded.");
+const u8 gText_2PlayersNeeded[] = _("2 players\nneeded.");
+const u8 gText_3PlayersNeeded[] = _("3 players\nneeded.");
+const u8 gText_4PlayersNeeded[] = _("4 players\nneeded.");
+const u8 gText_2PlayerMode[] = _("2-PLAYER\nMODE");
+const u8 gText_3PlayerMode[] = _("3-PLAYER\nMODE");
+const u8 gText_4PlayerMode[] = _("4-PLAYER\nMODE");
+const u8 gText_5PlayerMode[] = _("5-PLAYER\nMODE");
+
+const u8 *const gUnknown_082EDB60[][5] = {
+ {
+ gText_1PlayerNeeded,
+ gText_2PlayerMode
+ }, {
+ gText_3PlayersNeeded,
+ gText_2PlayersNeeded,
+ gText_1PlayerNeeded,
+ gText_4PlayerMode
+ }, {
+ gText_1PlayerNeeded,
+ gText_2PlayerMode,
+ gText_3PlayerMode,
+ gText_4PlayerMode,
+ gText_5PlayerMode
+ }, {
+ gText_2PlayersNeeded,
+ gText_1PlayerNeeded,
+ gText_3PlayerMode,
+ gText_4PlayerMode,
+ gText_5PlayerMode
+ }, {
+ gText_1PlayerNeeded,
+ gText_2PlayerMode,
+ gText_3PlayerMode,
+ gText_4PlayerMode
+ }
+};
+
+ALIGNED(4) const u8 gUnknown_082EDBC4[] = _("{B_BUTTON}CANCEL");
+ALIGNED(4) const u8 unref_text_union_room_2[] = _("ため\nさんかしゃ ぼしゅうちゅう です!");
+ALIGNED(4) const u8 gUnknown_082EDBE8[] = _("{STR_VAR_2} contacted you for\n{STR_VAR_1}. Accept?");
+ALIGNED(4) const u8 gUnknown_082EDC0C[] = _("{STR_VAR_2} contacted you.\nWill you share {STR_VAR_1}?");
+ALIGNED(4) const u8 gUnknown_082EDC34[] = _("{STR_VAR_2} contacted you.\nAdd to the members?");
+ALIGNED(4) const u8 gUnknown_082EDC5C[] = _("{STR_VAR_1}!\nAre these members OK?");
+ALIGNED(4) const u8 gUnknown_082EDC78[] = _("Cancel {STR_VAR_1} MODE\nwith these members?");
+ALIGNED(4) const u8 gUnknown_082EDC9C[] = _("An “OK” was sent\nto {STR_VAR_1}.");
+ALIGNED(4) const u8 gUnknown_082EDCB4[] = _("The other TRAINER doesn't appear\nto be available now…\p");
+ALIGNED(4) const u8 gUnknown_082EDCEC[] = _("You can't transmit with a TRAINER\nwho is too far away.\p");
+ALIGNED(4) const u8 gUnknown_082EDD24[] = _("The other TRAINER(S) is/are not\nready yet.\p");
+
+const u8 *const gUnknown_082EDD50[] = {
+ gUnknown_082EDCEC,
+ gUnknown_082EDD24
+};
+
+ALIGNED(4) const u8 gUnknown_082EDD58[] = _("The {STR_VAR_1} MODE with\nthese members will be canceled.{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EDD8C[] = _("There is a member who can no\nlonger remain available.\p");
+
+const u8 *const gUnknown_082EDDC4[] = {
+ gUnknown_082EDCB4,
+ gUnknown_082EDD8C
+};
+
+ALIGNED(4) const u8 gUnknown_082EDDCC[] = _("The other TRAINER appears\nunavailable…\p");
+ALIGNED(4) const u8 gUnknown_082EDDF4[] = _("{STR_VAR_1} sent back an “OK”!");
+ALIGNED(4) const u8 gUnknown_082EDE0C[] = _("{STR_VAR_1} OK'd your registration as\na member.");
+ALIGNED(4) const u8 gUnknown_082EDE34[] = _("{STR_VAR_1} replied, “No…”\p");
+ALIGNED(4) const u8 gUnknown_082EDE48[] = _("{STR_VAR_1}!\nAwaiting other members!");
+ALIGNED(4) const u8 gUnknown_082EDE64[] = _("Quit being a member?");
+ALIGNED(4) const u8 gUnknown_082EDE7C[] = _("You stopped being a member.\p");
+
+const u8 *const gUnknown_082EDE9C[] = {
+ NULL,
+ gUnknown_082EDD8C,
+ gUnknown_082EDDCC,
+ NULL,
+ NULL,
+ NULL,
+ gUnknown_082EDE34,
+ NULL,
+ NULL,
+ gUnknown_082EDE7C
+};
+
+ALIGNED(4) const u8 gUnknown_082EDEC4[] = _("The WIRELESS COMMUNICATION\nSYSTEM link has been established.");
+ALIGNED(4) const u8 gUnknown_082EDF04[] = _("The WIRELESS COMMUNICATION\nSYSTEM link has been dropped…");
+ALIGNED(4) const u8 gUnknown_082EDF40[] = _("The link with your friend has been\ndropped…");
+ALIGNED(4) const u8 gUnknown_082EDF6C[] = _("{STR_VAR_1} replied, “No…”");
+
+const u8 *const gUnknown_082EDF80[] = {
+ NULL,
+ gUnknown_082EDF40,
+ gUnknown_082EDF40,
+ NULL,
+ NULL,
+ NULL,
+ gUnknown_082EDF6C,
+ NULL,
+ NULL,
+ NULL
+};
+
+ALIGNED(4) const u8 gUnknown_082EDFA8[] = _("Do you want the {STR_VAR_2}\nMODE?");
+ALIGNED(4) const u8 gUnknown_082EDFC4[] = _("Do you want the {STR_VAR_2}\nMODE?");
+
+const u8 *const unref_text_ptrs_union_room_1[] = {
+ gUnknown_082EDFA8,
+ gUnknown_082EDFC4
+};
+
+ALIGNED(4) const u8 unref_text_union_room_3[] = _("Communicating…\nPlease wait.");
+ALIGNED(4) const u8 gUnknown_082EE004[] = _("Awaiting {STR_VAR_1}'s response about\nthe trade…");
+ALIGNED(4) const u8 gUnknown_082EE02C[] = _("Communicating{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.\n{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.");
+ALIGNED(4) const u8 gUnknown_082EE098[] = _("Communicating with {STR_VAR_1}{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.\n{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.");
+ALIGNED(4) const u8 gUnknown_082EE104[] = _("Please wait a while{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.\n{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.{PAUSE 15}.");
+
+const u8 *const gUnknown_082EE17C[] = {
+ gUnknown_082EE02C,
+ gUnknown_082EE098,
+ gUnknown_082EE104
+};
+
+ALIGNED(4) const u8 gUnknown_082EE188[] = _("Hiya! Is there something that you\nwanted to do?");
+ALIGNED(4) const u8 gUnknown_082EE1B8[] = _("Hello!\nWould you like to do something?");
+ALIGNED(4) const u8 gUnknown_082EE1E0[] = _("{STR_VAR_1}: Hiya, we meet again!\nWhat are you up for this time?");
+ALIGNED(4) const u8 gUnknown_082EE218[] = _("{STR_VAR_1}: Oh! {PLAYER}, hello!\nWould you like to do something?");
+
+const u8 *const gUnknown_082EE24C[][2] = {
+ {
+ gUnknown_082EE188,
+ gUnknown_082EE1B8
+ }, {
+ gUnknown_082EE1E0,
+ gUnknown_082EE218
+ }
+};
+
+ALIGNED(4) const u8 gUnknown_082EE25C[] = _("Want to do something?");
+ALIGNED(4) const u8 gUnknown_082EE274[] = _("Would you like to do something?");
+ALIGNED(4) const u8 gUnknown_082EE294[] = _("{STR_VAR_1}: What would you like to\ndo now?");
+ALIGNED(4) const u8 unref_text_union_room_4[] = _("{STR_VAR_1}: Want to do anything else?");
+
+const u8 *const unref_text_ptrs_union_room_2[][2] = {
+ {
+ gUnknown_082EE25C,
+ gUnknown_082EE274
+ }, {
+ gUnknown_082EE294,
+ gUnknown_082EE294
+ }
+};
+
+ALIGNED(4) const u8 sText_SomebodyHasContactedYou[] = _("Somebody has contacted you.{PAUSE 60}");
+ALIGNED(4) const u8 sText_XHasContactedYou[] = _("{STR_VAR_1} has contacted you.{PAUSE 60}");
+
+static const u8 *const gUnknown_082EE324[] = {
+ sText_SomebodyHasContactedYou,
+ sText_XHasContactedYou
+};
+
+ALIGNED(4) const u8 sUnionRoom_AwaitingResponseFromTrainer[] = _("Awaiting a response from\nthe other TRAINER…");
+ALIGNED(4) const u8 sUnionRoom_AwaitingResponseFromX[] = _("Awaiting a response from\n{STR_VAR_1}…");
+
+static const u8 *const sUnionRoomTexts_AwaitingResponse[] = {
+ sUnionRoom_AwaitingResponseFromTrainer,
+ sUnionRoom_AwaitingResponseFromX
+};
+
+ALIGNED(4) const u8 sText_ShowTrainerCard[] = _("The other TRAINER showed\nyou their TRAINER CARD.\pWould you like to show your\nTRAINER CARD?");
+ALIGNED(4) const u8 sText_BattleChallenge[] = _("The other TRAINER challenges you\nto battle.\pWill you accept the battle\nchallenge?");
+ALIGNED(4) const u8 sText_ChatInvitation[] = _("The other TRAINER invites you\nto chat.\pWill you accept the chat\ninvitation?");
+ALIGNED(4) const u8 sText_OfferToTradeMon[] = _("There is an offer to trade your\nregistered Lv. {SPECIAL_F7 0x00} {SPECIAL_F7 0x01}\pin exchange for a\nLv. {SPECIAL_F7 0x02} {SPECIAL_F7 0x03}.\pWill you accept this trade\noffer?");
+ALIGNED(4) const u8 sText_OfferToTradeEgg[] = _("There is an offer to trade your\nregistered EGG.\lWill you accept this trade offer?");
+ALIGNED(4) const u8 sText_ChatDropped[] = _("The chat has been dropped.\p");
+ALIGNED(4) const u8 sText_OfferDeclined1[] = _("You declined the offer.\p");
+ALIGNED(4) const u8 sText_OfferDeclined2[] = _("You declined the offer.\p");
+ALIGNED(4) const u8 sText_ChatEnded[] = _("The chat was ended.\p");
+
+// Unused
+static const u8 *const sUnionRoomTexts_Invitation[] = {
+ sText_ShowTrainerCard,
+ sText_BattleChallenge,
+ sText_ChatInvitation,
+ sText_OfferToTradeMon
+};
+
+ALIGNED(4) const u8 sText_JoinChatMale[] = _("Oh, hey! We're in a chat right now.\nWant to join us?");
+ALIGNED(4) const u8 sText_PlayerJoinChatMale[] = _("{STR_VAR_1}: Hey, {PLAYER}!\nWe're having a chat right now.\lWant to join us?");
+ALIGNED(4) const u8 sText_JoinChatFemale[] = _("Oh, hi! We're having a chat now.\nWould you like to join us?");
+ALIGNED(4) const u8 sText_PlayerJoinChatFemale[] = _("{STR_VAR_1}: Oh, hi, {PLAYER}!\nWe're having a chat now.\lWould you like to join us?");
+
+const u8 *const sUnionRoomTexts_JoinChat[][GENDER_COUNT] = {
+ {
+ sText_JoinChatMale,
+ sText_JoinChatFemale
+ }, {
+ sText_PlayerJoinChatMale,
+ sText_PlayerJoinChatFemale
+ }
+};
+
+ALIGNED(4) const u8 sText_TrainerAppearsBusy[] = _("……\nThe TRAINER appears to be busy…\p");
+ALIGNED(4) const u8 gUnknown_082EE6EC[] = _("A battle, huh?\nAll right, just give me some time.");
+ALIGNED(4) const u8 gUnknown_082EE720[] = _("You want to chat, huh?\nSure, just wait a little.");
+ALIGNED(4) const u8 gUnknown_082EE754[] = _("Sure thing! As my “Greetings,”\nhere's my TRAINER CARD.");
+ALIGNED(4) const u8 gUnknown_082EE78C[] = _("A battle? Of course, but I need\ntime to get ready.");
+ALIGNED(4) const u8 gUnknown_082EE7C0[] = _("Did you want to chat?\nOkay, but please wait a moment.");
+ALIGNED(4) const u8 gUnknown_082EE7F8[] = _("As my introduction, I'll show you\nmy TRAINER CARD.");
+
+const u8 *const gUnknown_082EE82C[][4] = {
+ {
+ gUnknown_082EE6EC,
+ gUnknown_082EE720,
+ NULL,
+ gUnknown_082EE754
+ }, {
+ gUnknown_082EE78C,
+ gUnknown_082EE7C0,
+ NULL,
+ gUnknown_082EE7F8
+ }
+};
+
+ALIGNED(4) const u8 unref_text_union_room_5[] = _("You want to chat, huh?\nSure, just wait a little.");
+ALIGNED(4) const u8 gUnknown_082EE880[] = _("Thanks for waiting!\nLet's get our battle started!{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EE8B8[] = _("All right!\nLet's chat!{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EE8D4[] = _("Sorry I made you wait!\nLet's get started!{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EE904[] = _("Sorry I made you wait!\nLet's chat.{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EE92C[] = _("The trade will be started.{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EE94C[] = _("The battle will be started.{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EE96C[] = _("Entering the chat…{PAUSE 60}");
+
+const u8 *const gUnknown_082EE984[][2][3] = {
+ {
+ {
+ gUnknown_082EE94C,
+ gUnknown_082EE96C,
+ gUnknown_082EE92C
+ }, {
+ gUnknown_082EE94C,
+ gUnknown_082EE96C,
+ gUnknown_082EE92C
+ }
+ }, {
+ {
+ gUnknown_082EE880,
+ gUnknown_082EE8B8,
+ gUnknown_082EE92C
+ }, {
+ gUnknown_082EE8D4,
+ gUnknown_082EE904,
+ gUnknown_082EE92C
+ }
+ }
+};
+
+ALIGNED(4) const u8 gUnknown_082EE9B4[] = _("Sorry! My POKéMON don't seem to\nbe feeling too well right now.\lLet me battle you another time.\p");
+ALIGNED(4) const u8 gUnknown_082EEA14[] = _("I'm terribly sorry, but my POKéMON\naren't feeling well…\pLet's battle another time.\p");
+
+const u8 *const gUnknown_082EEA68[] = {
+ gUnknown_082EE9B4,
+ gUnknown_082EEA14
+};
+
+ALIGNED(4) const u8 gUnknown_082EEA70[] = _("Huh? My TRAINER CARD…\nWhere'd it go now?\lSorry! I'll show you another time!\p");
+ALIGNED(4) const u8 gUnknown_082EEAC0[] = _("Oh? Now where did I put my\nTRAINER CARD?…\lSorry! I'll show you later!\p");
+
+const u8 *const gUnknown_082EEB08[] = {
+ gUnknown_082EEA70,
+ gUnknown_082EEAC0
+};
+
+ALIGNED(4) const u8 gUnknown_082EEB10[] = _("If you want to do something with\nme, just give me a shout!\p");
+ALIGNED(4) const u8 gUnknown_082EEB4C[] = _("If you want to do something with\nme, don't be shy.\p");
+
+const u8 *const gUnknown_082EEB80[] = {
+ gUnknown_082EEB10,
+ gUnknown_082EEB4C
+};
+
+ALIGNED(4) const u8 sText_TrainerBattleBusy[] = _("Whoops! Sorry, but I have to do\nsomething else.\lAnother time, okay?\p");
+ALIGNED(4) const u8 sText_NeedTwoMonsOfLevel30OrLower1[] = _("If you want to battle, you need\ntwo POKéMON that are below\lLv. 30.\p");
+ALIGNED(4) const u8 sText_NeedTwoMonsOfLevel30OrLower2[] = _("For a battle, you need two\nPOKéMON that are below Lv. 30.\p");
+ALIGNED(4) const u8 sText_DeclineBattleMale[] = _("Oh, all right.\nCome see me anytime, okay?\p");
+ALIGNED(4) const u8 sText_DeclineBattleFemale[] = _("Oh…\nPlease come by anytime.\p");
+
+const u8 *const sUnionRoomTexts_DeclineBattle[GENDER_COUNT] = {
+ [MALE] = sText_DeclineBattleMale,
+ [FEMALE] = sText_DeclineBattleFemale
+};
+
+ALIGNED(4) const u8 gUnknown_082EECA4[] = _("Oh, sorry!\nI just can't right this instant.\lLet's chat another time.\p");
+ALIGNED(4) const u8 gUnknown_082EECEC[] = _("Oh, I'm sorry.\nI have too much to do right now.\lLet's chat some other time.\p");
+
+const u8 *const gUnknown_082EED3C[] = {
+ gUnknown_082EECA4,
+ gUnknown_082EECEC
+};
+
+ALIGNED(4) const u8 gUnknown_082EED44[] = _("Whoa!\nI can tell you're pretty tough!\p");
+ALIGNED(4) const u8 gUnknown_082EED6C[] = _("You used that move?\nThat's good strategy!\p");
+ALIGNED(4) const u8 gUnknown_082EED98[] = _("Way to go!\nThat was an eye-opener!\p");
+ALIGNED(4) const u8 gUnknown_082EEDBC[] = _("Oh! How could you use that\nPOKéMON in that situation?\p");
+ALIGNED(4) const u8 gUnknown_082EEDF4[] = _("That POKéMON…\nIt's been raised really well!\p");
+ALIGNED(4) const u8 gUnknown_082EEE24[] = _("That's it!\nThis is the right move now!\p");
+ALIGNED(4) const u8 gUnknown_082EEE4C[] = _("That's awesome!\nYou can battle that way?\p");
+ALIGNED(4) const u8 gUnknown_082EEE78[] = _("You have exquisite timing for\nswitching POKéMON!\p");
+
+const u8 *const gUnknown_082EEEAC[GENDER_COUNT][4] = {
+ [MALE] =
+ {
+ gUnknown_082EED44,
+ gUnknown_082EED6C,
+ gUnknown_082EED98,
+ gUnknown_082EEDBC
+ },
+ [FEMALE] =
+ {
+ gUnknown_082EEDF4,
+ gUnknown_082EEE24,
+ gUnknown_082EEE4C,
+ gUnknown_082EEE78
+ }
+};
+
+ALIGNED(4) const u8 gUnknown_082EEECC[] = _("Oh, I see!\nThis is educational!\p");
+ALIGNED(4) const u8 gUnknown_082EEEF0[] = _("Don't say anything funny anymore!\nI'm sore from laughing!\p");
+ALIGNED(4) const u8 gUnknown_082EEF2C[] = _("Oh?\nSomething like that happened.\p");
+ALIGNED(4) const u8 gUnknown_082EEF50[] = _("Hmhm… What?\nSo is this what you're saying?\p");
+ALIGNED(4) const u8 gUnknown_082EEF7C[] = _("Is that right?\nI didn't know that.\p");
+ALIGNED(4) const u8 gUnknown_082EEFA0[] = _("Ahaha!\nWhat is that about?\p");
+ALIGNED(4) const u8 gUnknown_082EEFBC[] = _("Yes, that's exactly it!\nThat's what I meant.\p");
+ALIGNED(4) const u8 gUnknown_082EEFEC[] = _("In other words…\nYes! That's right!\p");
+
+const u8 *const gUnknown_082EF010[GENDER_COUNT][4] = {
+ [MALE] =
+ {
+ gUnknown_082EEECC,
+ gUnknown_082EEEF0,
+ gUnknown_082EEF2C,
+ gUnknown_082EEF50
+ },
+ [FEMALE] =
+ {
+ gUnknown_082EEF7C,
+ gUnknown_082EEFA0,
+ gUnknown_082EEFBC,
+ gUnknown_082EEFEC
+ }
+};
+
+ALIGNED(4) const u8 gUnknown_082EF030[] = _("I'm just showing my TRAINER CARD\nas my way of greeting.\p");
+ALIGNED(4) const u8 gUnknown_082EF06C[] = _("I hope I get to know you better!\p");
+ALIGNED(4) const u8 gUnknown_082EF090[] = _("We're showing each other our\nTRAINER CARDS to get acquainted.\p");
+ALIGNED(4) const u8 gUnknown_082EF0D0[] = _("Glad to meet you.\nPlease don't be a stranger!\p");
+
+const u8 *const gUnknown_082EF100[GENDER_COUNT][2] = {
+ [MALE] =
+ {
+ gUnknown_082EF030,
+ gUnknown_082EF06C
+ },
+ [FEMALE] =
+ {
+ gUnknown_082EF090,
+ gUnknown_082EF0D0
+ }
+};
+
+ALIGNED(4) const u8 sText_MaleTraded1[] = _("Yeahah!\nI really wanted this POKéMON!\p");
+ALIGNED(4) const u8 sText_MaleTraded2[] = _("Finally, a trade got me that\nPOKéMON I'd wanted a long time.\p");
+ALIGNED(4) const u8 sText_FemaleTraded1[] = _("I'm trading POKéMON right now.\p");
+ALIGNED(4) const u8 sText_FemaleTraded2[] = _("I finally got that POKéMON I\nwanted in a trade!\p");
+
+const u8 *const sUnionRoomTexts_Traded[GENDER_COUNT][4] = {
+ [MALE] =
+ {
+ sText_MaleTraded1,
+ sText_MaleTraded2
+ },
+ [FEMALE] =
+ {
+ sText_FemaleTraded1,
+ sText_FemaleTraded2
+ }
+};
+
+ALIGNED(4) const u8 sText_XCheckedTradingBoard[] = _("{STR_VAR_1} checked the\nTRADING BOARD.\p");
+ALIGNED(4) const u8 sText_RegisterMonAtTradingBoard[] = _("Welcome to the TRADING BOARD.\pYou may register your POKéMON\nand offer it up for a trade.\pWould you like to register one of\nyour POKéMON?");
+ALIGNED(4) const u8 sText_TradingBoardInfo[] = _("This TRADING BOARD is used for\noffering a POKéMON for a trade.\pAll you need to do is register a\nPOKéMON for a trade.\pAnother TRAINER may offer a party\nPOKéMON in return for the trade.\pWe hope you will register POKéMON\nand trade them with many, many\lother TRAINERS.\pWould you like to register one of\nyour POKéMON?");
+ALIGNED(4) const u8 sText_ThankYouForRegistering[] = _("We have registered your POKéMON for\ntrade on the TRADING BOARD.\pThank you for using this service!\p"); // unused
+ALIGNED(4) const u8 sText_NobodyHasRegistered[] = _("Nobody has registered any POKéMON\nfor trade on the TRADING BOARD.\p\n"); // unused
+ALIGNED(4) const u8 sText_ChooseRequestedMonType[] = _("Please choose the type of POKéMON\nthat you would like in the trade.\n");
+ALIGNED(4) const u8 sText_WhichMonWillYouOffer[] = _("Which of your party POKéMON will\nyou offer in trade?\p");
+ALIGNED(4) const u8 sText_RegistrationCanceled[] = _("Registration has been canceled.\p");
+ALIGNED(4) const u8 sText_RegistraionCompleted[] = _("Registration has been completed.\p");
+ALIGNED(4) const u8 sText_TradeCanceled[] = _("The trade has been canceled.\p");
+ALIGNED(4) const u8 sText_CancelRegistrationOfMon[] = _("Cancel the registration of your\nLv. {STR_VAR_2} {STR_VAR_1}?");
+ALIGNED(4) const u8 sText_CancelRegistrationOfEgg[] = _("Cancel the registration of your\nEGG?");
+ALIGNED(4) const u8 sText_RegistrationCanceled2[] = _("The registration has been canceled.\p");
+ALIGNED(4) const u8 sText_TradeTrainersWillBeListed[] = _("TRAINERS wishing to make a trade\nwill be listed."); // unused
+ALIGNED(4) const u8 sText_ChooseTrainerToTradeWith[] = _("Please choose the TRAINER with whom\nyou would like to trade POKéMON."); // unused
+ALIGNED(4) const u8 sText_AskTrainerToMakeTrade[] = _("Would you like to ask {STR_VAR_1} to\nmake a trade?");
+ALIGNED(4) const u8 sText_AwaitingResponseFromTrainer[] = _("Awaiting a response from\nthe other TRAINER…"); // unused
+ALIGNED(4) const u8 sText_NotRegisteredAMonForTrade[] = _("You have not registered a POKéMON\nfor trading.\p"); // unused
+ALIGNED(4) const u8 sText_DontHaveTypeTrainerWants[] = _("You don't have a {STR_VAR_2}-type\nPOKéMON that {STR_VAR_1} wants.\p");
+ALIGNED(4) const u8 sText_DontHaveEggTrainerWants[] = _("You don't have an EGG that\n{STR_VAR_1} wants.\p");
+ALIGNED(4) const u8 sText_CantTradeMonRightNow[] = _("{STR_VAR_1} can't make a trade for\nyour POKéMON right now.\p");
+ALIGNED(4) const u8 sText_CantTradePartnersMonRightNow[] = _("You can't make a trade for\n{STR_VAR_1}'s POKéMON right now.\p");
+
+// unused
+const u8 *const sUnionRoomTexts_CantTradeRightNow[] = {
+ sText_CantTradeMonRightNow,
+ sText_CantTradePartnersMonRightNow
+};
+
+ALIGNED(4) const u8 sText_TradeOfferRejected[] = _("Your trade offer was rejected.\p");
+ALIGNED(4) const u8 sText_EggTrade[] = _("EGG TRADE");
+ALIGNED(4) const u8 gUnknown_082EF7DC[] = _("{DPAD_UPDOWN}CHOOSE {A_BUTTON}JOIN {B_BUTTON}CANCEL");
+ALIGNED(4) const u8 gUnknown_082EF7F8[] = _("Please choose a TRAINER.");
+ALIGNED(4) const u8 gUnknown_082EF814[] = _("Please choose a TRAINER for\na SINGLE BATTLE.");
+ALIGNED(4) const u8 gUnknown_082EF844[] = _("Please choose a TRAINER for\na DOUBLE BATTLE.");
+ALIGNED(4) const u8 gUnknown_082EF874[] = _("Please choose the LEADER\nfor a MULTI BATTLE.");
+ALIGNED(4) const u8 gUnknown_082EF8A4[] = _("Please choose the TRAINER to\ntrade with.");
+ALIGNED(4) const u8 gUnknown_082EF8D0[] = _("Please choose the TRAINER who is\nsharing WONDER CARDS.");
+ALIGNED(4) const u8 gUnknown_082EF908[] = _("Please choose the TRAINER who is\nsharing WONDER NEWS.");
+ALIGNED(4) const u8 gUnknown_082EF940[] = _("Jump with mini POKéMON!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EF974[] = _("BERRY CRUSH!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EF99C[] = _("DODRIO BERRY-PICKING!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EF9CC[] = _("BERRY BLENDER!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EF9F8[] = _("RECORD CORNER!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFA24[] = _("COOLNESS CONTEST!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFA50[] = _("BEAUTY CONTEST!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFA7C[] = _("CUTENESS CONTEST!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFAA8[] = _("SMARTNESS CONTEST!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFAD8[] = _("TOUGHNESS CONTEST!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFB08[] = _("BATTLE TOWER LEVEL 50!\nPlease choose the LEADER.");
+ALIGNED(4) const u8 gUnknown_082EFB3C[] = _("BATTLE TOWER OPEN LEVEL!\nPlease choose the LEADER.");
+
+const u8 *const gUnknown_082EFB70[] = {
+ gUnknown_082EF814,
+ gUnknown_082EF844,
+ gUnknown_082EF874,
+ gUnknown_082EF8A4,
+ gUnknown_082EF940,
+ gUnknown_082EF974,
+ gUnknown_082EF99C,
+ gUnknown_082EF8D0,
+ gUnknown_082EF908,
+ NULL,
+ NULL,
+ NULL,
+ gUnknown_082EF9F8,
+ gUnknown_082EF9CC,
+ NULL,
+ gUnknown_082EFA24,
+ gUnknown_082EFA50,
+ gUnknown_082EFA7C,
+ gUnknown_082EFAA8,
+ gUnknown_082EFAD8,
+ gUnknown_082EFB08,
+ gUnknown_082EFB3C
+};
+
+ALIGNED(4) const u8 gUnknown_082EFBC8[] = _("Searching for a WIRELESS\nCOMMUNICATION SYSTEM. Wait...");
+ALIGNED(4) const u8 unref_text_union_room_12[] = _("For a DOUBLE BATTLE, you must have\nat least two POKéMON.\p");
+ALIGNED(4) const u8 gUnknown_082EFC3C[] = _("Awaiting {STR_VAR_1}'s response…");
+ALIGNED(4) const u8 gUnknown_082EFC54[] = _("{STR_VAR_1} has been asked to register\nyou as a member. Please wait.");
+ALIGNED(4) const u8 gUnknown_082EFC90[] = _("Awaiting a response from the\nWIRELESS COMMUNICATION SYSTEM.");
+ALIGNED(4) const u8 unref_text_union_room_13[] = _("Please wait for other TRAINERS to\ngather and get ready.");
+ALIGNED(4) const u8 gUnknown_082EFD04[] = _("No CARDS appear to be shared \nright now.");
+ALIGNED(4) const u8 gUnknown_082EFD30[] = _("No NEWS appears to be shared\nright now.");
+
+const u8 *const gUnknown_082EFD58[] = {
+ gUnknown_082EFD04,
+ gUnknown_082EFD30
+};
+
+ALIGNED(4) const u8 gUnknown_082EFD60[] = _("BATTLE");
+ALIGNED(4) const u8 gUnknown_082EFD68[] = _("CHAT");
+ALIGNED(4) const u8 gUnknown_082EFD70[] = _("GREETINGS");
+ALIGNED(4) const u8 gUnknown_082EFD7C[] = _("EXIT");
+ALIGNED(4) const u8 gUnknown_082EFD84[] = _("EXIT");
+ALIGNED(4) const u8 gUnknown_082EFD8C[] = _("INFO");
+ALIGNED(4) const u8 gUnknown_082EFD94[] = _("NAME{CLEAR_TO 0x3C}WANTED{CLEAR_TO 0x6E}OFFER{CLEAR_TO 0xC6}LV.");
+ALIGNED(4) const u8 gUnknown_082EFDB0[] = _("SINGLE BATTLE");
+ALIGNED(4) const u8 gUnknown_082EFDC0[] = _("DOUBLE BATTLE");
+ALIGNED(4) const u8 gUnknown_082EFDD0[] = _("MULTI BATTLE");
+ALIGNED(4) const u8 gUnknown_082EFDE0[] = _("POKéMON TRADES");
+ALIGNED(4) const u8 gUnknown_082EFDF0[] = _("CHAT");
+ALIGNED(4) const u8 gUnknown_082EFDF8[] = _("CARDS");
+ALIGNED(4) const u8 gUnknown_082EFE00[] = _("WONDER CARDS");
+ALIGNED(4) const u8 gUnknown_082EFE10[] = _("WONDER NEWS");
+ALIGNED(4) const u8 gUnknown_082EFE1C[] = _("POKéMON JUMP");
+ALIGNED(4) const u8 gUnknown_082EFE2C[] = _("BERRY CRUSH");
+ALIGNED(4) const u8 gUnknown_082EFE38[] = _("BERRY-PICKING");
+ALIGNED(4) const u8 gUnknown_082EFE48[] = _("SEARCH");
+ALIGNED(4) const u8 gUnknown_082EFE50[] = _("BERRY BLENDER");
+ALIGNED(4) const u8 gUnknown_082EFE60[] = _("RECORD CORNER");
+ALIGNED(4) const u8 gUnknown_082EFE70[] = _("COOL CONTEST");
+ALIGNED(4) const u8 gUnknown_082EFE80[] = _("BEAUTY CONTEST");
+ALIGNED(4) const u8 gUnknown_082EFE90[] = _("CUTE CONTEST");
+ALIGNED(4) const u8 gUnknown_082EFEA0[] = _("SMART CONTEST");
+ALIGNED(4) const u8 gUnknown_082EFEB0[] = _("TOUGH CONTEST");
+ALIGNED(4) const u8 gUnknown_082EFEC0[] = _("BATTLE TOWER LV. 50");
+ALIGNED(4) const u8 gUnknown_082EFED4[] = _("BATTLE TOWER OPEN LEVEL");
+ALIGNED(4) const u8 gUnknown_082EFEEC[] = _("It's a NORMAL CARD.");
+ALIGNED(4) const u8 gUnknown_082EFF00[] = _("It's a BRONZE CARD!");
+ALIGNED(4) const u8 gUnknown_082EFF14[] = _("It's a COPPER CARD!");
+ALIGNED(4) const u8 gUnknown_082EFF28[] = _("It's a SILVER CARD!");
+ALIGNED(4) const u8 gUnknown_082EFF3C[] = _("It's a GOLD CARD!");
+
+const u8 *const gUnknown_082EFF50[] = {
+ gUnknown_082EFEEC,
+ gUnknown_082EFF00,
+ gUnknown_082EFF14,
+ gUnknown_082EFF28,
+ gUnknown_082EFF3C
+};
+
+ALIGNED(4) const u8 gUnknown_082EFF64[] = _("This is {SPECIAL_F7 0x00} {SPECIAL_F7 0x01}'s\nTRAINER CARD…\l{SPECIAL_F7 0x02}\pPOKéDEX: {SPECIAL_F7 0x03}\nTIME: {SPECIAL_F7 0x04}:{SPECIAL_F7 0x05}\p");
+ALIGNED(4) const u8 gUnknown_082EFFA4[] = _("BATTLES: WINS: {SPECIAL_F7 0x00} LOSSES: {SPECIAL_F7 0x02}\nTRADES: {SPECIAL_F7 0x03}\p“{SPECIAL_F7 0x04} {SPECIAL_F7 0x05}\n{SPECIAL_F7 0x06} {SPECIAL_F7 0x07}”\p");
+ALIGNED(4) const u8 gUnknown_082EFFDC[] = _("{SPECIAL_F7 0x01}: Glad to have met you!{PAUSE 60}");
+ALIGNED(4) const u8 gUnknown_082EFFFC[] = _("{SPECIAL_F7 0x01}: Glad to meet you!{PAUSE 60}");
+
+const u8 *const gUnknown_082F0018[] = {
+ gUnknown_082EFFDC,
+ gUnknown_082EFFFC
+};
+
+ALIGNED(4) const u8 gUnknown_082F0020[] = _("Finished checking {SPECIAL_F7 0x01}'s\nTRAINER CARD.{PAUSE 60}");
+
+const u8 *const gUnknown_082F0048[] = {
+ gText_EmptyString,
+ gUnknown_082EFDB0,
+ gUnknown_082EFDC0,
+ gUnknown_082EFDD0,
+ gUnknown_082EFDE0,
+ gUnknown_082EFDF0,
+ gUnknown_082EFE00,
+ gUnknown_082EFE10,
+ gUnknown_082EFDF8,
+ gUnknown_082EFE1C,
+ gUnknown_082EFE2C,
+ gUnknown_082EFE38,
+ gUnknown_082EFE48,
+ gText_EmptyString,
+ gUnknown_082EFED4,
+ gUnknown_082EFE60,
+ gUnknown_082EFE50,
+ gText_EmptyString,
+ gText_EmptyString,
+ gText_EmptyString,
+ gText_EmptyString,
+ gUnknown_082EFE00,
+ gUnknown_082EFE10,
+ gUnknown_082EFE70,
+ gUnknown_082EFE80,
+ gUnknown_082EFE90,
+ gUnknown_082EFEA0,
+ gUnknown_082EFEB0,
+ gUnknown_082EFEC0
+};
+
+const struct WindowTemplate gUnknown_082F00BC = {
+ .bg = 0x00,
+ .tilemapLeft = 0x00,
+ .tilemapTop = 0x00,
+ .width = 0x1E,
+ .height = 0x02,
+ .paletteNum = 0x0F,
+ .baseBlock = 0x0008
+};
+
+const u32 gUnknown_082F00C4[] = {
+ 0x0201,
+ 0x0202,
+ 0x0403,
+ 0x0204,
+ 0x2509,
+ 0x250a,
+ 0x350b,
+ 0x0000,
+ 0x0000,
+ 0x0000,
+ 0x0000,
+ 0x0000,
+ 0x240f,
+ 0x2410,
+ 0x0000,
+ 0x2417,
+ 0x2418,
+ 0x2419,
+ 0x241a,
+ 0x241b,
+ 0x021c,
+ 0x020e
+};
+
+const struct WindowTemplate gUnknown_082F011C = {
+ .bg = 0x00,
+ .tilemapLeft = 0x01,
+ .tilemapTop = 0x03,
+ .width = 0x0d,
+ .height = 0x08,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x0044
+};
+
+const struct WindowTemplate gUnknown_082F0124 = {
+ .bg = 0x00,
+ .tilemapLeft = 0x01,
+ .tilemapTop = 0x03,
+ .width = 0x0d,
+ .height = 0x0a,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x0044
+};
+
+const struct WindowTemplate gUnknown_082F012C = {
+ .bg = 0x00,
+ .tilemapLeft = 0x10,
+ .tilemapTop = 0x03,
+ .width = 0x07,
+ .height = 0x04,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x00c6
+};
+
+const struct ListMenuItem gUnknown_082F0134[] = {
+ { gText_EmptyString, 0 },
+ { gText_EmptyString, 1 },
+ { gText_EmptyString, 2 },
+ { gText_EmptyString, 3 },
+ { gText_EmptyString, 4 }
+};
+
+const struct ListMenuTemplate gUnknown_082F015C = {
+ .items = gUnknown_082F0134,
+ .moveCursorFunc = NULL,
+ .itemPrintFunc = sub_8013278,
+ .totalItems = 5,
+ .maxShowed = 5,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 0,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 2,
+ .fillValue = 1,
+ .cursorShadowPal = 3,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 0,
+ .fontId = 1,
+ .cursorKind = 1
+};
+
+const struct WindowTemplate gUnknown_082F0174 = {
+ .bg = 0x00,
+ .tilemapLeft = 0x01,
+ .tilemapTop = 0x03,
+ .width = 0x11,
+ .height = 0x0a,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x0044
+};
+
+const struct WindowTemplate gUnknown_082F017C = {
+ .bg = 0x00,
+ .tilemapLeft = 0x14,
+ .tilemapTop = 0x03,
+ .width = 0x07,
+ .height = 0x04,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x00ee
+};
+
+const struct ListMenuItem gUnknown_082F0184[] = {
+ { gText_EmptyString, 0 },
+ { gText_EmptyString, 1 },
+ { gText_EmptyString, 2 },
+ { gText_EmptyString, 3 },
+ { gText_EmptyString, 4 },
+ { gText_EmptyString, 5 },
+ { gText_EmptyString, 6 },
+ { gText_EmptyString, 7 },
+ { gText_EmptyString, 8 },
+ { gText_EmptyString, 9 },
+ { gText_EmptyString, 10 },
+ { gText_EmptyString, 11 },
+ { gText_EmptyString, 12 },
+ { gText_EmptyString, 13 },
+ { gText_EmptyString, 14 },
+ { gText_EmptyString, 15 }
+};
+
+const struct ListMenuTemplate gUnknown_082F0204 = {
+ .items = gUnknown_082F0184,
+ .moveCursorFunc = ListMenuDefaultCursorMoveFunc,
+ .itemPrintFunc = sub_8013DF4,
+ .totalItems = 16,
+ .maxShowed = 5,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 8,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 2,
+ .fillValue = 1,
+ .cursorShadowPal = 3,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 1,
+ .fontId = 1,
+ .cursorKind = 0
+};
+
+const struct WindowTemplate gUnknown_082F021C = {
+ .bg = 0x00,
+ .tilemapLeft = 0x14,
+ .tilemapTop = 0x05,
+ .width = 0x10,
+ .height = 0x08,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x0001
+};
+
+const struct ListMenuItem gUnknown_082F0224[] = {
+ { gUnknown_082EFD70, 0x208 },
+ { gUnknown_082EFD60, 0x241 },
+ { gUnknown_082EFD68, 0x245 },
+ { gUnknown_082EFD7C, 0x040 }
+};
+
+const struct ListMenuTemplate gUnknown_082F0244 = {
+ .items = gUnknown_082F0224,
+ .moveCursorFunc = ListMenuDefaultCursorMoveFunc,
+ .itemPrintFunc = NULL,
+ .totalItems = 4,
+ .maxShowed = 4,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 8,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 2,
+ .fillValue = 1,
+ .cursorShadowPal = 3,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 0,
+ .fontId = 1,
+ .cursorKind = 0
+};
+
+const struct WindowTemplate gUnknown_082F025C = {
+ .bg = 0x00,
+ .tilemapLeft = 0x12,
+ .tilemapTop = 0x07,
+ .width = 0x10,
+ .height = 0x06,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x0001
+};
+
+const struct ListMenuItem gUnknown_082F0264[] = {
+ { gText_Register, 1 },
+ { gUnknown_082EFD8C, 2 },
+ { gUnknown_082EFD7C, 3 }
+};
+
+const struct ListMenuTemplate gUnknown_082F027C = {
+ .items = gUnknown_082F0264,
+ .moveCursorFunc = ListMenuDefaultCursorMoveFunc,
+ .itemPrintFunc = NULL,
+ .totalItems = 3,
+ .maxShowed = 3,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 8,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 2,
+ .fillValue = 1,
+ .cursorShadowPal = 3,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 0,
+ .fontId = 1,
+ .cursorKind = 0
+};
+
+const struct WindowTemplate gUnknown_082F0294 = {
+ .bg = 0x00,
+ .tilemapLeft = 0x14,
+ .tilemapTop = 0x01,
+ .width = 0x10,
+ .height = 0x0c,
+ .paletteNum = 0x0f,
+ .baseBlock = 0x0001
+};
+
+static const struct ListMenuItem sTradingBoardTypes[] = {
+ { gTypeNames[TYPE_NORMAL], TYPE_NORMAL },
+ { gTypeNames[TYPE_FIRE], TYPE_FIRE },
+ { gTypeNames[TYPE_WATER], TYPE_WATER },
+ { gTypeNames[TYPE_ELECTRIC], TYPE_ELECTRIC },
+ { gTypeNames[TYPE_GRASS], TYPE_GRASS },
+ { gTypeNames[TYPE_ICE], TYPE_ICE },
+ { gTypeNames[TYPE_GROUND], TYPE_GROUND },
+ { gTypeNames[TYPE_ROCK], TYPE_ROCK },
+ { gTypeNames[TYPE_FLYING], TYPE_FLYING },
+ { gTypeNames[TYPE_PSYCHIC], TYPE_PSYCHIC },
+ { gTypeNames[TYPE_FIGHTING], TYPE_FIGHTING },
+ { gTypeNames[TYPE_POISON], TYPE_POISON },
+ { gTypeNames[TYPE_BUG], TYPE_BUG },
+ { gTypeNames[TYPE_GHOST], TYPE_GHOST },
+ { gTypeNames[TYPE_DRAGON], TYPE_DRAGON },
+ { gTypeNames[TYPE_STEEL], TYPE_STEEL },
+ { gTypeNames[TYPE_DARK], TYPE_DARK },
+ { gUnknown_082EFD7C, NUMBER_OF_MON_TYPES }
+};
+
+const struct ListMenuTemplate sMenuTemplate_TradingBoardRequestType = {
+ .items = sTradingBoardTypes,
+ .moveCursorFunc = ListMenuDefaultCursorMoveFunc,
+ .itemPrintFunc = NULL,
+ .totalItems = NUMBER_OF_MON_TYPES,
+ .maxShowed = 6,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 8,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 2,
+ .fillValue = 1,
+ .cursorShadowPal = 3,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 0,
+ .fontId = 1,
+ .cursorKind = 0
+};
+
+const struct WindowTemplate gUnknown_082F0344 = {
+ .bg = 0x00,
+ .tilemapLeft = 0x01,
+ .tilemapTop = 0x01,
+ .width = 0x1c,
+ .height = 0x02,
+ .paletteNum = 0x0d,
+ .baseBlock = 0x0001
+};
+
+const struct WindowTemplate gUnknown_082F034C = {
+ .bg = 0x00,
+ .tilemapLeft = 0x01,
+ .tilemapTop = 0x05,
+ .width = 0x1c,
+ .height = 0x0c,
+ .paletteNum = 0x0d,
+ .baseBlock = 0x0039
+};
+
+const struct ListMenuItem gUnknown_082F0354[] = {
+ { gText_EmptyString, -3 },
+ { gText_EmptyString, 0 },
+ { gText_EmptyString, 1 },
+ { gText_EmptyString, 2 },
+ { gText_EmptyString, 3 },
+ { gText_EmptyString, 4 },
+ { gText_EmptyString, 5 },
+ { gText_EmptyString, 6 },
+ { gText_EmptyString, 7 },
+ { gUnknown_082EFD84, 8 }
+};
+
+const struct ListMenuTemplate gUnknown_082F03A4 = {
+ .items = gUnknown_082F0354,
+ .moveCursorFunc = ListMenuDefaultCursorMoveFunc,
+ .itemPrintFunc = sub_8017BE8,
+ .totalItems = 10,
+ .maxShowed = 6,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 8,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 14,
+ .fillValue = 15,
+ .cursorShadowPal = 13,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 0,
+ .fontId = 1,
+ .cursorKind = 0
+};
+
+const struct WindowTemplate UnrefWindowTemplate_082F03B4 = {
+ .bg = 0x00,
+ .tilemapLeft = 0x01,
+ .tilemapTop = 0x05,
+ .width = 0x1c,
+ .height = 0x0c,
+ .paletteNum = 0x0d,
+ .baseBlock = 0x0039
+};
+
+const struct ListMenuItem gUnknown_082F03C4[] = {
+ { gText_EmptyString, 0 },
+ { gText_EmptyString, 1 },
+ { gText_EmptyString, 2 },
+ { gText_EmptyString, 3 },
+ { gText_EmptyString, 4 },
+ { gText_EmptyString, 5 },
+ { gText_EmptyString, 6 },
+ { gText_EmptyString, 7 },
+ { gText_EmptyString, 8 },
+ { gText_EmptyString, 9 },
+ { gText_EmptyString, 10 },
+ { gText_EmptyString, 11 },
+ { gText_EmptyString, 12 },
+ { gText_EmptyString, 13 },
+ { gText_EmptyString, 14 },
+ { gText_EmptyString, 15 }
+};
+
+const struct ListMenuTemplate UnrefListMenuTemplate_082F0444 = {
+ .items = gUnknown_082F03C4,
+ .moveCursorFunc = ListMenuDefaultCursorMoveFunc,
+ .itemPrintFunc = nullsub_14,
+ .totalItems = 16,
+ .maxShowed = 4,
+ .windowId = 0,
+ .header_X = 0,
+ .item_X = 8,
+ .cursor_X = 0,
+ .upText_Y = 1,
+ .cursorPal = 2,
+ .fillValue = 1,
+ .cursorShadowPal = 3,
+ .lettersSpacing = 0,
+ .itemVerticalPadding = 0,
+ .scrollMultiple = 1,
+ .fontId = 1,
+ .cursorKind = 0
+};
+
+const struct UnkStruct_Shared gUnknown_082F045C = {0};
+
+ALIGNED(4) const u8 gUnknown_082F0474[] = {0x01, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0478[] = {0x02, 0xff};
+ALIGNED(4) const u8 gUnknown_082F047C[] = {0x03, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0480[] = {0x04, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0484[] = {0x09, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0488[] = {0x0a, 0xff};
+ALIGNED(4) const u8 gUnknown_082F048C[] = {0x0b, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0490[] = {0x15, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0494[] = {0x16, 0xff};
+ALIGNED(4) const u8 gUnknown_082F0498[] = {0x40, 0x41, 0x44, 0x45, 0x48, 0x51, 0x52, 0x53, 0x54, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04A4[] = {0x0c, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04A8[] = {0x01, 0x02, 0x03, 0x04, 0x09, 0x0a, 0x0b, 0x15, 0x16, 0x0d, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04B4[] = {0x0f, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04B8[] = {0x10, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04BC[] = {0x17, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04C0[] = {0x18, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04C4[] = {0x19, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04C8[] = {0x1a, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04CC[] = {0x1b, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04D0[] = {0x1c, 0xff};
+ALIGNED(4) const u8 gUnknown_082F04D4[] = {0x0e, 0xff};
+
+const u8 *const gUnknown_082F04D8[] = {
+ gUnknown_082F0474,
+ gUnknown_082F0478,
+ gUnknown_082F047C,
+ gUnknown_082F0480,
+ gUnknown_082F0484,
+ gUnknown_082F0488,
+ gUnknown_082F048C,
+ gUnknown_082F0490,
+ gUnknown_082F0494,
+ gUnknown_082F0498,
+ gUnknown_082F04A4,
+ gUnknown_082F04A8,
+ gUnknown_082F04B4,
+ gUnknown_082F04B8,
+ NULL,
+ gUnknown_082F04BC,
+ gUnknown_082F04C0,
+ gUnknown_082F04C4,
+ gUnknown_082F04C8,
+ gUnknown_082F04CC,
+ gUnknown_082F04D0,
+ gUnknown_082F04D4
+};
+
+const u8 gUnknown_082F0530[] = {
+ 0x01, 0x02, 0x03, 0x04, 0x09, 0x0a, 0x0b, 0x15,
+ 0x16, 0x00, 0x00, 0x00, 0x0f, 0x10, 0x00, 0x17,
+ 0x18, 0x19, 0x1a, 0x1b, 0x1c, 0x0e, 0x00, 0x00
+};
diff --git a/src/data/wild_encounters.json b/src/data/wild_encounters.json
index ea555bd32..19aa40b00 100755
--- a/src/data/wild_encounters.json
+++ b/src/data/wild_encounters.json
@@ -26,7 +26,12 @@
"type": "fishing_mons",
"encounter_rates": [
70, 30, 60, 20, 20, 40, 40, 15, 4, 1
- ]
+ ],
+ "groups": {
+ "old_rod": [0, 1],
+ "good_rod": [2, 3, 4],
+ "super_rod": [5, 6, 7, 8, 9]
+ }
}
],
"encounters": [
diff --git a/src/data/wild_encounters.json.txt b/src/data/wild_encounters.json.txt
index 85755ddec..bf848249f 100755
--- a/src/data/wild_encounters.json.txt
+++ b/src/data/wild_encounters.json.txt
@@ -3,14 +3,26 @@
## for wild_encounter_group in wild_encounter_groups
{% if wild_encounter_group.for_maps %}
## for wild_encounter_field in wild_encounter_group.fields
+{% if not existsIn(wild_encounter_field, "groups") %}
## for encounter_rate in wild_encounter_field.encounter_rates
-{% if trackVar(encounter_rate, 100) %}
+{% if loop.index == 0 %}
#define ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_SLOT_{{ loop.index }} {{ encounter_rate }} {% else %}#define ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_SLOT_{{ loop.index }} ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_SLOT_{{ subtract(loop.index, 1) }} + {{ encounter_rate }}{% endif %} {{ setVarInt(wild_encounter_field.type, loop.index) }}
## endfor
#define ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_TOTAL (ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_SLOT_{{ getVar(wild_encounter_field.type) }})
+{% else %}
+## for field_subgroup_key, field_subgroup_subarray in wild_encounter_field.groups
+## for field_subgroup_index in field_subgroup_subarray
+{% if loop.index == 0 %}
+#define ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_{{ upper(field_subgroup_key) }}_SLOT_{{ field_subgroup_index }} {{ at(wild_encounter_field.encounter_rates, field_subgroup_index) }} {% else %}#define ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_{{ upper(field_subgroup_key) }}_SLOT_{{ field_subgroup_index }} ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_{{ upper(field_subgroup_key) }}_SLOT_{{ getVar("previous_slot") }} + {{ at(wild_encounter_field.encounter_rates, field_subgroup_index) }}{% endif %}{{ setVarInt(concat(wild_encounter_field.type, field_subgroup_key), field_subgroup_index) }}{{ setVarInt("previous_slot", field_subgroup_index) }}
+## endfor
+#define ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_{{ upper(field_subgroup_key) }}_TOTAL (ENCOUNTER_CHANCE_{{ upper(wild_encounter_field.type) }}_{{ upper(field_subgroup_key) }}_SLOT_{{ getVar(concat(wild_encounter_field.type, field_subgroup_key)) }})
+## endfor
+{% endif %}
## endfor
{% endif %}
+
+
## for encounter in wild_encounter_group.encounters
{% if existsIn(encounter, "land_mons") %}
const struct WildPokemon {{ encounter.base_label }}_LandMons[] =