Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Rotom Catalog and Zygarde Cube #3284

Merged
merged 30 commits into from
Nov 13, 2023
Merged
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
098d52a
doesn't work
kittenchilly Sep 5, 2023
7d72aa2
more tries
kittenchilly Sep 5, 2023
93c5abc
Finish rotom catalog!
kittenchilly Sep 6, 2023
1f3465d
Correct rotom form move learning
kittenchilly Sep 6, 2023
e13cbec
Finish Zygarde cube
kittenchilly Sep 6, 2023
217d506
Clean up
kittenchilly Sep 6, 2023
2d8aea8
Oops
kittenchilly Sep 6, 2023
625be57
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Sep 7, 2023
da6a215
Prevent using registered form changing items
kittenchilly Sep 7, 2023
1bc308b
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Sep 8, 2023
73ed744
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Sep 10, 2023
6716cf2
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Sep 11, 2023
95f6b02
Merge branch 'upcoming' into catalog-cube
kittenchilly Sep 20, 2023
27a2ec6
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Oct 2, 2023
dac90d3
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Oct 7, 2023
bd5c35e
Apply suggestions from code review
kittenchilly Oct 15, 2023
59e549d
Merge branch 'upcoming' into catalog-cube
kittenchilly Oct 15, 2023
d21fedf
Update items.h
kittenchilly Oct 15, 2023
df76ad0
Update party_menu.c
kittenchilly Oct 15, 2023
3d6c27e
Update party_menu.c
kittenchilly Oct 15, 2023
3437026
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Oct 15, 2023
ac195a4
Merge remote-tracking branch 'upstream/upcoming' into catalog-cube
kittenchilly Oct 16, 2023
22f0803
Merge branch 'upcoming' into catalog-cube
kittenchilly Oct 23, 2023
08cb3d0
Update form_change_types.h
kittenchilly Oct 23, 2023
133c773
Merge branch 'upcoming' into catalog-cube
kittenchilly Oct 30, 2023
bae0eb7
Merge branch 'upcoming' into catalog-cube
AsparagusEduardo Oct 30, 2023
6f934f1
Merge branch 'upcoming' into catalog-cube
kittenchilly Oct 31, 2023
8d520c0
Merge branch 'upcoming' into catalog-cube
kittenchilly Nov 13, 2023
ba7c953
Apply suggestions from code review
kittenchilly Nov 13, 2023
b46d8e5
Fix DoesMonHaveAnyMoves
kittenchilly Nov 13, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions include/constants/form_change_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,6 @@
// param1: item to hold.
#define FORM_CHANGE_BATTLE_ULTRA_BURST 16

#define FORM_CHANGE_ITEM_USE_MULTICHOICE 17

#endif // GUARD_CONSTANTS_FORM_CHANGE_TYPES_H
11 changes: 7 additions & 4 deletions include/constants/party_menu.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
#define PARTY_MSG_DO_WHAT_WITH_ITEM 24
#define PARTY_MSG_DO_WHAT_WITH_MAIL 25
#define PARTY_MSG_ALREADY_HOLDING_ONE 26
#define PARTY_MSG_WHICH_APPLIANCE 27
#define PARTY_MSG_NONE 127

// IDs for DisplayPartyPokemonDescriptionText, to display a message in the party pokemon's box
Expand All @@ -96,9 +97,11 @@
#define PARTYBOX_DESC_HAVE 11
#define PARTYBOX_DESC_DONT_HAVE 12

#define SELECTWINDOW_ACTIONS 0
#define SELECTWINDOW_ITEM 1
#define SELECTWINDOW_MAIL 2
#define SELECTWINDOW_MOVES 3
#define SELECTWINDOW_ACTIONS 0
#define SELECTWINDOW_ITEM 1
#define SELECTWINDOW_MAIL 2
#define SELECTWINDOW_MOVES 3
#define SELECTWINDOW_CATALOG 4
#define SELECTWINDOW_ZYGARDECUBE 5

#endif // GUARD_CONSTANTS_PARTY_MENU_H
1 change: 1 addition & 0 deletions include/item_menu.h
Original file line number Diff line number Diff line change
Expand Up @@ -107,5 +107,6 @@ void UpdatePocketItemList(u8 pocketId);
void DisplayItemMessage(u8 taskId, u8 fontId, const u8 *str, void ( *callback)(u8 taskId));
void DisplayItemMessageOnField(u8 taskId, const u8 *src, TaskFunc callback);
void CloseItemMessage(u8 taskId);
void ItemMenu_RotomCatalog(u8 taskId);

#endif //GUARD_ITEM_MENU_H
2 changes: 2 additions & 0 deletions include/item_use.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ void ItemUseOutOfBattle_Berry(u8);
void ItemUseOutOfBattle_EnigmaBerry(u8);
void ItemUseOutOfBattle_FormChange(u8);
void ItemUseOutOfBattle_FormChange_ConsumedOnUse(u8);
void ItemUseOutOfBattle_RotomCatalog(u8);
void ItemUseOutOfBattle_ZygardeCube(u8);
void ItemUseOutOfBattle_Honey(u8);
void ItemUseOutOfBattle_CannotUse(u8);
void ItemUseOutOfBattle_ExpShare(u8);
Expand Down
2 changes: 2 additions & 0 deletions include/party_menu.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ void ItemUseCB_SacredAsh(u8 taskId, TaskFunc task);
void ItemUseCB_EvolutionStone(u8 taskId, TaskFunc task);
void ItemUseCB_FormChange(u8 taskId, TaskFunc task);
void ItemUseCB_FormChange_ConsumedOnUse(u8 taskId, TaskFunc task);
void ItemUseCB_RotomCatalog(u8 taskId, TaskFunc task);
void ItemUseCB_ZygardeCube(u8 taskId, TaskFunc task);
const u8* GetItemEffect(u16 item);
u8 GetItemEffectType(u16 item);
void CB2_PartyMenuFromStartMenu(void);
Expand Down
14 changes: 14 additions & 0 deletions include/strings.h
Original file line number Diff line number Diff line change
Expand Up @@ -1319,6 +1319,19 @@ extern const u8 CableClub_Text_YouMayBattleHere[];
extern const u8 CableClub_Text_CanMixRecords[];
extern const u8 CableClub_Text_CanMakeBerryPowder[];

// Rotom Catalog text
extern const u8 gText_LightBulb[];
extern const u8 gText_MicrowaveOven[];
extern const u8 gText_WashingMachine[];
extern const u8 gText_Refrigerator[];
extern const u8 gText_ElectricFan[];
extern const u8 gText_LawnMower[];
extern const u8 gText_Exit[];

// Zygarde Cube text
extern const u8 gText_ChangeForm[];
extern const u8 gText_ChangeAbility[];

// Frontier records.
extern const u8 gText_WinStreak[];
extern const u8 gText_Record[];
Expand Down Expand Up @@ -2130,6 +2143,7 @@ extern const u8 gText_BoostPp[];
extern const u8 gText_DoWhatWithItem[];
extern const u8 gText_DoWhatWithMail[];
extern const u8 gText_AlreadyHoldingOne[];
extern const u8 gText_WhichAppliance[];
extern const u8 gText_NoUse[];
extern const u8 gText_Able[];
extern const u8 gText_First_PM[];
Expand Down
8 changes: 4 additions & 4 deletions src/data/items.h
Original file line number Diff line number Diff line change
Expand Up @@ -8510,8 +8510,8 @@ const struct Item gItems[] =
.importance = 1,
.description = sRotomCatalogDesc,
.pocket = POCKET_KEY_ITEMS,
.type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse, // Todo
.type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_RotomCatalog,
},

[ITEM_GRACIDEA] =
Expand Down Expand Up @@ -8551,8 +8551,8 @@ const struct Item gItems[] =
.importance = 1,
.description = sZygardeCubeDesc,
.pocket = POCKET_KEY_ITEMS,
.type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse, // Todo
.type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ZygardeCube, // Todo
kittenchilly marked this conversation as resolved.
Show resolved Hide resolved
},

[ITEM_PRISON_BOTTLE] =
Expand Down
61 changes: 60 additions & 1 deletion src/data/party_menu.h
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,17 @@ static const struct WindowTemplate sAlreadyHoldingOneMsgWindowTemplate =
.baseBlock = 0x299,
};

static const struct WindowTemplate sOrderWhichApplianceMsgWindowTemplate =
{
.bg = 2,
.tilemapLeft = 1,
.tilemapTop = 15,
.width = 14,
.height = 4,
.paletteNum = 15,
.baseBlock = 0x299,
};

static const struct WindowTemplate sItemGiveTakeWindowTemplate =
{
.bg = 2,
Expand Down Expand Up @@ -515,6 +526,28 @@ static const struct WindowTemplate sMoveSelectWindowTemplate =
.baseBlock = 0x2E9,
};

static const struct WindowTemplate sCatalogSelectWindowTemplate =
{
.bg = 2,
.tilemapLeft = 17,
.tilemapTop = 5,
.width = 12,
.height = 14,
.paletteNum = 14,
.baseBlock = 0x2E9,
};

static const struct WindowTemplate sZygardeCubeSelectWindowTemplate =
{
.bg = 2,
.tilemapLeft = 18,
.tilemapTop = 13,
.width = 11,
.height = 6,
.paletteNum = 14,
.baseBlock = 0x2E9,
};

static const struct WindowTemplate sPartyMenuYesNoWindowTemplate =
{
.bg = 2,
Expand Down Expand Up @@ -624,6 +657,7 @@ static const u8 *const sActionStringTable[] =
[PARTY_MSG_DO_WHAT_WITH_ITEM] = gText_DoWhatWithItem,
[PARTY_MSG_DO_WHAT_WITH_MAIL] = gText_DoWhatWithMail,
[PARTY_MSG_ALREADY_HOLDING_ONE] = gText_AlreadyHoldingOne,
[PARTY_MSG_WHICH_APPLIANCE] = gText_WhichAppliance,
};

static const u8 *const sDescriptionStringTable[] =
Expand Down Expand Up @@ -676,6 +710,14 @@ struct
[MENU_TRADE1] = {gText_Trade4, CursorCb_Trade1},
[MENU_TRADE2] = {gText_Trade4, CursorCb_Trade2},
[MENU_TOSS] = {gMenuText_Toss, CursorCb_Toss},
[MENU_CATALOG_BULB] = {gText_LightBulb, CursorCb_CatalogBulb},
[MENU_CATALOG_OVEN] = {gText_MicrowaveOven, CursorCb_CatalogOven},
[MENU_CATALOG_WASHING] = {gText_WashingMachine, CursorCb_CatalogWashing},
[MENU_CATALOG_FRIDGE] = {gText_Refrigerator, CursorCb_CatalogFridge},
[MENU_CATALOG_FAN] = {gText_ElectricFan, CursorCb_CatalogFan},
[MENU_CATALOG_MOWER] = {gText_LawnMower, CursorCb_CatalogMower},
[MENU_CHANGE_FORM] = {gText_ChangeForm, CursorCb_ChangeForm},
[MENU_CHANGE_ABILITY] = {gText_ChangeAbility, CursorCb_ChangeAbility},
[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},
Expand Down Expand Up @@ -705,6 +747,10 @@ static const u8 sPartyMenuAction_RegisterSummaryCancel[] = {MENU_REGISTER, MENU_
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};
static const u8 sPartyMenuAction_RotomCatalog[] = {MENU_CATALOG_BULB, MENU_CATALOG_OVEN, MENU_CATALOG_WASHING, MENU_CATALOG_FRIDGE, MENU_CATALOG_FAN, MENU_CATALOG_MOWER, MENU_CANCEL1};
static const u8 sPartyMenuAction_ZygardeCube[] = {MENU_CHANGE_FORM, MENU_CHANGE_ABILITY, MENU_CANCEL1};



static const u8 *const sPartyMenuActions[] =
{
Expand All @@ -722,6 +768,8 @@ static const u8 *const sPartyMenuActions[] =
[ACTIONS_TRADE] = sPartyMenuAction_TradeSummaryCancel1,
[ACTIONS_SPIN_TRADE] = sPartyMenuAction_TradeSummaryCancel2,
[ACTIONS_TAKEITEM_TOSS] = sPartyMenuAction_TakeItemTossCancel,
[ACTIONS_ROTOM_CATALOG] = sPartyMenuAction_RotomCatalog,
[ACTIONS_ZYGARDE_CUBE] = sPartyMenuAction_ZygardeCube,
};

static const u8 sPartyMenuActionCounts[] =
Expand All @@ -739,7 +787,9 @@ static const u8 sPartyMenuActionCounts[] =
[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)
[ACTIONS_TAKEITEM_TOSS] = ARRAY_COUNT(sPartyMenuAction_TakeItemTossCancel),
[ACTIONS_ROTOM_CATALOG] = ARRAY_COUNT(sPartyMenuAction_RotomCatalog),
[ACTIONS_ZYGARDE_CUBE] = ARRAY_COUNT(sPartyMenuAction_ZygardeCube),
};

static const u16 sFieldMoves[FIELD_MOVES_COUNT + 1] =
Expand Down Expand Up @@ -1102,3 +1152,12 @@ static const u8 *const sUnused_StatStrings[] =
gText_SpDef4,
gText_Speed2
};

static const u16 sRotomFormChangeMoves[5] =
{
MOVE_HYDRO_PUMP,
MOVE_BLIZZARD,
MOVE_OVERHEAT,
MOVE_AIR_SLASH,
MOVE_LEAF_STORM,
};
12 changes: 10 additions & 2 deletions src/data/pokemon/form_change_table_pointers.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,12 @@ const struct FormChange *const gFormChangeTablePointers[NUM_SPECIES] =
[SPECIES_ABOMASNOW_MEGA] = sAbomasnowFormChangeTable,
[SPECIES_GALLADE] = sGalladeFormChangeTable,
[SPECIES_GALLADE_MEGA] = sGalladeFormChangeTable,
[SPECIES_ROTOM] = sRotomFormChangeTable,
[SPECIES_ROTOM_HEAT] = sRotomFormChangeTable,
[SPECIES_ROTOM_WASH] = sRotomFormChangeTable,
[SPECIES_ROTOM_FROST] = sRotomFormChangeTable,
[SPECIES_ROTOM_FAN] = sRotomFormChangeTable,
[SPECIES_ROTOM_MOW] = sRotomFormChangeTable,
[SPECIES_DIALGA] = sDialgaFormChangeTable,
[SPECIES_DIALGA_ORIGIN] = sDialgaFormChangeTable,
[SPECIES_PALKIA] = sPalkiaFormChangeTable,
Expand Down Expand Up @@ -161,9 +167,11 @@ const struct FormChange *const gFormChangeTablePointers[NUM_SPECIES] =
[SPECIES_AEGISLASH_BLADE] = sAegislashFormChangeTable,
[SPECIES_XERNEAS] = sXerneasFormChangeTable,
[SPECIES_XERNEAS_ACTIVE] = sXerneasFormChangeTable,
[SPECIES_ZYGARDE_10_POWER_CONSTRUCT] = sZygardePowerConstructFormChangeTable,
[SPECIES_ZYGARDE] = sZygardeFormChangeTable,
[SPECIES_ZYGARDE_10] = sZygarde10FormChangeTable,
[SPECIES_ZYGARDE_50_POWER_CONSTRUCT] = sZygardePowerConstructFormChangeTable,
[SPECIES_ZYGARDE_COMPLETE] = sZygardePowerConstructFormChangeTable,
[SPECIES_ZYGARDE_10_POWER_CONSTRUCT] = sZygarde10PowerConstructFormChangeTable,
[SPECIES_ZYGARDE_COMPLETE] = sZygardeCompleteFormChangeTable,
[SPECIES_DIANCIE] = sDiancieFormChangeTable,
[SPECIES_DIANCIE_MEGA] = sDiancieFormChangeTable,
[SPECIES_HOOPA] = sHoopaFormChangeTable,
Expand Down
35 changes: 35 additions & 0 deletions src/data/pokemon/form_change_tables.h
Original file line number Diff line number Diff line change
Expand Up @@ -279,6 +279,16 @@ static const struct FormChange sGalladeFormChangeTable[] = {
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sRotomFormChangeTable[] = {
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ROTOM, ITEM_ROTOM_CATALOG, 0},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ROTOM_HEAT, ITEM_ROTOM_CATALOG, 1},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ROTOM_WASH, ITEM_ROTOM_CATALOG, 2},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ROTOM_FROST, ITEM_ROTOM_CATALOG, 3},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ROTOM_FAN, ITEM_ROTOM_CATALOG, 4},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ROTOM_MOW, ITEM_ROTOM_CATALOG, 5},
kittenchilly marked this conversation as resolved.
Show resolved Hide resolved
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sDialgaFormChangeTable[] = {
{FORM_CHANGE_ITEM_HOLD, SPECIES_DIALGA, ITEM_NONE},
{FORM_CHANGE_ITEM_HOLD, SPECIES_DIALGA_ORIGIN, ITEM_ADAMANT_CRYSTAL},
Expand Down Expand Up @@ -428,8 +438,33 @@ static const struct FormChange sXerneasFormChangeTable[] = {
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sZygardeFormChangeTable[] = {
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE_10, ITEM_ZYGARDE_CUBE, 0},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE_50_POWER_CONSTRUCT, ITEM_ZYGARDE_CUBE, 1},
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sZygarde10FormChangeTable[] = {
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE, ITEM_ZYGARDE_CUBE, 0},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE_10_POWER_CONSTRUCT, ITEM_ZYGARDE_CUBE, 1},
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sZygardePowerConstructFormChangeTable[] = {
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE_10_POWER_CONSTRUCT, ITEM_ZYGARDE_CUBE, 0},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE, ITEM_ZYGARDE_CUBE, 1},
{FORM_CHANGE_BATTLE_HP_PERCENT, SPECIES_ZYGARDE_COMPLETE, ABILITY_POWER_CONSTRUCT, HP_LOWER_EQ_THAN, 50},
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sZygarde10PowerConstructFormChangeTable[] = {
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE_50_POWER_CONSTRUCT, ITEM_ZYGARDE_CUBE, 0},
{FORM_CHANGE_ITEM_USE_MULTICHOICE, SPECIES_ZYGARDE_10, ITEM_ZYGARDE_CUBE, 1},
{FORM_CHANGE_BATTLE_HP_PERCENT, SPECIES_ZYGARDE_COMPLETE, ABILITY_POWER_CONSTRUCT, HP_LOWER_EQ_THAN, 50},
{FORM_CHANGE_TERMINATOR},
};

static const struct FormChange sZygardeCompleteFormChangeTable[] = {
{FORM_CHANGE_FAINT},
{FORM_CHANGE_END_BATTLE},
{FORM_CHANGE_TERMINATOR},
Expand Down
54 changes: 48 additions & 6 deletions src/item_use.c
Original file line number Diff line number Diff line change
Expand Up @@ -1310,16 +1310,58 @@ void ItemUseOutOfBattle_EnigmaBerry(u8 taskId)

void ItemUseOutOfBattle_FormChange(u8 taskId)
{
gItemUseCB = ItemUseCB_FormChange;
gTasks[taskId].data[0] = FALSE;
SetUpItemUseCallback(taskId);
if (!gTasks[taskId].tUsingRegisteredKeyItem)
{
gItemUseCB = ItemUseCB_FormChange;
gTasks[taskId].data[0] = FALSE;
SetUpItemUseOnFieldCallback(taskId);
}
else
{
DisplayDadsAdviceCannotUseItemMessage(taskId, gTasks[taskId].tUsingRegisteredKeyItem); //todo
mrgriffin marked this conversation as resolved.
Show resolved Hide resolved
kittenchilly marked this conversation as resolved.
Show resolved Hide resolved
}
}

void ItemUseOutOfBattle_FormChange_ConsumedOnUse(u8 taskId)
{
gItemUseCB = ItemUseCB_FormChange_ConsumedOnUse;
gTasks[taskId].data[0] = TRUE;
SetUpItemUseCallback(taskId);
if (!gTasks[taskId].tUsingRegisteredKeyItem)
{
gItemUseCB = ItemUseCB_FormChange_ConsumedOnUse;
gTasks[taskId].data[0] = TRUE;
SetUpItemUseOnFieldCallback(taskId);
}
else
{
DisplayDadsAdviceCannotUseItemMessage(taskId, gTasks[taskId].tUsingRegisteredKeyItem); //todo
kittenchilly marked this conversation as resolved.
Show resolved Hide resolved
}
}

void ItemUseOutOfBattle_RotomCatalog(u8 taskId)
{
if (!gTasks[taskId].tUsingRegisteredKeyItem)
{
gItemUseCB = ItemUseCB_RotomCatalog;
gTasks[taskId].data[0] = TRUE;
SetUpItemUseOnFieldCallback(taskId);
}
else
{
DisplayDadsAdviceCannotUseItemMessage(taskId, gTasks[taskId].tUsingRegisteredKeyItem); //todo
kittenchilly marked this conversation as resolved.
Show resolved Hide resolved
}
}

void ItemUseOutOfBattle_ZygardeCube(u8 taskId)
{
if (!gTasks[taskId].tUsingRegisteredKeyItem)
{
gItemUseCB = ItemUseCB_ZygardeCube;
gTasks[taskId].data[0] = TRUE;
SetUpItemUseOnFieldCallback(taskId);
}
else
{
DisplayDadsAdviceCannotUseItemMessage(taskId, gTasks[taskId].tUsingRegisteredKeyItem); //todo
kittenchilly marked this conversation as resolved.
Show resolved Hide resolved
}
}

void Task_UseHoneyOnField(u8 taskId)
Expand Down
Loading
Loading