mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-27 04:04:17 +01:00
Cleanup; create enums for trainer rematches
This commit is contained in:
parent
6bfc8579ad
commit
80906f022b
87
include/trainer_rematch.h
Normal file
87
include/trainer_rematch.h
Normal file
@ -0,0 +1,87 @@
|
|||||||
|
#ifndef GUARD_TRAINER_REMATCH_H
|
||||||
|
#define GUARD_TRAINER_REMATCH_H
|
||||||
|
|
||||||
|
enum {
|
||||||
|
REMATCH_ROSE,
|
||||||
|
REMATCH_ANDRES,
|
||||||
|
REMATCH_DUSTY,
|
||||||
|
REMATCH_LOLA,
|
||||||
|
REMATCH_RICKY,
|
||||||
|
REMATCH_LILA_AND_ROY,
|
||||||
|
REMATCH_CRISTIN,
|
||||||
|
REMATCH_BROOKE,
|
||||||
|
REMATCH_WILTON,
|
||||||
|
REMATCH_VALERIE,
|
||||||
|
REMATCH_CINDY,
|
||||||
|
REMATCH_THALIA,
|
||||||
|
REMATCH_JESSICA,
|
||||||
|
REMATCH_WINSTON,
|
||||||
|
REMATCH_STEVE,
|
||||||
|
REMATCH_TONY,
|
||||||
|
REMATCH_NOB,
|
||||||
|
REMATCH_KOJI,
|
||||||
|
REMATCH_FERNANDO,
|
||||||
|
REMATCH_DALTON,
|
||||||
|
REMATCH_BERNIE,
|
||||||
|
REMATCH_ETHAN,
|
||||||
|
REMATCH_JOHN_AND_JAY,
|
||||||
|
REMATCH_JEFFREY,
|
||||||
|
REMATCH_CAMERON,
|
||||||
|
REMATCH_JACKI,
|
||||||
|
REMATCH_WALTER,
|
||||||
|
REMATCH_KAREN,
|
||||||
|
REMATCH_JERRY,
|
||||||
|
REMATCH_ANNA_AND_MEG,
|
||||||
|
REMATCH_ISABEL,
|
||||||
|
REMATCH_MIGUEL,
|
||||||
|
REMATCH_TIMOTHY,
|
||||||
|
REMATCH_SHELBY,
|
||||||
|
REMATCH_CALVIN,
|
||||||
|
REMATCH_ELLIOT,
|
||||||
|
REMATCH_ISAIAH,
|
||||||
|
REMATCH_MARIA,
|
||||||
|
REMATCH_ABIGAIL,
|
||||||
|
REMATCH_DYLAN,
|
||||||
|
REMATCH_KATELYN,
|
||||||
|
REMATCH_BENJAMIN,
|
||||||
|
REMATCH_PABLO,
|
||||||
|
REMATCH_NICOLAS,
|
||||||
|
REMATCH_ROBERT,
|
||||||
|
REMATCH_LAO,
|
||||||
|
REMATCH_CYNDY,
|
||||||
|
REMATCH_MADELINE,
|
||||||
|
REMATCH_JENNY,
|
||||||
|
REMATCH_DIANA,
|
||||||
|
REMATCH_AMY_AND_LIV,
|
||||||
|
REMATCH_ERNEST,
|
||||||
|
REMATCH_CORY,
|
||||||
|
REMATCH_EDWIN,
|
||||||
|
REMATCH_LYDIA,
|
||||||
|
REMATCH_ISAAC,
|
||||||
|
REMATCH_GABRIELLE,
|
||||||
|
REMATCH_CATHERINE,
|
||||||
|
REMATCH_JACKSON,
|
||||||
|
REMATCH_HALEY,
|
||||||
|
REMATCH_JAMES,
|
||||||
|
REMATCH_TRENT,
|
||||||
|
REMATCH_SAWYER,
|
||||||
|
REMATCH_KIRA_AND_DAN,
|
||||||
|
REMATCH_WALLY_3,
|
||||||
|
REMATCH_ROXANNE,
|
||||||
|
REMATCH_BRAWLY,
|
||||||
|
REMATCH_WATTSON,
|
||||||
|
REMATCH_FLANNERY,
|
||||||
|
REMATCH_NORMAN,
|
||||||
|
REMATCH_WINONA,
|
||||||
|
REMATCH_TATE_AND_LIZA,
|
||||||
|
REMATCH_JUAN,
|
||||||
|
REMATCH_SIDNEY,
|
||||||
|
REMATCH_PHOEBE,
|
||||||
|
REMATCH_GLACIA,
|
||||||
|
REMATCH_DRAKE,
|
||||||
|
REMATCH_WALLACE
|
||||||
|
};
|
||||||
|
|
||||||
|
void sub_81DA57C(void);
|
||||||
|
|
||||||
|
#endif //GUARD_TRAINER_REMATCH_H
|
@ -252,84 +252,84 @@ static const struct TrainerBattleParameter sTrainerBContinueScriptBattleParams[]
|
|||||||
|
|
||||||
const struct RematchTrainer gRematchTable[REMATCH_TABLE_ENTRIES] =
|
const struct RematchTrainer gRematchTable[REMATCH_TABLE_ENTRIES] =
|
||||||
{
|
{
|
||||||
{{0x0025, 0x0028, 0x0029, 0x002a, 0x002b}, 0x0000, 0x0021},
|
{{TRAINER_ROSE_1, TRAINER_ROSE_2, TRAINER_ROSE_3, TRAINER_ROSE_4, TRAINER_ROSE_5}, 0x0, 0x21},
|
||||||
{{0x02e1, 0x032c, 0x032d, 0x032e, 0x032f}, 0x0000, 0x0014},
|
{{TRAINER_ANDRES_1, TRAINER_ANDRES_2, TRAINER_ANDRES_3, TRAINER_ANDRES_4, TRAINER_ANDRES_5}, 0x0, 0x14},
|
||||||
{{0x002c, 0x002f, 0x0030, 0x0031, 0x0032}, 0x0000, 0x001a},
|
{{TRAINER_DUSTY_1, TRAINER_DUSTY_2, TRAINER_DUSTY_3, TRAINER_DUSTY_4, TRAINER_DUSTY_5}, 0x0, 0x1a},
|
||||||
{{0x0039, 0x003c, 0x003d, 0x003e, 0x003f}, 0x0000, 0x0018},
|
{{TRAINER_LOLA_1, TRAINER_LOLA_2, TRAINER_LOLA_3, TRAINER_LOLA_4, TRAINER_LOLA_5}, 0x0, 0x18},
|
||||||
{{0x0040, 0x0043, 0x0044, 0x0045, 0x0046}, 0x0000, 0x0018},
|
{{TRAINER_RICKY_1, TRAINER_RICKY_2, TRAINER_RICKY_3, TRAINER_RICKY_4, TRAINER_RICKY_5}, 0x0, 0x18},
|
||||||
{{0x02af, 0x02b0, 0x02b1, 0x02b2, 0x02b3}, 0x0000, 0x0027},
|
{{TRAINER_LILA_AND_ROY_1, TRAINER_LILA_AND_ROY_2, TRAINER_LILA_AND_ROY_3, TRAINER_LILA_AND_ROY_4, TRAINER_LILA_AND_ROY_5}, 0x0, 0x27},
|
||||||
{{0x02ff, 0x033c, 0x033d, 0x033e, 0x033f}, 0x0000, 0x0024},
|
{{TRAINER_CRISTIN_1, TRAINER_CRISTIN_2, TRAINER_CRISTIN_3, TRAINER_CRISTIN_4, TRAINER_CRISTIN_5}, 0x0, 0x24},
|
||||||
{{0x005e, 0x0065, 0x0066, 0x0067, 0x0068}, 0x0000, 0x001a},
|
{{TRAINER_BROOKE_1, TRAINER_BROOKE_2, TRAINER_BROOKE_3, TRAINER_BROOKE_4, TRAINER_BROOKE_5}, 0x0, 0x1a},
|
||||||
{{0x004e, 0x0054, 0x0055, 0x0056, 0x0057}, 0x0000, 0x001a},
|
{{TRAINER_WILTON_1, TRAINER_WILTON_2, TRAINER_WILTON_3, TRAINER_WILTON_4, TRAINER_WILTON_5}, 0x0, 0x1a},
|
||||||
{{0x006c, 0x006e, 0x006f, 0x0070, 0x0071}, 0x0018, 0x0014},
|
{{TRAINER_VALERIE_1, TRAINER_VALERIE_2, TRAINER_VALERIE_3, TRAINER_VALERIE_4, TRAINER_VALERIE_5}, 0x18, 0x14},
|
||||||
{{0x0072, 0x0078, 0x0079, 0x007a, 0x007b}, 0x0000, 0x0013},
|
{{TRAINER_CINDY_1, TRAINER_CINDY_3, TRAINER_CINDY_4, TRAINER_CINDY_5, TRAINER_CINDY_6}, 0x0, 0x13},
|
||||||
{{0x0090, 0x034c, 0x034d, 0x034e, 0x034f}, 0x0018, 0x0038},
|
{{TRAINER_THALIA_1, TRAINER_THALIA_2, TRAINER_THALIA_3, TRAINER_THALIA_4, TRAINER_THALIA_5}, 0x18, 0x38},
|
||||||
{{0x007f, 0x0084, 0x0085, 0x0086, 0x0087}, 0x0000, 0x0024},
|
{{TRAINER_JESSICA_1, TRAINER_JESSICA_2, TRAINER_JESSICA_3, TRAINER_JESSICA_4, TRAINER_JESSICA_5}, 0x0, 0x24},
|
||||||
{{0x0088, 0x008b, 0x008c, 0x008d, 0x008e}, 0x0000, 0x0013},
|
{{TRAINER_WINSTON_1, TRAINER_WINSTON_2, TRAINER_WINSTON_3, TRAINER_WINSTON_4, TRAINER_WINSTON_5}, 0x0, 0x13},
|
||||||
{{0x008f, 0x0093, 0x0094, 0x0095, 0x0096}, 0x0000, 0x001d},
|
{{TRAINER_STEVE_1, TRAINER_STEVE_2, TRAINER_STEVE_3, TRAINER_STEVE_4, TRAINER_STEVE_5}, 0x0, 0x1d},
|
||||||
{{0x009b, 0x00af, 0x00b0, 0x00b1, 0x00b2}, 0x0000, 0x0016},
|
{{TRAINER_TONY_1, TRAINER_TONY_2, TRAINER_TONY_3, TRAINER_TONY_4, TRAINER_TONY_5}, 0x0, 0x16},
|
||||||
{{0x00b7, 0x00b8, 0x00b9, 0x00ba, 0x00bb}, 0x0000, 0x001e},
|
{{TRAINER_NOB_1, TRAINER_NOB_2, TRAINER_NOB_3, TRAINER_NOB_4, TRAINER_NOB_5}, 0x0, 0x1e},
|
||||||
{{0x02a0, 0x0338, 0x0339, 0x033a, 0x033b}, 0x0000, 0x002a},
|
{{TRAINER_KOJI_1, TRAINER_KOJI_2, TRAINER_KOJI_3, TRAINER_KOJI_4, TRAINER_KOJI_5}, 0x0, 0x2a},
|
||||||
{{0x00c3, 0x0340, 0x0341, 0x0342, 0x0343}, 0x0000, 0x0026},
|
{{TRAINER_FERNANDO_1, TRAINER_FERNANDO_2, TRAINER_FERNANDO_3, TRAINER_FERNANDO_4, TRAINER_FERNANDO_5}, 0x0, 0x26},
|
||||||
{{0x00c4, 0x00c5, 0x00c6, 0x00c7, 0x00c8}, 0x0000, 0x0021},
|
{{TRAINER_DALTON_1, TRAINER_DALTON_2, TRAINER_DALTON_3, TRAINER_DALTON_4, TRAINER_DALTON_5}, 0x0, 0x21},
|
||||||
{{0x00ce, 0x00cf, 0x00d0, 0x00d1, 0x00d2}, 0x0000, 0x001d},
|
{{TRAINER_BERNIE_1, TRAINER_BERNIE_2, TRAINER_BERNIE_3, TRAINER_BERNIE_4, TRAINER_BERNIE_5}, 0x0, 0x1d},
|
||||||
{{0x00d8, 0x00db, 0x00dc, 0x00dd, 0x00de}, 0x0018, 0x000d},
|
{{TRAINER_ETHAN_1, TRAINER_ETHAN_2, TRAINER_ETHAN_3, TRAINER_ETHAN_4, TRAINER_ETHAN_5}, 0x18, 0xd},
|
||||||
{{0x02a9, 0x02aa, 0x02ab, 0x02ac, 0x02ad}, 0x0018, 0x0001},
|
{{TRAINER_JOHN_AND_JAY_1, TRAINER_JOHN_AND_JAY_2, TRAINER_JOHN_AND_JAY_3, TRAINER_JOHN_AND_JAY_4, TRAINER_JOHN_AND_JAY_5}, 0x18, 0x1},
|
||||||
{{0x00e2, 0x00e4, 0x00e5, 0x00e6, 0x00e7}, 0x0000, 0x0023},
|
{{TRAINER_JEFFREY_1, TRAINER_JEFFREY_2, TRAINER_JEFFREY_3, TRAINER_JEFFREY_4, TRAINER_JEFFREY_5}, 0x0, 0x23},
|
||||||
{{0x00ee, 0x00ef, 0x00f0, 0x00f1, 0x00f2}, 0x0000, 0x0026},
|
{{TRAINER_CAMERON_1, TRAINER_CAMERON_2, TRAINER_CAMERON_3, TRAINER_CAMERON_4, TRAINER_CAMERON_5}, 0x0, 0x26},
|
||||||
{{0x00f9, 0x00fa, 0x00fb, 0x00fc, 0x00fd}, 0x0000, 0x0026},
|
{{TRAINER_JACKI_1, TRAINER_JACKI_2, TRAINER_JACKI_3, TRAINER_JACKI_4, TRAINER_JACKI_5}, 0x0, 0x26},
|
||||||
{{0x00fe, 0x0101, 0x0102, 0x0103, 0x0104}, 0x0000, 0x0024},
|
{{TRAINER_WALTER_1, TRAINER_WALTER_2, TRAINER_WALTER_3, TRAINER_WALTER_4, TRAINER_WALTER_5}, 0x0, 0x24},
|
||||||
{{0x0118, 0x011a, 0x011b, 0x011c, 0x011d}, 0x0000, 0x001f},
|
{{TRAINER_KAREN_1, TRAINER_KAREN_2, TRAINER_KAREN_3, TRAINER_KAREN_4, TRAINER_KAREN_5}, 0x0, 0x1f},
|
||||||
{{0x0111, 0x0114, 0x0115, 0x0116, 0x0117}, 0x0000, 0x001f},
|
{{TRAINER_JERRY_1, TRAINER_JERRY_2, TRAINER_JERRY_3, TRAINER_JERRY_4, TRAINER_JERRY_5}, 0x0, 0x1f},
|
||||||
{{0x011f, 0x0120, 0x0121, 0x0122, 0x0123}, 0x0000, 0x0020},
|
{{TRAINER_ANNA_AND_MEG_1, TRAINER_ANNA_AND_MEG_2, TRAINER_ANNA_AND_MEG_3, TRAINER_ANNA_AND_MEG_4, TRAINER_ANNA_AND_MEG_5}, 0x0, 0x20},
|
||||||
{{0x012e, 0x012f, 0x0130, 0x0131, 0x0132}, 0x0000, 0x0019},
|
{{TRAINER_ISABEL_1, TRAINER_ISABEL_2, TRAINER_ISABEL_3, TRAINER_ISABEL_4, TRAINER_ISABEL_5}, 0x0, 0x19},
|
||||||
{{0x0125, 0x0127, 0x0128, 0x0129, 0x012a}, 0x0000, 0x0012},
|
{{TRAINER_MIGUEL_1, TRAINER_MIGUEL_2, TRAINER_MIGUEL_3, TRAINER_MIGUEL_4, TRAINER_MIGUEL_5}, 0x0, 0x12},
|
||||||
{{0x0133, 0x0134, 0x0135, 0x0136, 0x0137}, 0x0000, 0x001e},
|
{{TRAINER_TIMOTHY_1, TRAINER_TIMOTHY_2, TRAINER_TIMOTHY_3, TRAINER_TIMOTHY_4, TRAINER_TIMOTHY_5}, 0x0, 0x1e},
|
||||||
{{0x0139, 0x013a, 0x013b, 0x013c, 0x013d}, 0x0018, 0x000c},
|
{{TRAINER_SHELBY_1, TRAINER_SHELBY_2, TRAINER_SHELBY_3, TRAINER_SHELBY_4, TRAINER_SHELBY_5}, 0x18, 0xc},
|
||||||
{{0x013e, 0x0148, 0x0149, 0x014a, 0x014b}, 0x0000, 0x0011},
|
{{TRAINER_CALVIN_1, TRAINER_CALVIN_2, TRAINER_CALVIN_3, TRAINER_CALVIN_4, TRAINER_CALVIN_5}, 0x0, 0x11},
|
||||||
{{0x0153, 0x015a, 0x015b, 0x015c, 0x015d}, 0x0000, 0x0015},
|
{{TRAINER_ELLIOT_1, TRAINER_ELLIOT_2, TRAINER_ELLIOT_3, TRAINER_ELLIOT_4, TRAINER_ELLIOT_5}, 0x0, 0x15},
|
||||||
{{0x0178, 0x017b, 0x017c, 0x017d, 0x017e}, 0x0000, 0x002b},
|
{{TRAINER_ISAIAH_1, TRAINER_ISAIAH_2, TRAINER_ISAIAH_3, TRAINER_ISAIAH_4, TRAINER_ISAIAH_5}, 0x0, 0x2b},
|
||||||
{{0x0171, 0x0172, 0x0173, 0x0174, 0x0175}, 0x0000, 0x0020},
|
{{TRAINER_MARIA_1, TRAINER_MARIA_2, TRAINER_MARIA_3, TRAINER_MARIA_4, TRAINER_MARIA_5}, 0x0, 0x20},
|
||||||
{{0x0166, 0x0168, 0x0169, 0x016a, 0x016b}, 0x0000, 0x0019},
|
{{TRAINER_ABIGAIL_1, TRAINER_ABIGAIL_2, TRAINER_ABIGAIL_3, TRAINER_ABIGAIL_4, TRAINER_ABIGAIL_5}, 0x0, 0x19},
|
||||||
{{0x016c, 0x016d, 0x016e, 0x016f, 0x0170}, 0x0000, 0x0020},
|
{{TRAINER_DYLAN_1, TRAINER_DYLAN_2, TRAINER_DYLAN_3, TRAINER_DYLAN_4, TRAINER_DYLAN_5}, 0x0, 0x20},
|
||||||
{{0x0182, 0x0184, 0x0185, 0x0186, 0x0187}, 0x0000, 0x002b},
|
{{TRAINER_KATELYN_1, TRAINER_KATELYN_2, TRAINER_KATELYN_3, TRAINER_KATELYN_4, TRAINER_KATELYN_5}, 0x0, 0x2b},
|
||||||
{{0x0161, 0x0162, 0x0163, 0x0164, 0x0165}, 0x0000, 0x0019},
|
{{TRAINER_BENJAMIN_1, TRAINER_BENJAMIN_2, TRAINER_BENJAMIN_3, TRAINER_BENJAMIN_4, TRAINER_BENJAMIN_5}, 0x0, 0x19},
|
||||||
{{0x0179, 0x0334, 0x0335, 0x0336, 0x0337}, 0x0000, 0x0029},
|
{{TRAINER_PABLO_1, TRAINER_PABLO_2, TRAINER_PABLO_3, TRAINER_PABLO_4, TRAINER_PABLO_5}, 0x0, 0x29},
|
||||||
{{0x0188, 0x0189, 0x018a, 0x018b, 0x018c}, 0x0018, 0x0001},
|
{{TRAINER_NICOLAS_1, TRAINER_NICOLAS_2, TRAINER_NICOLAS_3, TRAINER_NICOLAS_4, TRAINER_NICOLAS_5}, 0x18, 0x1},
|
||||||
{{0x0196, 0x0199, 0x019a, 0x019b, 0x019c}, 0x0000, 0x0023},
|
{{TRAINER_ROBERT_1, TRAINER_ROBERT_2, TRAINER_ROBERT_3, TRAINER_ROBERT_4, TRAINER_ROBERT_5}, 0x0, 0x23},
|
||||||
{{0x01a3, 0x01a5, 0x01a6, 0x01a7, 0x01a8}, 0x0000, 0x001c},
|
{{TRAINER_LAO_1, TRAINER_LAO_2, TRAINER_LAO_3, TRAINER_LAO_4, TRAINER_LAO_5}, 0x0, 0x1c},
|
||||||
{{0x01ab, 0x01ae, 0x01af, 0x01b0, 0x01b1}, 0x0000, 0x001e},
|
{{TRAINER_CYNDY_1, TRAINER_CYNDY_2, TRAINER_CYNDY_3, TRAINER_CYNDY_4, TRAINER_CYNDY_5}, 0x0, 0x1e},
|
||||||
{{0x01b2, 0x01b5, 0x01b6, 0x01b7, 0x01b8}, 0x0000, 0x001c},
|
{{TRAINER_MADELINE_1, TRAINER_MADELINE_2, TRAINER_MADELINE_3, TRAINER_MADELINE_4, TRAINER_MADELINE_5}, 0x0, 0x1c},
|
||||||
{{0x01c1, 0x01d1, 0x01d2, 0x01d3, 0x01d4}, 0x0000, 0x0027},
|
{{TRAINER_JENNY_1, TRAINER_JENNY_2, TRAINER_JENNY_3, TRAINER_JENNY_4, TRAINER_JENNY_5}, 0x0, 0x27},
|
||||||
{{0x01da, 0x01dd, 0x01de, 0x01df, 0x01e0}, 0x0018, 0x000d},
|
{{TRAINER_DIANA_1, TRAINER_DIANA_2, TRAINER_DIANA_3, TRAINER_DIANA_4, TRAINER_DIANA_5}, 0x18, 0xd},
|
||||||
{{0x01e1, 0x01e2, 0x01e7, 0x01e8, 0x01e9}, 0x0000, 0x0012},
|
{{TRAINER_AMY_AND_LIV_1, TRAINER_AMY_AND_LIV_2, TRAINER_AMY_AND_LIV_4, TRAINER_AMY_AND_LIV_5, TRAINER_AMY_AND_LIV_6}, 0x0, 0x12},
|
||||||
{{0x01ec, 0x01f1, 0x01f2, 0x01f3, 0x01f4}, 0x0000, 0x0028},
|
{{TRAINER_ERNEST_1, TRAINER_ERNEST_2, TRAINER_ERNEST_3, TRAINER_ERNEST_4, TRAINER_ERNEST_5}, 0x0, 0x28},
|
||||||
{{0x02e4, 0x0330, 0x0331, 0x0332, 0x0333}, 0x0000, 0x0017},
|
{{TRAINER_CORY_1, TRAINER_CORY_2, TRAINER_CORY_3, TRAINER_CORY_4, TRAINER_CORY_5}, 0x0, 0x17},
|
||||||
{{0x0200, 0x0203, 0x0204, 0x0205, 0x0206}, 0x0000, 0x0019},
|
{{TRAINER_EDWIN_1, TRAINER_EDWIN_2, TRAINER_EDWIN_3, TRAINER_EDWIN_4, TRAINER_EDWIN_5}, 0x0, 0x19},
|
||||||
{{0x0221, 0x0224, 0x0225, 0x0226, 0x0227}, 0x0000, 0x0020},
|
{{TRAINER_LYDIA_1, TRAINER_LYDIA_2, TRAINER_LYDIA_3, TRAINER_LYDIA_4, TRAINER_LYDIA_5}, 0x0, 0x20},
|
||||||
{{0x021a, 0x021d, 0x021e, 0x021f, 0x0220}, 0x0000, 0x0020},
|
{{TRAINER_ISAAC_1, TRAINER_ISAAC_2, TRAINER_ISAAC_3, TRAINER_ISAAC_4, TRAINER_ISAAC_5}, 0x0, 0x20},
|
||||||
{{0x0009, 0x0348, 0x0349, 0x034a, 0x034b}, 0x0018, 0x0011},
|
{{TRAINER_GABRIELLE_1, TRAINER_GABRIELLE_2, TRAINER_GABRIELLE_3, TRAINER_GABRIELLE_4, TRAINER_GABRIELLE_5}, 0x18, 0x11},
|
||||||
{{0x022f, 0x0232, 0x0233, 0x0234, 0x0235}, 0x0000, 0x0022},
|
{{TRAINER_CATHERINE_1, TRAINER_CATHERINE_2, TRAINER_CATHERINE_3, TRAINER_CATHERINE_4, TRAINER_CATHERINE_5}, 0x0, 0x22},
|
||||||
{{0x0228, 0x022b, 0x022c, 0x022d, 0x022e}, 0x0000, 0x0022},
|
{{TRAINER_JACKSON_1, TRAINER_JACKSON_2, TRAINER_JACKSON_3, TRAINER_JACKSON_4, TRAINER_JACKSON_5}, 0x0, 0x22},
|
||||||
{{0x025c, 0x025f, 0x0260, 0x0261, 0x0262}, 0x0000, 0x0013},
|
{{TRAINER_HALEY_1, TRAINER_HALEY_2, TRAINER_HALEY_3, TRAINER_HALEY_4, TRAINER_HALEY_5}, 0x0, 0x13},
|
||||||
{{0x026d, 0x026e, 0x026f, 0x0270, 0x0271}, 0x0018, 0x000b},
|
{{TRAINER_JAMES_1, TRAINER_JAMES_2, TRAINER_JAMES_3, TRAINER_JAMES_4, TRAINER_JAMES_5}, 0x18, 0xb},
|
||||||
{{0x0273, 0x027c, 0x027d, 0x027e, 0x027f}, 0x0000, 0x001b},
|
{{TRAINER_TRENT_1, TRAINER_TRENT_2, TRAINER_TRENT_3, TRAINER_TRENT_4, TRAINER_TRENT_5}, 0x0, 0x1b},
|
||||||
{{0x0001, 0x0344, 0x0345, 0x0346, 0x0347}, 0x0018, 0x000c},
|
{{TRAINER_SAWYER_1, TRAINER_SAWYER_2, TRAINER_SAWYER_3, TRAINER_SAWYER_4, TRAINER_SAWYER_5}, 0x18, 0xc},
|
||||||
{{0x0282, 0x0283, 0x0284, 0x0285, 0x0286}, 0x0018, 0x003e},
|
{{TRAINER_KIRA_AND_DAN_1, TRAINER_KIRA_AND_DAN_2, TRAINER_KIRA_AND_DAN_3, TRAINER_KIRA_AND_DAN_4, TRAINER_KIRA_AND_DAN_5}, 0x18, 0x3e},
|
||||||
{{0x0291, 0x0292, 0x0293, 0x0294, 0x0294}, 0x0018, 0x002b},
|
{{TRAINER_WALLY_3, 0x292, 0x293, 0x294, 0x294}, 0x18, 0x2b},
|
||||||
{{0x0109, 0x0302, 0x0303, 0x0304, 0x0305}, 0x0000, 0x0003},
|
{{TRAINER_ROXANNE_1, TRAINER_ROXANNE_2, TRAINER_ROXANNE_3, TRAINER_ROXANNE_4, TRAINER_ROXANNE_5}, 0x0, 0x3},
|
||||||
{{0x010a, 0x0306, 0x0307, 0x0308, 0x0309}, 0x0000, 0x000b},
|
{{TRAINER_BRAWLY_1, TRAINER_BRAWLY_2, TRAINER_BRAWLY_3, TRAINER_BRAWLY_4, TRAINER_BRAWLY_5}, 0x0, 0xb},
|
||||||
{{0x010b, 0x030a, 0x030b, 0x030c, 0x030d}, 0x0000, 0x0002},
|
{{TRAINER_WATTSON_1, TRAINER_WATTSON_2, TRAINER_WATTSON_3, TRAINER_WATTSON_4, TRAINER_WATTSON_5}, 0x0, 0x2},
|
||||||
{{0x010c, 0x030e, 0x030f, 0x0310, 0x0311}, 0x0000, 0x000c},
|
{{TRAINER_FLANNERY_1, TRAINER_FLANNERY_2, TRAINER_FLANNERY_3, TRAINER_FLANNERY_4, TRAINER_FLANNERY_5}, 0x0, 0xc},
|
||||||
{{0x010d, 0x0312, 0x0313, 0x0314, 0x0315}, 0x0000, 0x0000},
|
{{TRAINER_NORMAN_1, TRAINER_NORMAN_2, TRAINER_NORMAN_3, TRAINER_NORMAN_4, TRAINER_NORMAN_5}, 0x0, 0x0},
|
||||||
{{0x010e, 0x0316, 0x0317, 0x0318, 0x0319}, 0x0000, 0x0004},
|
{{TRAINER_WINONA_1, TRAINER_WINONA_2, TRAINER_WINONA_3, TRAINER_WINONA_4, TRAINER_WINONA_5}, 0x0, 0x4},
|
||||||
{{0x010f, 0x031a, 0x031b, 0x031c, 0x031d}, 0x0000, 0x0006},
|
{{TRAINER_TATE_AND_LIZA_1, TRAINER_TATE_AND_LIZA_2, TRAINER_TATE_AND_LIZA_3, TRAINER_TATE_AND_LIZA_4, TRAINER_TATE_AND_LIZA_5}, 0x0, 0x6},
|
||||||
{{0x0110, 0x031e, 0x031f, 0x0320, 0x0321}, 0x0000, 0x0007},
|
{{TRAINER_JUAN_1, TRAINER_JUAN_2, TRAINER_JUAN_3, TRAINER_JUAN_4, TRAINER_JUAN_5}, 0x0, 0x7},
|
||||||
{{0x0105, 0x0105, 0x0105, 0x0105, 0x0105}, 0x0000, 0x0008},
|
{{TRAINER_SIDNEY, TRAINER_SIDNEY, TRAINER_SIDNEY, TRAINER_SIDNEY, TRAINER_SIDNEY}, 0x0, 0x8},
|
||||||
{{0x0106, 0x0106, 0x0106, 0x0106, 0x0106}, 0x0000, 0x0008},
|
{{TRAINER_PHOEBE, TRAINER_PHOEBE, TRAINER_PHOEBE, TRAINER_PHOEBE, TRAINER_PHOEBE}, 0x0, 0x8},
|
||||||
{{0x0107, 0x0107, 0x0107, 0x0107, 0x0107}, 0x0000, 0x0008},
|
{{TRAINER_GLACIA, TRAINER_GLACIA, TRAINER_GLACIA, TRAINER_GLACIA, TRAINER_GLACIA}, 0x0, 0x8},
|
||||||
{{0x0108, 0x0108, 0x0108, 0x0108, 0x0108}, 0x0000, 0x0008},
|
{{TRAINER_DRAKE, TRAINER_DRAKE, TRAINER_DRAKE, TRAINER_DRAKE, TRAINER_DRAKE}, 0x0, 0x8},
|
||||||
{{0x014f, 0x014f, 0x014f, 0x014f, 0x014f}, 0x0000, 0x0008},
|
{{TRAINER_WALLACE, TRAINER_WALLACE, TRAINER_WALLACE, TRAINER_WALLACE, TRAINER_WALLACE}, 0x0, 0x8},
|
||||||
};
|
};
|
||||||
|
|
||||||
static const u16 sBadgeFlags[8] =
|
static const u16 sBadgeFlags[8] =
|
||||||
|
@ -1,39 +1,47 @@
|
|||||||
|
|
||||||
// Includes
|
|
||||||
#include "global.h"
|
#include "global.h"
|
||||||
#include "constants/flags.h"
|
#include "constants/flags.h"
|
||||||
#include "random.h"
|
#include "random.h"
|
||||||
#include "event_data.h"
|
#include "event_data.h"
|
||||||
#include "battle_setup.h"
|
#include "battle_setup.h"
|
||||||
|
#include "trainer_rematch.h"
|
||||||
|
|
||||||
// Static type declarations
|
static void sub_81DA5D4(const u16 *data, size_t size, u32 a2);
|
||||||
|
static s32 sub_81DA6CC(u32 trainerIdx);
|
||||||
|
|
||||||
// Static RAM declarations
|
static const u16 GymLeaderRematches_AfterNewMauville[] = {
|
||||||
|
REMATCH_ROXANNE,
|
||||||
|
REMATCH_BRAWLY,
|
||||||
|
REMATCH_WATTSON,
|
||||||
|
REMATCH_FLANNERY,
|
||||||
|
REMATCH_NORMAN,
|
||||||
|
REMATCH_WINONA,
|
||||||
|
REMATCH_TATE_AND_LIZA,
|
||||||
|
REMATCH_JUAN
|
||||||
|
};
|
||||||
|
|
||||||
// Static ROM declarations
|
static const u16 GymLeaderRematches_BeforeNewMauville[] = {
|
||||||
|
REMATCH_ROXANNE,
|
||||||
void sub_81DA5D4(const u16 *data, size_t size, u32 a2);
|
REMATCH_BRAWLY,
|
||||||
s32 sub_81DA6CC(u32 trainerIdx);
|
// Wattson isn't available at this time
|
||||||
|
REMATCH_FLANNERY,
|
||||||
// .rodata
|
REMATCH_NORMAN,
|
||||||
|
REMATCH_WINONA,
|
||||||
const u16 gUnknown_0862AD34[] = {0x41, 0x42, 0x43, 0x44, 0x45, 0x46, 0x47, 0x48};
|
REMATCH_TATE_AND_LIZA,
|
||||||
const u16 gUnknown_0862AD44[] = {0x41, 0x42, 0x44, 0x45, 0x46, 0x47, 0x48};
|
REMATCH_JUAN
|
||||||
|
};
|
||||||
// .text
|
|
||||||
|
|
||||||
void sub_81DA57C(void)
|
void sub_81DA57C(void)
|
||||||
{
|
{
|
||||||
if (FlagGet(FLAG_SYS_GAME_CLEAR) && (Random() % 100) <= 30)
|
if (FlagGet(FLAG_SYS_GAME_CLEAR) && (Random() % 100) <= 30)
|
||||||
{
|
{
|
||||||
if (FlagGet(FLAG_0x05B))
|
if (FlagGet(FLAG_0x05B))
|
||||||
sub_81DA5D4(gUnknown_0862AD34, ARRAY_COUNT(gUnknown_0862AD34), 5);
|
sub_81DA5D4(GymLeaderRematches_AfterNewMauville, ARRAY_COUNT(GymLeaderRematches_AfterNewMauville), 5);
|
||||||
else
|
else
|
||||||
sub_81DA5D4(gUnknown_0862AD44, ARRAY_COUNT(gUnknown_0862AD44), 1);
|
sub_81DA5D4(GymLeaderRematches_BeforeNewMauville, ARRAY_COUNT(GymLeaderRematches_BeforeNewMauville), 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void sub_81DA5D4(const u16 *data, size_t size, u32 a2)
|
static void sub_81DA5D4(const u16 *data, size_t size, u32 a2)
|
||||||
{
|
{
|
||||||
s32 r6 = 0;
|
s32 r6 = 0;
|
||||||
s32 r8 = 5;
|
s32 r8 = 5;
|
||||||
@ -83,7 +91,7 @@ void sub_81DA5D4(const u16 *data, size_t size, u32 a2)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
s32 sub_81DA6CC(u32 trainerIdx)
|
static s32 sub_81DA6CC(u32 trainerIdx)
|
||||||
{
|
{
|
||||||
s32 i;
|
s32 i;
|
||||||
for (i = 0; i < 5; i++)
|
for (i = 0; i < 5; i++)
|
||||||
|
Loading…
Reference in New Issue
Block a user