summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-xsrc/battle_anim_effects_3.c1
-rw-r--r--src/battle_anim_flying.c1
-rw-r--r--src/battle_anim_mons.c7
-rw-r--r--src/battle_anim_normal.c2
-rwxr-xr-xsrc/battle_anim_throw.c2
-rw-r--r--src/battle_anim_water.c2
-rw-r--r--src/battle_controller_link_opponent.c1
-rw-r--r--src/battle_controller_opponent.c1
-rw-r--r--src/battle_controller_recorded_opponent.c1
-rw-r--r--src/battle_controller_safari.c2
-rw-r--r--src/battle_interface.c1
-rw-r--r--src/battle_main.c2
-rw-r--r--src/berry_blender.c2
-rwxr-xr-xsrc/berry_crush.c6
-rw-r--r--src/cable_club.c3
-rw-r--r--src/contest.c1
-rw-r--r--src/credits.c4
-rw-r--r--src/data/items.h1277
-rw-r--r--src/decompress.c6
-rw-r--r--src/decoration.c2
-rw-r--r--src/diploma.c2
-rw-r--r--src/easy_chat.c1
-rwxr-xr-xsrc/ereader_screen.c1
-rw-r--r--src/event_object_movement.c1
-rw-r--r--src/evolution_scene.c1
-rwxr-xr-xsrc/faraway_island.c1
-rw-r--r--src/fieldmap.c2
-rw-r--r--src/fldeff_cut.c1
-rw-r--r--src/fldeff_escalator.c2
-rw-r--r--src/frontier_util.c4
-rw-r--r--src/intro.c3
-rw-r--r--src/item.c4
-rwxr-xr-xsrc/item_menu.c7
-rwxr-xr-xsrc/item_use.c31
-rw-r--r--src/librfu_rfu.c1
-rw-r--r--src/mail.c10
-rw-r--r--src/main_menu.c4
-rw-r--r--src/match_call.c1
-rw-r--r--src/mauville_old_man.c1
-rw-r--r--src/mevent_server.c4
-rw-r--r--src/minigame_countdown.c1
-rw-r--r--src/overworld.c1
-rw-r--r--src/palette.c2
-rwxr-xr-xsrc/party_menu.c2
-rw-r--r--src/player_pc.c5
-rw-r--r--src/pokeblock_feed.c1
-rw-r--r--src/pokedex.c7
-rwxr-xr-xsrc/pokedex_area_screen.c1
-rw-r--r--src/pokemon.c5
-rw-r--r--src/pokemon_icon.c2
-rw-r--r--src/pokemon_storage_system.c2
-rw-r--r--src/pokenav_conditions_3.c2
-rw-r--r--src/pokenav_menu_handler_2.c2
-rw-r--r--src/pokenav_ribbons_1.c2
-rw-r--r--src/record_mixing.c1
-rw-r--r--src/region_map.c2
-rw-r--r--src/save_failed_screen.c4
-rw-r--r--src/script.c2
-rw-r--r--src/secret_base.c2
-rwxr-xr-xsrc/shop.c1
-rw-r--r--src/starter_choose.c1
-rw-r--r--src/tv.c5
62 files changed, 524 insertions, 935 deletions
diff --git a/src/battle_anim_effects_3.c b/src/battle_anim_effects_3.c
index 9e50a8477..f73a2dee7 100755
--- a/src/battle_anim_effects_3.c
+++ b/src/battle_anim_effects_3.c
@@ -4947,7 +4947,6 @@ static void AnimTask_OdorSleuthMovementWaitFinish(u8 taskId)
static void MoveOdorSleuthClone(struct Sprite *sprite)
{
- int zero = 0;
if (++sprite->data[1] > 1)
{
sprite->data[1] = 0;
diff --git a/src/battle_anim_flying.c b/src/battle_anim_flying.c
index f8d47f4ec..7d96fed8c 100644
--- a/src/battle_anim_flying.c
+++ b/src/battle_anim_flying.c
@@ -708,7 +708,6 @@ static void sub_810E520(struct Sprite *sprite)
}
}
data->unk0_0d = 0;
- data->unk2;
}
data->unk0_1 = 0;
break;
diff --git a/src/battle_anim_mons.c b/src/battle_anim_mons.c
index d626e1604..0c3d4ea47 100644
--- a/src/battle_anim_mons.c
+++ b/src/battle_anim_mons.c
@@ -16,13 +16,6 @@
#include "util.h"
#include "constants/battle_anim.h"
-#define GET_UNOWN_LETTER(personality) (( \
- (((personality & 0x03000000) >> 24) << 6) \
- | (((personality & 0x00030000) >> 16) << 4) \
- | (((personality & 0x00000300) >> 8) << 2) \
- | (((personality & 0x00000003) >> 0) << 0) \
-) % 28)
-
#define IS_DOUBLE_BATTLE() ((gBattleTypeFlags & BATTLE_TYPE_DOUBLE))
extern const struct OamData gOamData_AffineNormal_ObjNormal_64x64;
diff --git a/src/battle_anim_normal.c b/src/battle_anim_normal.c
index f7df9a4a9..e32ff3151 100644
--- a/src/battle_anim_normal.c
+++ b/src/battle_anim_normal.c
@@ -564,8 +564,6 @@ static void AnimTask_BlendColorCycleExcludeLoop(u8 taskId)
// See AnimTask_BlendColorCycle. Same, but selects palette by ANIM_TAG_*
void AnimTask_BlendColorCycleByTag(u8 taskId)
{
- u8 paletteIndex;
-
gTasks[taskId].tPalTag = gBattleAnimArgs[0];
gTasks[taskId].tDelay = gBattleAnimArgs[1];
gTasks[taskId].tNumBlends = gBattleAnimArgs[2];
diff --git a/src/battle_anim_throw.c b/src/battle_anim_throw.c
index fef301326..0da766036 100755
--- a/src/battle_anim_throw.c
+++ b/src/battle_anim_throw.c
@@ -1551,8 +1551,6 @@ static void SpriteCB_Ball_Block_Step(struct Sprite *sprite)
static void LoadBallParticleGfx(u8 ballId)
{
- u8 taskId;
-
if (GetSpriteTileStartByTag(sBallParticleSpriteSheets[ballId].tag) == 0xFFFF)
{
LoadCompressedSpriteSheetUsingHeap(&sBallParticleSpriteSheets[ballId]);
diff --git a/src/battle_anim_water.c b/src/battle_anim_water.c
index 2bb90e585..f157102b0 100644
--- a/src/battle_anim_water.c
+++ b/src/battle_anim_water.c
@@ -881,8 +881,6 @@ static void AnimTask_CreateSurfWave_Step1(u8 taskId)
u16 rgbBuffer;
u16 *BGptrX = &gBattle_BG1_X;
u16 *BGptrY = &gBattle_BG1_Y;
- u32 palOffset;
- u16 palNum;
*BGptrX += gTasks[taskId].data[0];
*BGptrY += gTasks[taskId].data[1];
diff --git a/src/battle_controller_link_opponent.c b/src/battle_controller_link_opponent.c
index 269b4c1b4..718fe30c9 100644
--- a/src/battle_controller_link_opponent.c
+++ b/src/battle_controller_link_opponent.c
@@ -1693,7 +1693,6 @@ static void LinkOpponentHandleIntroSlide(void)
static void LinkOpponentHandleIntroTrainerBallThrow(void)
{
- u8 paletteNum;
u8 taskId;
SetSpritePrimaryCoordsFromSecondaryCoords(&gSprites[gBattlerSpriteIds[gActiveBattler]]);
diff --git a/src/battle_controller_opponent.c b/src/battle_controller_opponent.c
index 2f1153612..d241d335f 100644
--- a/src/battle_controller_opponent.c
+++ b/src/battle_controller_opponent.c
@@ -1858,7 +1858,6 @@ static void OpponentHandleIntroSlide(void)
static void OpponentHandleIntroTrainerBallThrow(void)
{
- u8 paletteNum;
u8 taskId;
SetSpritePrimaryCoordsFromSecondaryCoords(&gSprites[gBattlerSpriteIds[gActiveBattler]]);
diff --git a/src/battle_controller_recorded_opponent.c b/src/battle_controller_recorded_opponent.c
index 895ca6b39..23269dbad 100644
--- a/src/battle_controller_recorded_opponent.c
+++ b/src/battle_controller_recorded_opponent.c
@@ -1633,7 +1633,6 @@ static void RecordedOpponentHandleIntroSlide(void)
static void RecordedOpponentHandleIntroTrainerBallThrow(void)
{
- u8 paletteNum;
u8 taskId;
SetSpritePrimaryCoordsFromSecondaryCoords(&gSprites[gBattlerSpriteIds[gActiveBattler]]);
diff --git a/src/battle_controller_safari.c b/src/battle_controller_safari.c
index b5a8b1bb6..b357c689f 100644
--- a/src/battle_controller_safari.c
+++ b/src/battle_controller_safari.c
@@ -470,8 +470,6 @@ static void SafariHandleChooseMove(void)
static void SafariHandleChooseItem(void)
{
- s32 i;
-
BeginNormalPaletteFade(0xFFFFFFFF, 0, 0, 0x10, RGB_BLACK);
gBattlerControllerFuncs[gActiveBattler] = SafariOpenPokeblockCase;
gBattlerInMenuId = gActiveBattler;
diff --git a/src/battle_interface.c b/src/battle_interface.c
index adbef019d..df123630c 100644
--- a/src/battle_interface.c
+++ b/src/battle_interface.c
@@ -1897,7 +1897,6 @@ static void UpdateNickInHealthbox(u8 healthboxSpriteId, struct Pokemon *mon)
{
u8 nickname[POKEMON_NAME_LENGTH + 1];
void *ptr;
- const u8 *genderTxt;
u32 windowId, spriteTileNum;
u8 *windowTileData;
u16 species;
diff --git a/src/battle_main.c b/src/battle_main.c
index 7e8966597..940fab8ff 100644
--- a/src/battle_main.c
+++ b/src/battle_main.c
@@ -2722,7 +2722,7 @@ void SpriteCB_FaintOpponentMon(struct Sprite *sprite)
if (species == SPECIES_UNOWN)
{
u32 personalityValue = GetMonData(&gEnemyParty[gBattlerPartyIndexes[battler]], MON_DATA_PERSONALITY);
- u16 unownForm = ((((personalityValue & 0x3000000) >> 18) | ((personalityValue & 0x30000) >> 12) | ((personalityValue & 0x300) >> 6) | (personalityValue & 3)) % 0x1C);
+ u16 unownForm = GET_UNOWN_LETTER(personalityValue);
u16 unownSpecies;
if (unownForm == 0)
diff --git a/src/berry_blender.c b/src/berry_blender.c
index 573affbd5..08a25c58a 100644
--- a/src/berry_blender.c
+++ b/src/berry_blender.c
@@ -2390,7 +2390,7 @@ static s16 Debug_GetGameTimeStage(void)
static void CalculatePokeblock(struct BlenderBerry *berries, struct Pokeblock *pokeblock, u8 numPlayers, u8 *flavors, u16 maxRPM)
{
s32 i, j;
- s32 multiuseVar, var2;
+ s32 multiuseVar;
u8 numNegatives;
for (i = 0; i < FLAVOR_COUNT + 1; i++)
diff --git a/src/berry_crush.c b/src/berry_crush.c
index 90bc7150d..84e2e2eba 100755
--- a/src/berry_crush.c
+++ b/src/berry_crush.c
@@ -877,7 +877,7 @@ void StartBerryCrush(MainCallback callback)
static void GetBerryFromBag(void)
{
if (gSpecialVar_ItemId < FIRST_BERRY_INDEX || gSpecialVar_ItemId > LAST_BERRY_INDEX + 1)
- gSpecialVar_ItemId = ITEM_CHERI_BERRY;
+ gSpecialVar_ItemId = FIRST_BERRY_INDEX;
else
RemoveBagItem(gSpecialVar_ItemId, 1);
@@ -1573,7 +1573,6 @@ static void Task_ShowBerryCrushRankings(u8 taskId)
u8 i = 0, j, xPos, yPos;
u32 score = 0;
s16 *data = gTasks[taskId].data;
- u8 *str;
switch (data[0])
{
@@ -1714,8 +1713,7 @@ void sub_8022588(struct BerryCrushGame *r5)
void sub_8022600(struct BerryCrushGame *r6)
{
- u8 r7, r2;
- u8 *r4;
+ u8 r7;
for (r7 = 0; r7 < r6->unk9; ++r7)
{
diff --git a/src/cable_club.c b/src/cable_club.c
index 64bc9187a..cd0baefcd 100644
--- a/src/cable_club.c
+++ b/src/cable_club.c
@@ -128,8 +128,6 @@ static void UpdateLinkPlayerCountDisplay(u8 taskId, u8 numPlayers)
static u32 ExchangeDataAndGetLinkupStatus(u8 minPlayers, u8 maxPlayers)
{
- int playerCount;
-
switch (GetLinkPlayerDataExchangeStatusTimed(minPlayers, maxPlayers))
{
case EXCHANGE_COMPLETE:
@@ -511,7 +509,6 @@ static void FinishLinkup(u16 *linkupStatus, u32 taskId)
static void Task_LinkupAwaitTrainerCardData(u8 taskId)
{
u8 index;
- struct TrainerCard *trainerCards;
if (CheckLinkErrored(taskId) == TRUE)
return;
diff --git a/src/contest.c b/src/contest.c
index 40a0eac66..e7c420448 100644
--- a/src/contest.c
+++ b/src/contest.c
@@ -4422,7 +4422,6 @@ static void CalculateAppealMoveImpact(u8 contestant)
u16 move;
u8 effect;
u8 rnd;
- bool8 canUseTurn;
s32 i;
eContestantStatus[contestant].appeal = 0;
diff --git a/src/credits.c b/src/credits.c
index 41d1c1686..a9beb319c 100644
--- a/src/credits.c
+++ b/src/credits.c
@@ -1158,7 +1158,7 @@ static void CB2_RunCreditsSequence(void)
static void sub_8175548(void)
{
ResetBgsAndClearDma3BusyFlags(0);
- InitBgsFromTemplates(0, sBackgroundTemplates, 1);
+ InitBgsFromTemplates(0, sBackgroundTemplates, ARRAY_COUNT(sBackgroundTemplates));
SetBgTilemapBuffer(0, AllocZeroed(BG_SCREEN_SIZE));
LoadPalette(gUnknown_085E56F0, 0x80, 0x40);
InitWindows(sWindowTemplates);
@@ -1305,8 +1305,6 @@ static void sub_8175808(u8 taskIdA)
static void c2_080C9BFC(u8 taskIdA)
{
- u16 backup;
-
SetVBlankCallback(NULL);
if (sub_8176AB0(gTasks[taskIdA].data[TDA_7], taskIdA))
diff --git a/src/data/items.h b/src/data/items.h
index 30beb5352..443c45f1a 100644
--- a/src/data/items.h
+++ b/src/data/items.h
@@ -7,9 +7,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Pokeballs
@@ -21,10 +20,10 @@ const struct Item gItems[] =
.price = 0,
.description = sMasterBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 0,
- .battleUsage = 2,
+ .type = ITEM_MASTER_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 0,
+ .secondaryId = ITEM_MASTER_BALL - FIRST_BALL,
},
[ITEM_ULTRA_BALL] =
@@ -34,10 +33,10 @@ const struct Item gItems[] =
.price = 1200,
.description = sUltraBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 1,
- .battleUsage = 2,
+ .type = ITEM_ULTRA_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 1,
+ .secondaryId = ITEM_ULTRA_BALL - FIRST_BALL,
},
[ITEM_GREAT_BALL] =
@@ -47,10 +46,10 @@ const struct Item gItems[] =
.price = 600,
.description = sGreatBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 2,
- .battleUsage = 2,
+ .type = ITEM_GREAT_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 2,
+ .secondaryId = ITEM_GREAT_BALL - FIRST_BALL,
},
[ITEM_POKE_BALL] =
@@ -60,10 +59,10 @@ const struct Item gItems[] =
.price = 200,
.description = sPokeBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 3,
- .battleUsage = 2,
+ .type = ITEM_POKE_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 3,
+ .secondaryId = ITEM_POKE_BALL - FIRST_BALL,
},
[ITEM_SAFARI_BALL] =
@@ -73,10 +72,10 @@ const struct Item gItems[] =
.price = 0,
.description = sSafariBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 4,
- .battleUsage = 2,
+ .type = ITEM_SAFARI_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 4,
+ .secondaryId = ITEM_SAFARI_BALL - FIRST_BALL,
},
[ITEM_NET_BALL] =
@@ -86,10 +85,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sNetBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 5,
- .battleUsage = 2,
+ .type = ITEM_NET_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 5,
+ .secondaryId = ITEM_NET_BALL - FIRST_BALL,
},
[ITEM_DIVE_BALL] =
@@ -99,10 +98,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sDiveBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 6,
- .battleUsage = 2,
+ .type = ITEM_DIVE_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 6,
+ .secondaryId = ITEM_DIVE_BALL - FIRST_BALL,
},
[ITEM_NEST_BALL] =
@@ -112,10 +111,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sNestBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 7,
- .battleUsage = 2,
+ .type = ITEM_NEST_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 7,
+ .secondaryId = ITEM_NEST_BALL - FIRST_BALL,
},
[ITEM_REPEAT_BALL] =
@@ -125,10 +124,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sRepeatBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 8,
- .battleUsage = 2,
+ .type = ITEM_REPEAT_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 8,
+ .secondaryId = ITEM_REPEAT_BALL - FIRST_BALL,
},
[ITEM_TIMER_BALL] =
@@ -138,10 +137,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sTimerBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 9,
- .battleUsage = 2,
+ .type = ITEM_TIMER_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 9,
+ .secondaryId = ITEM_TIMER_BALL - FIRST_BALL,
},
[ITEM_LUXURY_BALL] =
@@ -151,10 +150,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sLuxuryBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 10,
- .battleUsage = 2,
+ .type = ITEM_LUXURY_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 10,
+ .secondaryId = ITEM_LUXURY_BALL - FIRST_BALL,
},
[ITEM_PREMIER_BALL] =
@@ -164,10 +163,10 @@ const struct Item gItems[] =
.price = 200,
.description = sPremierBallDesc,
.pocket = POCKET_POKE_BALLS,
- .type = 11,
- .battleUsage = 2,
+ .type = ITEM_PREMIER_BALL - FIRST_BALL,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_PokeBall,
- .secondaryId = 11,
+ .secondaryId = ITEM_PREMIER_BALL - FIRST_BALL,
},
// Medicine
@@ -180,11 +179,10 @@ const struct Item gItems[] =
.holdEffectParam = 20,
.description = sPotionDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_ANTIDOTE] =
@@ -194,11 +192,10 @@ const struct Item gItems[] =
.price = 100,
.description = sAntidoteDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_BURN_HEAL] =
@@ -208,11 +205,10 @@ const struct Item gItems[] =
.price = 250,
.description = sBurnHealDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_ICE_HEAL] =
@@ -222,11 +218,10 @@ const struct Item gItems[] =
.price = 250,
.description = sIceHealDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_AWAKENING] =
@@ -236,11 +231,10 @@ const struct Item gItems[] =
.price = 250,
.description = sAwakeningDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_PARALYZE_HEAL] =
@@ -250,11 +244,10 @@ const struct Item gItems[] =
.price = 200,
.description = sParalyzeHealDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_FULL_RESTORE] =
@@ -265,11 +258,10 @@ const struct Item gItems[] =
.holdEffectParam = 255,
.description = sFullRestoreDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_MAX_POTION] =
@@ -280,11 +272,10 @@ const struct Item gItems[] =
.holdEffectParam = 255,
.description = sMaxPotionDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_HYPER_POTION] =
@@ -295,11 +286,10 @@ const struct Item gItems[] =
.holdEffectParam = 200,
.description = sHyperPotionDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_SUPER_POTION] =
@@ -310,11 +300,10 @@ const struct Item gItems[] =
.holdEffectParam = 50,
.description = sSuperPotionDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_FULL_HEAL] =
@@ -324,11 +313,10 @@ const struct Item gItems[] =
.price = 600,
.description = sFullHealDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_REVIVE] =
@@ -338,11 +326,10 @@ const struct Item gItems[] =
.price = 1500,
.description = sReviveDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_MAX_REVIVE] =
@@ -352,11 +339,10 @@ const struct Item gItems[] =
.price = 4000,
.description = sMaxReviveDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_FRESH_WATER] =
@@ -367,11 +353,10 @@ const struct Item gItems[] =
.holdEffectParam = 50,
.description = sFreshWaterDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_SODA_POP] =
@@ -382,11 +367,10 @@ const struct Item gItems[] =
.holdEffectParam = 60,
.description = sSodaPopDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_LEMONADE] =
@@ -397,11 +381,10 @@ const struct Item gItems[] =
.holdEffectParam = 80,
.description = sLemonadeDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_MOOMOO_MILK] =
@@ -412,11 +395,10 @@ const struct Item gItems[] =
.holdEffectParam = 100,
.description = sMoomooMilkDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_ENERGY_POWDER] =
@@ -426,11 +408,10 @@ const struct Item gItems[] =
.price = 500,
.description = sEnergyPowderDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_ENERGY_ROOT] =
@@ -440,11 +421,10 @@ const struct Item gItems[] =
.price = 800,
.description = sEnergyRootDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_HEAL_POWDER] =
@@ -454,11 +434,10 @@ const struct Item gItems[] =
.price = 450,
.description = sHealPowderDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_REVIVAL_HERB] =
@@ -468,11 +447,10 @@ const struct Item gItems[] =
.price = 2800,
.description = sRevivalHerbDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_ETHER] =
@@ -483,11 +461,10 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sEtherDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPRecovery,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_PPRecovery,
- .secondaryId = 0,
},
[ITEM_MAX_ETHER] =
@@ -498,11 +475,10 @@ const struct Item gItems[] =
.holdEffectParam = 255,
.description = sMaxEtherDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPRecovery,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_PPRecovery,
- .secondaryId = 0,
},
[ITEM_ELIXIR] =
@@ -513,11 +489,10 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sElixirDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPRecovery,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_PPRecovery,
- .secondaryId = 0,
},
[ITEM_MAX_ELIXIR] =
@@ -528,11 +503,10 @@ const struct Item gItems[] =
.holdEffectParam = 255,
.description = sMaxElixirDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPRecovery,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_PPRecovery,
- .secondaryId = 0,
},
[ITEM_LAVA_COOKIE] =
@@ -542,11 +516,10 @@ const struct Item gItems[] =
.price = 200,
.description = sLavaCookieDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_BLUE_FLUTE] =
@@ -556,11 +529,10 @@ const struct Item gItems[] =
.price = 100,
.description = sBlueFluteDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_YELLOW_FLUTE] =
@@ -570,11 +542,10 @@ const struct Item gItems[] =
.price = 200,
.description = sYellowFluteDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_RED_FLUTE] =
@@ -584,11 +555,10 @@ const struct Item gItems[] =
.price = 300,
.description = sRedFluteDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_BLACK_FLUTE] =
@@ -599,9 +569,8 @@ const struct Item gItems[] =
.holdEffectParam = 50,
.description = sBlackFluteDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_BlackWhiteFlute,
- .secondaryId = 0,
},
[ITEM_WHITE_FLUTE] =
@@ -612,9 +581,8 @@ const struct Item gItems[] =
.holdEffectParam = 150,
.description = sWhiteFluteDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_BlackWhiteFlute,
- .secondaryId = 0,
},
[ITEM_BERRY_JUICE] =
@@ -626,11 +594,10 @@ const struct Item gItems[] =
.holdEffectParam = 20,
.description = sBerryJuiceDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_SACRED_ASH] =
@@ -640,9 +607,8 @@ const struct Item gItems[] =
.price = 200,
.description = sSacredAshDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_SacredAsh,
- .secondaryId = 0,
},
// Collectibles
@@ -654,9 +620,8 @@ const struct Item gItems[] =
.price = 20,
.description = sShoalSaltDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SHOAL_SHELL] =
@@ -666,9 +631,8 @@ const struct Item gItems[] =
.price = 20,
.description = sShoalShellDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_RED_SHARD] =
@@ -678,9 +642,8 @@ const struct Item gItems[] =
.price = 200,
.description = sRedShardDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BLUE_SHARD] =
@@ -690,9 +653,8 @@ const struct Item gItems[] =
.price = 200,
.description = sBlueShardDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_YELLOW_SHARD] =
@@ -702,9 +664,8 @@ const struct Item gItems[] =
.price = 200,
.description = sYellowShardDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_GREEN_SHARD] =
@@ -714,9 +675,8 @@ const struct Item gItems[] =
.price = 200,
.description = sGreenShardDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_034] =
@@ -726,9 +686,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_035] =
@@ -738,9 +697,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_036] =
@@ -750,9 +708,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_037] =
@@ -762,9 +719,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_038] =
@@ -774,9 +730,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_039] =
@@ -786,9 +741,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_03A] =
@@ -798,9 +752,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_03B] =
@@ -810,9 +763,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_03C] =
@@ -822,9 +774,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_03D] =
@@ -834,9 +785,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_03E] =
@@ -846,9 +796,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Vitamins
@@ -860,9 +809,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sHPUpDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_PROTEIN] =
@@ -872,9 +820,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sProteinDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_IRON] =
@@ -884,9 +831,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sIronDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_CARBOS] =
@@ -896,9 +842,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sCarbosDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_CALCIUM] =
@@ -908,9 +853,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sCalciumDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_RARE_CANDY] =
@@ -920,9 +864,8 @@ const struct Item gItems[] =
.price = 4800,
.description = sRareCandyDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_RareCandy,
- .secondaryId = 0,
},
[ITEM_PP_UP] =
@@ -932,9 +875,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sPPUpDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPUp,
- .secondaryId = 0,
},
[ITEM_ZINC] =
@@ -944,9 +886,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sZincDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_PP_MAX] =
@@ -956,9 +897,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sPPMaxDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPUp,
- .secondaryId = 0,
},
[ITEM_048] =
@@ -968,9 +908,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Battle items
@@ -982,11 +921,10 @@ const struct Item gItems[] =
.price = 700,
.description = sGuardSpecDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_DIRE_HIT] =
@@ -996,11 +934,10 @@ const struct Item gItems[] =
.price = 650,
.description = sDireHitDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_X_ATTACK] =
@@ -1010,11 +947,10 @@ const struct Item gItems[] =
.price = 500,
.description = sXAttackDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_X_DEFEND] =
@@ -1024,11 +960,10 @@ const struct Item gItems[] =
.price = 550,
.description = sXDefendDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_X_SPEED] =
@@ -1038,11 +973,10 @@ const struct Item gItems[] =
.price = 350,
.description = sXSpeedDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_X_ACCURACY] =
@@ -1052,11 +986,10 @@ const struct Item gItems[] =
.price = 950,
.description = sXAccuracyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_X_SPECIAL] =
@@ -1066,11 +999,10 @@ const struct Item gItems[] =
.price = 350,
.description = sXSpecialDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_StatIncrease,
- .secondaryId = 0,
},
[ITEM_POKE_DOLL] =
@@ -1080,11 +1012,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sPokeDollDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_Escape,
- .secondaryId = 0,
},
[ITEM_FLUFFY_TAIL] =
@@ -1094,11 +1025,10 @@ const struct Item gItems[] =
.price = 1000,
.description = sFluffyTailDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 2,
+ .battleUsage = ITEM_B_USE_OTHER,
.battleUseFunc = ItemUseInBattle_Escape,
- .secondaryId = 0,
},
[ITEM_052] =
@@ -1108,9 +1038,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Field items
@@ -1123,9 +1052,8 @@ const struct Item gItems[] =
.holdEffectParam = 200,
.description = sSuperRepelDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Repel,
- .secondaryId = 0,
},
[ITEM_MAX_REPEL] =
@@ -1136,9 +1064,8 @@ const struct Item gItems[] =
.holdEffectParam = 250,
.description = sMaxRepelDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Repel,
- .secondaryId = 0,
},
[ITEM_ESCAPE_ROPE] =
@@ -1148,9 +1075,8 @@ const struct Item gItems[] =
.price = 550,
.description = sEscapeRopeDesc,
.pocket = POCKET_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_EscapeRope,
- .secondaryId = 0,
},
[ITEM_REPEL] =
@@ -1161,9 +1087,8 @@ const struct Item gItems[] =
.holdEffectParam = 100,
.description = sRepelDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Repel,
- .secondaryId = 0,
},
[ITEM_057] =
@@ -1173,9 +1098,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_058] =
@@ -1185,9 +1109,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_059] =
@@ -1197,9 +1120,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_05A] =
@@ -1209,9 +1131,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_05B] =
@@ -1221,9 +1142,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_05C] =
@@ -1233,9 +1153,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Evolution stones
@@ -1247,9 +1166,8 @@ const struct Item gItems[] =
.price = 2100,
.description = sSunStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_EvolutionStone,
- .secondaryId = 0,
},
[ITEM_MOON_STONE] =
@@ -1259,9 +1177,8 @@ const struct Item gItems[] =
.price = 0,
.description = sMoonStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_EvolutionStone,
- .secondaryId = 0,
},
[ITEM_FIRE_STONE] =
@@ -1271,9 +1188,8 @@ const struct Item gItems[] =
.price = 2100,
.description = sFireStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_EvolutionStone,
- .secondaryId = 0,
},
[ITEM_THUNDER_STONE] =
@@ -1283,9 +1199,8 @@ const struct Item gItems[] =
.price = 2100,
.description = sThunderStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_EvolutionStone,
- .secondaryId = 0,
},
[ITEM_WATER_STONE] =
@@ -1295,9 +1210,8 @@ const struct Item gItems[] =
.price = 2100,
.description = sWaterStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_EvolutionStone,
- .secondaryId = 0,
},
[ITEM_LEAF_STONE] =
@@ -1307,9 +1221,8 @@ const struct Item gItems[] =
.price = 2100,
.description = sLeafStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_EvolutionStone,
- .secondaryId = 0,
},
[ITEM_063] =
@@ -1319,9 +1232,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_064] =
@@ -1331,9 +1243,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_065] =
@@ -1343,9 +1254,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_066] =
@@ -1355,9 +1265,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Valuable items
@@ -1369,9 +1278,8 @@ const struct Item gItems[] =
.price = 500,
.description = sTinyMushroomDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BIG_MUSHROOM] =
@@ -1381,9 +1289,8 @@ const struct Item gItems[] =
.price = 5000,
.description = sBigMushroomDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_069] =
@@ -1393,9 +1300,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_PEARL] =
@@ -1405,9 +1311,8 @@ const struct Item gItems[] =
.price = 1400,
.description = sPearlDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BIG_PEARL] =
@@ -1417,9 +1322,8 @@ const struct Item gItems[] =
.price = 7500,
.description = sBigPearlDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_STARDUST] =
@@ -1429,9 +1333,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sStardustDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_STAR_PIECE] =
@@ -1441,9 +1344,8 @@ const struct Item gItems[] =
.price = 9800,
.description = sStarPieceDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_NUGGET] =
@@ -1453,9 +1355,8 @@ const struct Item gItems[] =
.price = 10000,
.description = sNuggetDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_HEART_SCALE] =
@@ -1465,9 +1366,8 @@ const struct Item gItems[] =
.price = 100,
.description = sHeartScaleDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_070] =
@@ -1477,9 +1377,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_071] =
@@ -1489,9 +1388,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_072] =
@@ -1501,9 +1399,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_073] =
@@ -1513,9 +1410,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_074] =
@@ -1525,9 +1421,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_075] =
@@ -1537,9 +1432,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_076] =
@@ -1549,9 +1443,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_077] =
@@ -1561,9 +1454,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_078] =
@@ -1573,9 +1465,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Mail
@@ -1586,9 +1477,9 @@ const struct Item gItems[] =
.price = 50,
.description = sOrangeMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 0,
+ .secondaryId = ITEM_ORANGE_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_HARBOR_MAIL] =
@@ -1598,9 +1489,9 @@ const struct Item gItems[] =
.price = 50,
.description = sHarborMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 1,
+ .secondaryId = ITEM_HARBOR_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_GLITTER_MAIL] =
@@ -1610,9 +1501,9 @@ const struct Item gItems[] =
.price = 50,
.description = sGlitterMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 2,
+ .secondaryId = ITEM_GLITTER_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_MECH_MAIL] =
@@ -1622,9 +1513,9 @@ const struct Item gItems[] =
.price = 50,
.description = sMechMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 3,
+ .secondaryId = ITEM_MECH_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_WOOD_MAIL] =
@@ -1634,9 +1525,9 @@ const struct Item gItems[] =
.price = 50,
.description = sWoodMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 4,
+ .secondaryId = ITEM_WOOD_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_WAVE_MAIL] =
@@ -1646,9 +1537,9 @@ const struct Item gItems[] =
.price = 50,
.description = sWaveMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 5,
+ .secondaryId = ITEM_WAVE_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_BEAD_MAIL] =
@@ -1658,9 +1549,9 @@ const struct Item gItems[] =
.price = 50,
.description = sBeadMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 6,
+ .secondaryId = ITEM_BEAD_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_SHADOW_MAIL] =
@@ -1670,9 +1561,9 @@ const struct Item gItems[] =
.price = 50,
.description = sShadowMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 7,
+ .secondaryId = ITEM_SHADOW_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_TROPIC_MAIL] =
@@ -1682,9 +1573,9 @@ const struct Item gItems[] =
.price = 50,
.description = sTropicMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 8,
+ .secondaryId = ITEM_TROPIC_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_DREAM_MAIL] =
@@ -1694,9 +1585,9 @@ const struct Item gItems[] =
.price = 50,
.description = sDreamMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 9,
+ .secondaryId = ITEM_DREAM_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_FAB_MAIL] =
@@ -1706,9 +1597,9 @@ const struct Item gItems[] =
.price = 50,
.description = sFabMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 10,
+ .secondaryId = ITEM_FAB_MAIL - FIRST_MAIL_INDEX,
},
[ITEM_RETRO_MAIL] =
@@ -1718,9 +1609,9 @@ const struct Item gItems[] =
.price = 0,
.description = sRetroMailDesc,
.pocket = POCKET_ITEMS,
- .type = 0,
+ .type = ITEM_USE_MAIL,
.fieldUseFunc = ItemUseOutOfBattle_Mail,
- .secondaryId = 11,
+ .secondaryId = ITEM_RETRO_MAIL - FIRST_MAIL_INDEX,
},
// Berries
@@ -1733,11 +1624,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_PAR,
.description = sCheriBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_CHESTO_BERRY] =
@@ -1748,11 +1638,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_SLP,
.description = sChestoBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_PECHA_BERRY] =
@@ -1763,11 +1652,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_PSN,
.description = sPechaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_RAWST_BERRY] =
@@ -1778,11 +1666,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_BRN,
.description = sRawstBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_ASPEAR_BERRY] =
@@ -1793,11 +1680,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_FRZ,
.description = sAspearBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_LEPPA_BERRY] =
@@ -1809,11 +1695,10 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sLeppaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PPRecovery,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_PPRecovery,
- .secondaryId = 0,
},
[ITEM_ORAN_BERRY] =
@@ -1825,11 +1710,10 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sOranBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_PERSIM_BERRY] =
@@ -1840,11 +1724,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_CONFUSION,
.description = sPersimBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_LUM_BERRY] =
@@ -1855,11 +1738,10 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_STATUS,
.description = sLumBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_SITRUS_BERRY] =
@@ -1871,11 +1753,10 @@ const struct Item gItems[] =
.holdEffectParam = 30,
.description = sSitrusBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_Medicine,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_Medicine,
- .secondaryId = 0,
},
[ITEM_FIGY_BERRY] =
@@ -1887,9 +1768,8 @@ const struct Item gItems[] =
.holdEffectParam = 8,
.description = sFigyBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_WIKI_BERRY] =
@@ -1901,9 +1781,8 @@ const struct Item gItems[] =
.holdEffectParam = 8,
.description = sWikiBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MAGO_BERRY] =
@@ -1915,9 +1794,8 @@ const struct Item gItems[] =
.holdEffectParam = 8,
.description = sMagoBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_AGUAV_BERRY] =
@@ -1929,9 +1807,8 @@ const struct Item gItems[] =
.holdEffectParam = 8,
.description = sAguavBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_IAPAPA_BERRY] =
@@ -1943,9 +1820,8 @@ const struct Item gItems[] =
.holdEffectParam = 8,
.description = sIapapaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_RAZZ_BERRY] =
@@ -1955,9 +1831,8 @@ const struct Item gItems[] =
.price = 20,
.description = sRazzBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BLUK_BERRY] =
@@ -1967,9 +1842,8 @@ const struct Item gItems[] =
.price = 20,
.description = sBlukBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_NANAB_BERRY] =
@@ -1979,9 +1853,8 @@ const struct Item gItems[] =
.price = 20,
.description = sNanabBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_WEPEAR_BERRY] =
@@ -1991,9 +1864,8 @@ const struct Item gItems[] =
.price = 20,
.description = sWepearBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_PINAP_BERRY] =
@@ -2003,9 +1875,8 @@ const struct Item gItems[] =
.price = 20,
.description = sPinapBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_POMEG_BERRY] =
@@ -2015,9 +1886,8 @@ const struct Item gItems[] =
.price = 20,
.description = sPomegBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ReduceEV,
- .secondaryId = 0,
},
[ITEM_KELPSY_BERRY] =
@@ -2027,9 +1897,8 @@ const struct Item gItems[] =
.price = 20,
.description = sKelpsyBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ReduceEV,
- .secondaryId = 0,
},
[ITEM_QUALOT_BERRY] =
@@ -2039,9 +1908,8 @@ const struct Item gItems[] =
.price = 20,
.description = sQualotBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ReduceEV,
- .secondaryId = 0,
},
[ITEM_HONDEW_BERRY] =
@@ -2051,9 +1919,8 @@ const struct Item gItems[] =
.price = 20,
.description = sHondewBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ReduceEV,
- .secondaryId = 0,
},
[ITEM_GREPA_BERRY] =
@@ -2063,9 +1930,8 @@ const struct Item gItems[] =
.price = 20,
.description = sGrepaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ReduceEV,
- .secondaryId = 0,
},
[ITEM_TAMATO_BERRY] =
@@ -2075,9 +1941,8 @@ const struct Item gItems[] =
.price = 20,
.description = sTamatoBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_ReduceEV,
- .secondaryId = 0,
},
[ITEM_CORNN_BERRY] =
@@ -2087,9 +1952,8 @@ const struct Item gItems[] =
.price = 20,
.description = sCornnBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MAGOST_BERRY] =
@@ -2099,9 +1963,8 @@ const struct Item gItems[] =
.price = 20,
.description = sMagostBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_RABUTA_BERRY] =
@@ -2111,9 +1974,8 @@ const struct Item gItems[] =
.price = 20,
.description = sRabutaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_NOMEL_BERRY] =
@@ -2123,9 +1985,8 @@ const struct Item gItems[] =
.price = 20,
.description = sNomelBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SPELON_BERRY] =
@@ -2135,9 +1996,8 @@ const struct Item gItems[] =
.price = 20,
.description = sSpelonBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_PAMTRE_BERRY] =
@@ -2147,9 +2007,8 @@ const struct Item gItems[] =
.price = 20,
.description = sPamtreBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_WATMEL_BERRY] =
@@ -2159,9 +2018,8 @@ const struct Item gItems[] =
.price = 20,
.description = sWatmelBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DURIN_BERRY] =
@@ -2171,9 +2029,8 @@ const struct Item gItems[] =
.price = 20,
.description = sDurinBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BELUE_BERRY] =
@@ -2183,9 +2040,8 @@ const struct Item gItems[] =
.price = 20,
.description = sBelueBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LIECHI_BERRY] =
@@ -2197,9 +2053,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sLiechiBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_GANLON_BERRY] =
@@ -2211,9 +2066,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sGanlonBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SALAC_BERRY] =
@@ -2225,9 +2079,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sSalacBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_PETAYA_BERRY] =
@@ -2239,9 +2092,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sPetayaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_APICOT_BERRY] =
@@ -2253,9 +2105,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sApicotBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LANSAT_BERRY] =
@@ -2267,9 +2118,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sLansatBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_STARF_BERRY] =
@@ -2281,9 +2131,8 @@ const struct Item gItems[] =
.holdEffectParam = 4,
.description = sStarfBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ENIGMA_BERRY] =
@@ -2293,11 +2142,10 @@ const struct Item gItems[] =
.price = 20,
.description = sEnigmaBerryDesc,
.pocket = POCKET_BERRIES,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU, // Type handled by ItemUseOutOfBattle_EnigmaBerry
.fieldUseFunc = ItemUseOutOfBattle_EnigmaBerry,
- .battleUsage = 1,
+ .battleUsage = ITEM_B_USE_MEDICINE,
.battleUseFunc = ItemUseInBattle_EnigmaBerry,
- .secondaryId = 0,
},
[ITEM_0B0] =
@@ -2307,9 +2155,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0B1] =
@@ -2319,9 +2166,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0B2] =
@@ -2331,9 +2177,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Hold items
@@ -2347,9 +2192,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sBrightPowderDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_WHITE_HERB] =
@@ -2360,9 +2204,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_RESTORE_STATS,
.description = sWhiteHerbDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MACHO_BRACE] =
@@ -2373,9 +2216,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_MACHO_BRACE,
.description = sMachoBraceDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_EXP_SHARE] =
@@ -2386,9 +2228,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_EXP_SHARE,
.description = sExpShareDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_QUICK_CLAW] =
@@ -2400,9 +2241,8 @@ const struct Item gItems[] =
.holdEffectParam = 20,
.description = sQuickClawDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SOOTHE_BELL] =
@@ -2413,9 +2253,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_HAPPINESS_UP,
.description = sSootheBellDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MENTAL_HERB] =
@@ -2426,9 +2265,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CURE_ATTRACT,
.description = sMentalHerbDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_CHOICE_BAND] =
@@ -2439,9 +2277,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CHOICE_BAND,
.description = sChoiceBandDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_KINGS_ROCK] =
@@ -2453,9 +2290,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sKingsRockDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SILVER_POWDER] =
@@ -2467,9 +2303,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sSilverPowderDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_AMULET_COIN] =
@@ -2481,9 +2316,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sAmuletCoinDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_CLEANSE_TAG] =
@@ -2494,9 +2328,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_REPEL,
.description = sCleanseTagDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SOUL_DEW] =
@@ -2507,9 +2340,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_SOUL_DEW,
.description = sSoulDewDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DEEP_SEA_TOOTH] =
@@ -2520,9 +2352,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_DEEP_SEA_TOOTH,
.description = sDeepSeaToothDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DEEP_SEA_SCALE] =
@@ -2533,9 +2364,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_DEEP_SEA_SCALE,
.description = sDeepSeaScaleDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SMOKE_BALL] =
@@ -2546,9 +2376,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_CAN_ALWAYS_RUN,
.description = sSmokeBallDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_EVERSTONE] =
@@ -2559,9 +2388,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_PREVENT_EVOLVE,
.description = sEverstoneDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_FOCUS_BAND] =
@@ -2573,9 +2401,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sFocusBandDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LUCKY_EGG] =
@@ -2586,9 +2413,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_LUCKY_EGG,
.description = sLuckyEggDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SCOPE_LENS] =
@@ -2599,9 +2425,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_SCOPE_LENS,
.description = sScopeLensDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_METAL_COAT] =
@@ -2613,9 +2438,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sMetalCoatDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LEFTOVERS] =
@@ -2627,9 +2451,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sLeftoversDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DRAGON_SCALE] =
@@ -2641,9 +2464,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sDragonScaleDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LIGHT_BALL] =
@@ -2654,9 +2476,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_LIGHT_BALL,
.description = sLightBallDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SOFT_SAND] =
@@ -2668,9 +2489,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sSoftSandDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_HARD_STONE] =
@@ -2682,9 +2502,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sHardStoneDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MIRACLE_SEED] =
@@ -2696,9 +2515,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sMiracleSeedDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BLACK_GLASSES] =
@@ -2710,9 +2528,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sBlackGlassesDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BLACK_BELT] =
@@ -2724,9 +2541,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sBlackBeltDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MAGNET] =
@@ -2738,9 +2554,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sMagnetDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MYSTIC_WATER] =
@@ -2752,9 +2567,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sMysticWaterDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SHARP_BEAK] =
@@ -2766,9 +2580,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sSharpBeakDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_POISON_BARB] =
@@ -2780,9 +2593,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sPoisonBarbDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_NEVER_MELT_ICE] =
@@ -2794,9 +2606,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sNeverMeltIceDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SPELL_TAG] =
@@ -2808,9 +2619,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sSpellTagDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_TWISTED_SPOON] =
@@ -2822,9 +2632,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sTwistedSpoonDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_CHARCOAL] =
@@ -2836,9 +2645,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sCharcoalDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DRAGON_FANG] =
@@ -2850,9 +2658,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sDragonFangDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SILK_SCARF] =
@@ -2864,9 +2671,8 @@ const struct Item gItems[] =
.holdEffectParam = 10,
.description = sSilkScarfDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_UP_GRADE] =
@@ -2877,9 +2683,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_UP_GRADE,
.description = sUpGradeDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SHELL_BELL] =
@@ -2891,9 +2696,8 @@ const struct Item gItems[] =
.holdEffectParam = 8,
.description = sShellBellDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SEA_INCENSE] =
@@ -2905,9 +2709,8 @@ const struct Item gItems[] =
.holdEffectParam = 5,
.description = sSeaIncenseDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LAX_INCENSE] =
@@ -2919,9 +2722,8 @@ const struct Item gItems[] =
.holdEffectParam = 5,
.description = sLaxIncenseDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LUCKY_PUNCH] =
@@ -2932,9 +2734,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_LUCKY_PUNCH,
.description = sLuckyPunchDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_METAL_POWDER] =
@@ -2945,9 +2746,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_METAL_POWDER,
.description = sMetalPowderDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_THICK_CLUB] =
@@ -2958,9 +2758,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_THICK_CLUB,
.description = sThickClubDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_STICK] =
@@ -2971,9 +2770,8 @@ const struct Item gItems[] =
.holdEffect = HOLD_EFFECT_STICK,
.description = sStickDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E2] =
@@ -2983,9 +2781,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E3] =
@@ -2995,9 +2792,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E4] =
@@ -3007,9 +2803,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E5] =
@@ -3019,9 +2814,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E6] =
@@ -3031,9 +2825,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E7] =
@@ -3043,9 +2836,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E8] =
@@ -3055,9 +2847,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0E9] =
@@ -3067,9 +2858,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0EA] =
@@ -3079,9 +2869,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0EB] =
@@ -3091,9 +2880,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0EC] =
@@ -3103,9 +2891,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0ED] =
@@ -3115,9 +2902,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0EE] =
@@ -3127,9 +2913,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0EF] =
@@ -3139,9 +2924,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F0] =
@@ -3151,9 +2935,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F1] =
@@ -3163,9 +2946,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F2] =
@@ -3175,9 +2957,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F3] =
@@ -3187,9 +2968,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F4] =
@@ -3199,9 +2979,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F5] =
@@ -3211,9 +2990,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F6] =
@@ -3223,9 +3001,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F7] =
@@ -3235,9 +3012,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F8] =
@@ -3247,9 +3023,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0F9] =
@@ -3259,9 +3034,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0FA] =
@@ -3271,9 +3045,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0FB] =
@@ -3283,9 +3056,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0FC] =
@@ -3295,9 +3067,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_0FD] =
@@ -3307,9 +3078,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_RED_SCARF] =
@@ -3319,9 +3089,8 @@ const struct Item gItems[] =
.price = 100,
.description = sRedScarfDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BLUE_SCARF] =
@@ -3331,9 +3100,8 @@ const struct Item gItems[] =
.price = 100,
.description = sBlueScarfDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_PINK_SCARF] =
@@ -3343,9 +3111,8 @@ const struct Item gItems[] =
.price = 100,
.description = sPinkScarfDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_GREEN_SCARF] =
@@ -3355,9 +3122,8 @@ const struct Item gItems[] =
.price = 100,
.description = sGreenScarfDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_YELLOW_SCARF] =
@@ -3367,9 +3133,8 @@ const struct Item gItems[] =
.price = 100,
.description = sYellowScarfDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Key items
@@ -3383,9 +3148,9 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_Bike,
- .secondaryId = 0,
+ .secondaryId = MACH_BIKE,
},
[ITEM_COIN_CASE] =
@@ -3396,9 +3161,8 @@ const struct Item gItems[] =
.description = sCoinCaseDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CoinCase,
- .secondaryId = 0,
},
[ITEM_ITEMFINDER] =
@@ -3410,9 +3174,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_Itemfinder,
- .secondaryId = 0,
},
[ITEM_OLD_ROD] =
@@ -3424,7 +3187,7 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_Rod,
.secondaryId = OLD_ROD,
},
@@ -3438,7 +3201,7 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_Rod,
.secondaryId = GOOD_ROD,
},
@@ -3452,7 +3215,7 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_Rod,
.secondaryId = SUPER_ROD,
},
@@ -3465,9 +3228,8 @@ const struct Item gItems[] =
.description = sSSTicketDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_CONTEST_PASS] =
@@ -3478,9 +3240,8 @@ const struct Item gItems[] =
.description = sContestPassDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_10B] =
@@ -3490,9 +3251,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_WAILMER_PAIL] =
@@ -3503,9 +3263,8 @@ const struct Item gItems[] =
.description = sWailmerPailDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_WailmerPail,
- .secondaryId = 0,
},
[ITEM_DEVON_GOODS] =
@@ -3516,9 +3275,8 @@ const struct Item gItems[] =
.description = sDevonGoodsDesc,
.importance = 2,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SOOT_SACK] =
@@ -3529,9 +3287,8 @@ const struct Item gItems[] =
.description = sSootSackDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BASEMENT_KEY] =
@@ -3542,9 +3299,8 @@ const struct Item gItems[] =
.description = sBasementKeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ACRO_BIKE] =
@@ -3556,9 +3312,9 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_Bike,
- .secondaryId = 1,
+ .secondaryId = ACRO_BIKE,
},
[ITEM_POKEBLOCK_CASE] =
@@ -3570,9 +3326,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 3,
+ .type = ITEM_USE_PBLOCK_CASE,
.fieldUseFunc = ItemUseOutOfBattle_PokeblockCase,
- .secondaryId = 0,
},
[ITEM_LETTER] =
@@ -3583,9 +3338,8 @@ const struct Item gItems[] =
.description = sLetterDesc,
.importance = 2,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_EON_TICKET] =
@@ -3596,7 +3350,7 @@ const struct Item gItems[] =
.description = sEonTicketDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
.secondaryId = 1,
},
@@ -3609,9 +3363,8 @@ const struct Item gItems[] =
.description = sRedOrbDesc,
.importance = 2,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BLUE_ORB] =
@@ -3622,9 +3375,8 @@ const struct Item gItems[] =
.description = sBlueOrbDesc,
.importance = 2,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SCANNER] =
@@ -3635,9 +3387,8 @@ const struct Item gItems[] =
.description = sScannerDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_GO_GOGGLES] =
@@ -3648,9 +3399,8 @@ const struct Item gItems[] =
.description = sGoGogglesDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_METEORITE] =
@@ -3661,9 +3411,8 @@ const struct Item gItems[] =
.description = sMeteoriteDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ROOM_1_KEY] =
@@ -3674,9 +3423,8 @@ const struct Item gItems[] =
.description = sRoom1KeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ROOM_2_KEY] =
@@ -3687,9 +3435,8 @@ const struct Item gItems[] =
.description = sRoom2KeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ROOM_4_KEY] =
@@ -3700,9 +3447,8 @@ const struct Item gItems[] =
.description = sRoom4KeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ROOM_6_KEY] =
@@ -3713,9 +3459,8 @@ const struct Item gItems[] =
.description = sRoom6KeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_STORAGE_KEY] =
@@ -3726,9 +3471,8 @@ const struct Item gItems[] =
.description = sStorageKeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_ROOT_FOSSIL] =
@@ -3739,9 +3483,8 @@ const struct Item gItems[] =
.description = sRootFossilDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_CLAW_FOSSIL] =
@@ -3752,9 +3495,8 @@ const struct Item gItems[] =
.description = sClawFossilDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DEVON_SCOPE] =
@@ -3765,9 +3507,8 @@ const struct Item gItems[] =
.description = sDevonScopeDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// TMs/HMs
@@ -3779,9 +3520,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM01Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM02_DRAGON_CLAW] =
@@ -3791,9 +3531,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM02Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM03_WATER_PULSE] =
@@ -3803,9 +3542,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM03Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM04_CALM_MIND] =
@@ -3815,9 +3553,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM04Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM05_ROAR] =
@@ -3827,9 +3564,8 @@ const struct Item gItems[] =
.price = 1000,
.description = sTM05Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM06_TOXIC] =
@@ -3839,9 +3575,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM06Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM07_HAIL] =
@@ -3851,9 +3586,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM07Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM08_BULK_UP] =
@@ -3863,9 +3597,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM08Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM09_BULLET_SEED] =
@@ -3875,9 +3608,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM09Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM10_HIDDEN_POWER] =
@@ -3887,9 +3619,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM10Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM11_SUNNY_DAY] =
@@ -3899,9 +3630,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sTM11Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM12_TAUNT] =
@@ -3911,9 +3641,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM12Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM13_ICE_BEAM] =
@@ -3923,9 +3652,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM13Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM14_BLIZZARD] =
@@ -3935,9 +3663,8 @@ const struct Item gItems[] =
.price = 5500,
.description = sTM14Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM15_HYPER_BEAM] =
@@ -3947,9 +3674,8 @@ const struct Item gItems[] =
.price = 7500,
.description = sTM15Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM16_LIGHT_SCREEN] =
@@ -3959,9 +3685,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM16Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM17_PROTECT] =
@@ -3971,9 +3696,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM17Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM18_RAIN_DANCE] =
@@ -3983,9 +3707,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sTM18Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM19_GIGA_DRAIN] =
@@ -3995,9 +3718,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM19Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM20_SAFEGUARD] =
@@ -4007,9 +3729,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM20Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM21_FRUSTRATION] =
@@ -4019,9 +3740,8 @@ const struct Item gItems[] =
.price = 1000,
.description = sTM21Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM22_SOLARBEAM] =
@@ -4031,9 +3751,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM22Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM23_IRON_TAIL] =
@@ -4043,9 +3762,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM23Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM24_THUNDERBOLT] =
@@ -4055,9 +3773,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM24Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM25_THUNDER] =
@@ -4067,9 +3784,8 @@ const struct Item gItems[] =
.price = 5500,
.description = sTM25Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM26_EARTHQUAKE] =
@@ -4079,9 +3795,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM26Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM27_RETURN] =
@@ -4091,9 +3806,8 @@ const struct Item gItems[] =
.price = 1000,
.description = sTM27Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM28_DIG] =
@@ -4103,9 +3817,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sTM28Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM29_PSYCHIC] =
@@ -4115,9 +3828,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sTM29Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM30_SHADOW_BALL] =
@@ -4127,9 +3839,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM30Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM31_BRICK_BREAK] =
@@ -4139,9 +3850,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM31Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM32_DOUBLE_TEAM] =
@@ -4151,9 +3861,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sTM32Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM33_REFLECT] =
@@ -4163,9 +3872,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM33Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM34_SHOCK_WAVE] =
@@ -4175,9 +3883,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM34Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM35_FLAMETHROWER] =
@@ -4187,9 +3894,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM35Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM36_SLUDGE_BOMB] =
@@ -4199,9 +3905,8 @@ const struct Item gItems[] =
.price = 1000,
.description = sTM36Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM37_SANDSTORM] =
@@ -4211,9 +3916,8 @@ const struct Item gItems[] =
.price = 2000,
.description = sTM37Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM38_FIRE_BLAST] =
@@ -4223,9 +3927,8 @@ const struct Item gItems[] =
.price = 5500,
.description = sTM38Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM39_ROCK_TOMB] =
@@ -4235,9 +3938,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM39Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM40_AERIAL_ACE] =
@@ -4247,9 +3949,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM40Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM41_TORMENT] =
@@ -4259,9 +3960,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM41Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM42_FACADE] =
@@ -4271,9 +3971,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM42Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM43_SECRET_POWER] =
@@ -4283,9 +3982,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM43Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM44_REST] =
@@ -4295,9 +3993,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM44Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM45_ATTRACT] =
@@ -4307,9 +4004,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM45Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM46_THIEF] =
@@ -4319,9 +4015,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM46Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM47_STEEL_WING] =
@@ -4331,9 +4026,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM47Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM48_SKILL_SWAP] =
@@ -4343,9 +4037,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM48Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM49_SNATCH] =
@@ -4355,9 +4048,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM49Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_TM50_OVERHEAT] =
@@ -4367,9 +4059,8 @@ const struct Item gItems[] =
.price = 3000,
.description = sTM50Desc,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM01_CUT] =
@@ -4380,9 +4071,8 @@ const struct Item gItems[] =
.description = sHM01Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM02_FLY] =
@@ -4393,9 +4083,8 @@ const struct Item gItems[] =
.description = sHM02Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM03_SURF] =
@@ -4406,9 +4095,8 @@ const struct Item gItems[] =
.description = sHM03Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM04_STRENGTH] =
@@ -4419,9 +4107,8 @@ const struct Item gItems[] =
.description = sHM04Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM05_FLASH] =
@@ -4432,9 +4119,8 @@ const struct Item gItems[] =
.description = sHM05Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM06_ROCK_SMASH] =
@@ -4445,9 +4131,8 @@ const struct Item gItems[] =
.description = sHM06Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM07_WATERFALL] =
@@ -4458,9 +4143,8 @@ const struct Item gItems[] =
.description = sHM07Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_HM08_DIVE] =
@@ -4471,9 +4155,8 @@ const struct Item gItems[] =
.description = sHM08Desc,
.importance = 1,
.pocket = POCKET_TM_HM,
- .type = 1,
+ .type = ITEM_USE_PARTY_MENU,
.fieldUseFunc = ItemUseOutOfBattle_TMHM,
- .secondaryId = 0,
},
[ITEM_15B] =
@@ -4483,9 +4166,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_15C] =
@@ -4495,9 +4177,8 @@ const struct Item gItems[] =
.price = 0,
.description = sDummyDesc,
.pocket = POCKET_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// FireRed/LeafGreen key items
@@ -4510,9 +4191,8 @@ const struct Item gItems[] =
.description = sOaksParcelDesc,
.importance = 2,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_POKE_FLUTE] =
@@ -4523,9 +4203,8 @@ const struct Item gItems[] =
.description = sPokeFluteDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SECRET_KEY] =
@@ -4536,9 +4215,8 @@ const struct Item gItems[] =
.description = sSecretKeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BIKE_VOUCHER] =
@@ -4549,9 +4227,8 @@ const struct Item gItems[] =
.description = sBikeVoucherDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_GOLD_TEETH] =
@@ -4562,9 +4239,8 @@ const struct Item gItems[] =
.description = sGoldTeethDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_OLD_AMBER] =
@@ -4575,9 +4251,8 @@ const struct Item gItems[] =
.description = sOldAmberDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_CARD_KEY] =
@@ -4588,9 +4263,8 @@ const struct Item gItems[] =
.description = sCardKeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_LIFT_KEY] =
@@ -4601,9 +4275,8 @@ const struct Item gItems[] =
.description = sLiftKeyDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_HELIX_FOSSIL] =
@@ -4614,9 +4287,8 @@ const struct Item gItems[] =
.description = sHelixFossilDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_DOME_FOSSIL] =
@@ -4627,9 +4299,8 @@ const struct Item gItems[] =
.description = sDomeFossilDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SILPH_SCOPE] =
@@ -4640,9 +4311,8 @@ const struct Item gItems[] =
.description = sSilphScopeDesc,
.importance = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BICYCLE] =
@@ -4654,9 +4324,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_TOWN_MAP] =
@@ -4668,9 +4337,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_VS_SEEKER] =
@@ -4682,9 +4350,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_FAME_CHECKER] =
@@ -4696,9 +4363,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_TM_CASE] =
@@ -4710,9 +4376,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_BERRY_POUCH] =
@@ -4724,9 +4389,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_TEACHY_TV] =
@@ -4738,9 +4402,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 2,
+ .type = ITEM_USE_FIELD,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_TRI_PASS] =
@@ -4752,9 +4415,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_RAINBOW_PASS] =
@@ -4766,9 +4428,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_TEA] =
@@ -4780,9 +4441,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_MYSTIC_TICKET] =
@@ -4794,9 +4454,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_AURORA_TICKET] =
@@ -4808,9 +4467,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_POWDER_JAR] =
@@ -4822,9 +4480,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_PowderJar,
- .secondaryId = 0,
},
[ITEM_RUBY] =
@@ -4836,9 +4493,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_SAPPHIRE] =
@@ -4850,9 +4506,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
// Emerald-specific key items
@@ -4866,9 +4521,8 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
[ITEM_OLD_SEA_MAP] =
@@ -4880,8 +4534,7 @@ const struct Item gItems[] =
.importance = 1,
.unk19 = 1,
.pocket = POCKET_KEY_ITEMS,
- .type = 4,
+ .type = ITEM_USE_BAG_MENU,
.fieldUseFunc = ItemUseOutOfBattle_CannotUse,
- .secondaryId = 0,
},
};
diff --git a/src/decompress.c b/src/decompress.c
index 007753303..335699449 100644
--- a/src/decompress.c
+++ b/src/decompress.c
@@ -86,7 +86,7 @@ void LoadSpecialPokePic(const struct CompressedSpriteSheet *src, void *dest, s32
{
if (species == SPECIES_UNOWN)
{
- u16 i = (((personality & 0x3000000) >> 18) | ((personality & 0x30000) >> 12) | ((personality & 0x300) >> 6) | (personality & 3)) % 0x1C;
+ u16 i = GET_UNOWN_LETTER(personality);
// The other Unowns are separate from Unown A.
if (i == 0)
@@ -308,7 +308,7 @@ void LoadSpecialPokePic_2(const struct CompressedSpriteSheet *src, void *dest, s
{
if (species == SPECIES_UNOWN)
{
- u16 i = (((personality & 0x3000000) >> 18) | ((personality & 0x30000) >> 12) | ((personality & 0x300) >> 6) | (personality & 3)) % 0x1C;
+ u16 i = GET_UNOWN_LETTER(personality);
// The other Unowns are separate from Unown A.
if (i == 0)
@@ -366,7 +366,7 @@ void LoadSpecialPokePic_DontHandleDeoxys(const struct CompressedSpriteSheet *src
{
if (species == SPECIES_UNOWN)
{
- u16 i = (((personality & 0x3000000) >> 18) | ((personality & 0x30000) >> 12) | ((personality & 0x300) >> 6) | (personality & 3)) % 0x1C;
+ u16 i = GET_UNOWN_LETTER(personality);
// The other Unowns are separate from Unown A.
if (i == 0)
diff --git a/src/decoration.c b/src/decoration.c
index b97ab4321..484398aba 100644
--- a/src/decoration.c
+++ b/src/decoration.c
@@ -113,7 +113,7 @@ EWRAM_DATA static u16 sDecorationsCursorPos = 0;
EWRAM_DATA static u16 sDecorationsScrollOffset = 0;
EWRAM_DATA u8 gCurDecorationIndex = 0;
EWRAM_DATA static u8 sCurDecorationCategory = DECORCAT_DESK;
-EWRAM_DATA static u32 filler_0203a174[2] = {};
+EWRAM_DATA static u32 sFiller[2] = {};
EWRAM_DATA static struct DecorationPCContext sDecorationContext = {};
EWRAM_DATA static u8 sDecorMenuWindowIds[WINDOW_COUNT] = {};
EWRAM_DATA static struct DecorationItemsMenu *sDecorationItemsMenu = NULL;
diff --git a/src/diploma.c b/src/diploma.c
index f243d09f9..8f04bb9ad 100644
--- a/src/diploma.c
+++ b/src/diploma.c
@@ -168,7 +168,7 @@ static const struct BgTemplate sDiplomaBgTemplates[2] =
static void InitDiplomaBg(void)
{
ResetBgsAndClearDma3BusyFlags(0);
- InitBgsFromTemplates(0, sDiplomaBgTemplates, 2);
+ InitBgsFromTemplates(0, sDiplomaBgTemplates, ARRAY_COUNT(sDiplomaBgTemplates));
SetBgTilemapBuffer(1, sDiplomaTilemapPtr);
SetGpuReg(REG_OFFSET_DISPCNT, DISPCNT_OBJ_ON | DISPCNT_OBJ_1D_MAP);
ShowBg(0);
diff --git a/src/easy_chat.c b/src/easy_chat.c
index 2590eea1a..6bb77bc84 100644
--- a/src/easy_chat.c
+++ b/src/easy_chat.c
@@ -4073,7 +4073,6 @@ static void sub_811D864(u8 arg0, u8 arg1)
{
int i, j;
u16 easyChatWord;
- u8 *str;
int y;
int var0;
diff --git a/src/ereader_screen.c b/src/ereader_screen.c
index 3f2cf3217..d27605c1d 100755
--- a/src/ereader_screen.c
+++ b/src/ereader_screen.c
@@ -211,7 +211,6 @@ static u32 sub_81D4EE4(u8 *arg0, u16 *arg1)
void task_add_00_ereader(void)
{
- int value;
struct Unk81D5014 *data;
u8 taskId = CreateTask(sub_81D5084, 0);
data = (struct Unk81D5014 *)gTasks[taskId].data;
diff --git a/src/event_object_movement.c b/src/event_object_movement.c
index 0cb4124a8..d9c06eb10 100644
--- a/src/event_object_movement.c
+++ b/src/event_object_movement.c
@@ -130,7 +130,6 @@ static struct ObjectEventTemplate *FindObjectEventTemplateByLocalId(u8 localId,
static void ClearObjectEventMovement(struct ObjectEvent *, struct Sprite *);
static void ObjectEventSetSingleMovement(struct ObjectEvent *, struct Sprite *, u8);
static void oamt_npc_ministep_reset(struct Sprite *, u8, u8);
-static void UpdateObjectEventSpriteSubpriorityAndVisibility(struct Sprite *);
static void InitSpriteForFigure8Anim(struct Sprite *sprite);
static bool8 AnimateSpriteInFigure8(struct Sprite *sprite);
static void UpdateObjectEventSprite(struct Sprite *);
diff --git a/src/evolution_scene.c b/src/evolution_scene.c
index d41bc5970..a8de8a555 100644
--- a/src/evolution_scene.c
+++ b/src/evolution_scene.c
@@ -60,7 +60,6 @@ static void CB2_TradeEvolutionSceneUpdate(void);
static void EvoDummyFunc(void);
static void VBlankCB_EvolutionScene(void);
static void VBlankCB_TradeEvolutionScene(void);
-static void sub_81150D8(void);
static void sub_8140134(void);
static void EvoScene_DoMonAnimation(u8 monSpriteId, u16 speciesId);
static bool32 EvoScene_IsMonAnimFinished(u8 monSpriteId);
diff --git a/src/faraway_island.c b/src/faraway_island.c
index e3d8444c9..bc0814652 100755
--- a/src/faraway_island.c
+++ b/src/faraway_island.c
@@ -372,7 +372,6 @@ void SetMewAboveGrass(void)
{
s16 x;
s16 y;
- u8 spriteId;
struct ObjectEvent *mew = &gObjectEvents[GetMewObjectEventId()];
mew->invisible = FALSE;
diff --git a/src/fieldmap.c b/src/fieldmap.c
index 296c4edf2..2961d2f49 100644
--- a/src/fieldmap.c
+++ b/src/fieldmap.c
@@ -28,7 +28,7 @@ EWRAM_DATA static u16 gBackupMapData[MAX_MAP_DATA_SIZE] = {0};
EWRAM_DATA struct MapHeader gMapHeader = {0};
EWRAM_DATA struct Camera gCamera = {0};
EWRAM_DATA static struct ConnectionFlags gMapConnectionFlags = {0};
-EWRAM_DATA static u32 sFiller_02037344 = 0; // without this, the next file won't align properly
+EWRAM_DATA static u32 sFiller = 0; // without this, the next file won't align properly
struct BackupMapLayout gBackupMapLayout;
diff --git a/src/fldeff_cut.c b/src/fldeff_cut.c
index 0458f7621..446633a53 100644
--- a/src/fldeff_cut.c
+++ b/src/fldeff_cut.c
@@ -62,7 +62,6 @@ static void HandleLongGrassOnHyper(u8, s16, s16);
static u8 sCutSquareSide;
static u8 sTileCountFromPlayer_X;
static u8 sTileCountFromPlayer_Y;
-static u32 sUnused;
static bool8 sHyperCutTiles[CUT_HYPER_AREA];
// EWRAM variables
diff --git a/src/fldeff_escalator.c b/src/fldeff_escalator.c
index 7a96eaa82..733dca722 100644
--- a/src/fldeff_escalator.c
+++ b/src/fldeff_escalator.c
@@ -10,8 +10,6 @@ static EWRAM_DATA u8 sEscalatorAnim_TaskId = 0;
static void SetEscalatorMetatile(u8 taskId, const s16 *metatileIds, u16 metatileMasks);
static void Task_DrawEscalator(u8 taskId);
-static void Task_DrawTeleporterHousing(u8 taskId);
-static void Task_DrawTeleporterCable(u8 taskId);
#define ESCALATOR_STAGES 3
#define LAST_ESCALATOR_STAGE (ESCALATOR_STAGES - 1)
diff --git a/src/frontier_util.c b/src/frontier_util.c
index db5f86aef..095c750a6 100644
--- a/src/frontier_util.c
+++ b/src/frontier_util.c
@@ -1513,9 +1513,9 @@ static void ShowLinkContestResultsWindow(void)
AddTextPrinterParameterized(gRecordsWindowId, 1, gText_Smart, x, 89, TEXT_SPEED_FF, NULL);
AddTextPrinterParameterized(gRecordsWindowId, 1, gText_Tough, x, 105, TEXT_SPEED_FF, NULL);
- for (i = 0; i < 5; i++)
+ for (i = 0; i < CONTEST_CATEGORIES_COUNT; i++)
{
- for (j = 0; j < 4; j++)
+ for (j = 0; j < CONTESTANT_COUNT; j++)
{
ConvertIntToDecimalStringN(gStringVar4, gSaveBlock2Ptr->contestLinkResults[i][j], STR_CONV_MODE_RIGHT_ALIGN, 4);
AddTextPrinterParameterized(gRecordsWindowId, 1, gStringVar4, (j * 38) + 64, (i * 16) + 41, TEXT_SPEED_FF, NULL);
diff --git a/src/intro.c b/src/intro.c
index 7dab2ad46..7c92913b6 100644
--- a/src/intro.c
+++ b/src/intro.c
@@ -986,8 +986,6 @@ static void SerialCB_CopyrightScreen(void)
static u8 SetUpCopyrightScreen(void)
{
- u16 ime;
-
switch (gMain.state)
{
case 0:
@@ -1302,7 +1300,6 @@ static void Task_IntroStartBikeRide(u8 taskId)
static void Task_IntroHandleBikeAndFlygonMovement(u8 taskId)
{
- s16 a;
u16 offset;
if (gIntroFrameCounter == 1856)
diff --git a/src/item.c b/src/item.c
index 0b6366048..91d2f1a0a 100644
--- a/src/item.c
+++ b/src/item.c
@@ -102,8 +102,8 @@ void CopyItemNameHandlePlural(u16 itemId, u8 *dst, u32 quantity)
}
else
{
- if (itemId >= ITEM_CHERI_BERRY && itemId <= ITEM_ENIGMA_BERRY)
- GetBerryCountString(dst, gBerries[itemId - ITEM_CHERI_BERRY].name, quantity);
+ if (itemId >= FIRST_BERRY_INDEX && itemId <= LAST_BERRY_INDEX)
+ GetBerryCountString(dst, gBerries[itemId - FIRST_BERRY_INDEX].name, quantity);
else
StringCopy(dst, ItemId_GetName(itemId));
}
diff --git a/src/item_menu.c b/src/item_menu.c
index 931cba2bf..6d30038d0 100755
--- a/src/item_menu.c
+++ b/src/item_menu.c
@@ -627,7 +627,6 @@ void CB2_Bag(void)
bool8 SetupBagMenu(void)
{
- u32 index;
u8 taskId;
switch (gMain.state)
@@ -742,7 +741,7 @@ void BagMenu_InitBGs(void)
ResetVramOamAndBgCntRegs();
memset(gBagMenu->tilemapBuffer, 0, 0x800);
ResetBgsAndClearDma3BusyFlags(0);
- InitBgsFromTemplates(0, sBgTemplates_ItemMenu, 3);
+ InitBgsFromTemplates(0, sBgTemplates_ItemMenu, ARRAY_COUNT(sBgTemplates_ItemMenu));
SetBgTilemapBuffer(2, gBagMenu->tilemapBuffer);
ResetAllBgsCoordinates();
ScheduleBgCopyTilemapToVram(2);
@@ -865,7 +864,7 @@ void GetItemName(s8 *dest, u16 itemId)
}
break;
case BERRIES_POCKET:
- ConvertIntToDecimalStringN(gStringVar1, itemId - ITEM_CHERI_BERRY + 1, STR_CONV_MODE_LEADING_ZEROS, 2);
+ ConvertIntToDecimalStringN(gStringVar1, itemId - FIRST_BERRY_INDEX + 1, STR_CONV_MODE_LEADING_ZEROS, 2);
CopyItemName(itemId, gStringVar2);
StringExpandPlaceholders(dest, gText_NumberVar1Clear7Var2);
break;
@@ -1721,7 +1720,7 @@ void ItemMenu_UseOutOfBattle(u8 taskId)
if (ItemId_GetFieldFunc(gSpecialVar_ItemId))
{
BagMenu_RemoveSomeWindow();
- if (CalculatePlayerPartyCount() == 0 && ItemId_GetType(gSpecialVar_ItemId) == 1)
+ if (CalculatePlayerPartyCount() == 0 && ItemId_GetType(gSpecialVar_ItemId) == ITEM_USE_PARTY_MENU)
BagMenu_PrintThereIsNoPokemon(taskId);
else
{
diff --git a/src/item_use.c b/src/item_use.c
index df6a35bc9..af0ca9ee5 100755
--- a/src/item_use.c
+++ b/src/item_use.c
@@ -77,13 +77,13 @@ EWRAM_DATA static void(*sItemUseOnFieldCB)(u8 taskId) = NULL;
// Below is set TRUE by UseRegisteredKeyItemOnField
#define tUsingRegisteredKeyItem data[3]
-// .rodata
-
+// UB here if an item with type ITEM_USE_MAIL or ITEM_USE_BAG_MENU uses SetUpItemUseCallback
+// Never occurs in vanilla, but can occur with improperly created items
static const MainCallback sItemUseCallbacks[] =
{
- CB2_ShowPartyMenuForItemUse,
- CB2_ReturnToField,
- NULL,
+ [ITEM_USE_PARTY_MENU - 1] = CB2_ShowPartyMenuForItemUse,
+ [ITEM_USE_FIELD - 1] = CB2_ReturnToField,
+ [ITEM_USE_PBLOCK_CASE - 1] = NULL,
};
static const u8 sClockwiseDirections[] = {DIR_NORTH, DIR_EAST, DIR_SOUTH, DIR_WEST};
@@ -94,13 +94,12 @@ static const struct YesNoFuncTable sUseTMHMYesNoFuncTable =
.noFunc = BagMenu_InitListsMenu,
};
-// .text
-
+#define tEnigmaBerryType data[4]
static void SetUpItemUseCallback(u8 taskId)
{
u8 type;
if (gSpecialVar_ItemId == ITEM_ENIGMA_BERRY)
- type = gTasks[taskId].data[4] - 1;
+ type = gTasks[taskId].tEnigmaBerryType - 1;
else
type = ItemId_GetType(gSpecialVar_ItemId) - 1;
if (!InBattlePyramid())
@@ -218,9 +217,9 @@ void ItemUseOutOfBattle_Bike(u8 taskId)
static void ItemUseOnFieldCB_Bike(u8 taskId)
{
- if (!ItemId_GetSecondaryId(gSpecialVar_ItemId))
+ if (ItemId_GetSecondaryId(gSpecialVar_ItemId) == MACH_BIKE)
GetOnOffBike(PLAYER_AVATAR_FLAG_MACH_BIKE);
- else
+ else // ACRO_BIKE
GetOnOffBike(PLAYER_AVATAR_FLAG_ACRO_BIKE);
ScriptUnfreezeObjectEvents();
ScriptContext2_Disable();
@@ -1065,28 +1064,28 @@ void ItemUseOutOfBattle_EnigmaBerry(u8 taskId)
case ITEM_EFFECT_SPDEF_EV:
case ITEM_EFFECT_SPEED_EV:
case ITEM_EFFECT_DEF_EV:
- gTasks[taskId].data[4] = 1;
+ gTasks[taskId].tEnigmaBerryType = ITEM_USE_PARTY_MENU;
ItemUseOutOfBattle_Medicine(taskId);
break;
case ITEM_EFFECT_SACRED_ASH:
- gTasks[taskId].data[4] = 1;
+ gTasks[taskId].tEnigmaBerryType = ITEM_USE_PARTY_MENU;
ItemUseOutOfBattle_SacredAsh(taskId);
break;
case ITEM_EFFECT_RAISE_LEVEL:
- gTasks[taskId].data[4] = 1;
+ gTasks[taskId].tEnigmaBerryType = ITEM_USE_PARTY_MENU;
ItemUseOutOfBattle_RareCandy(taskId);
break;
case ITEM_EFFECT_PP_UP:
case ITEM_EFFECT_PP_MAX:
- gTasks[taskId].data[4] = 1;
+ gTasks[taskId].tEnigmaBerryType = ITEM_USE_PARTY_MENU;
ItemUseOutOfBattle_PPUp(taskId);
break;
case ITEM_EFFECT_HEAL_PP:
- gTasks[taskId].data[4] = 1;
+ gTasks[taskId].tEnigmaBerryType = ITEM_USE_PARTY_MENU;
ItemUseOutOfBattle_PPRecovery(taskId);
break;
default:
- gTasks[taskId].data[4] = 4;
+ gTasks[taskId].tEnigmaBerryType = ITEM_USE_BAG_MENU;
ItemUseOutOfBattle_CannotUse(taskId);
break;
}
diff --git a/src/librfu_rfu.c b/src/librfu_rfu.c
index fe1d10834..7cb9b1bd6 100644
--- a/src/librfu_rfu.c
+++ b/src/librfu_rfu.c
@@ -1724,7 +1724,6 @@ static void rfu_constructSendLLFrame(void)
u32 pakcketSize, currSize;
u8 i;
u8 *llf_p;
- struct RfuSlotStatusNI *slotStatusNI;
if (gRfuLinkStatus->parentChild != MODE_NEUTRAL
&& gRfuLinkStatus->sendSlotNIFlag | gRfuLinkStatus->recvSlotNIFlag | gRfuLinkStatus->sendSlotUNIFlag)
diff --git a/src/mail.c b/src/mail.c
index 04464f06b..71e98b42a 100644
--- a/src/mail.c
+++ b/src/mail.c
@@ -125,7 +125,7 @@ static void CB2_ExitMailReadFreeVars(void);
// .rodata
-static const struct BgTemplate sUnknown_0859F290[] = {
+static const struct BgTemplate sBgTemplates[] = {
{
.bg = 0,
.charBaseIndex = 2,
@@ -254,7 +254,7 @@ void ReadMail(struct MailStruct *mail, void (*callback)(void), bool8 flag)
sMailRead->parserMultiple = ConvertEasyChatWordsToString;
if (IS_ITEM_MAIL(mail->itemId))
{
- sMailRead->mailType = mail->itemId - ITEM_ORANGE_MAIL;
+ sMailRead->mailType = mail->itemId - FIRST_MAIL_INDEX;
}
else
{
@@ -279,10 +279,10 @@ void ReadMail(struct MailStruct *mail, void (*callback)(void), bool8 flag)
default:
sMailRead->animsActive = 0;
break;
- case ITEM_BEAD_MAIL - ITEM_ORANGE_MAIL:
+ case ITEM_BEAD_MAIL - FIRST_MAIL_INDEX:
sMailRead->animsActive = 1;
break;
- case ITEM_DREAM_MAIL - ITEM_ORANGE_MAIL:
+ case ITEM_DREAM_MAIL - FIRST_MAIL_INDEX:
sMailRead->animsActive = 2;
break;
}
@@ -336,7 +336,7 @@ static bool8 MailReadBuildGraphics(void)
break;
case 6:
ResetBgsAndClearDma3BusyFlags(0);
- InitBgsFromTemplates(0, sUnknown_0859F290, 3);
+ InitBgsFromTemplates(0, sBgTemplates, ARRAY_COUNT(sBgTemplates));
SetBgTilemapBuffer(1, sMailRead->bg1TilemapBuffer);
SetBgTilemapBuffer(2, sMailRead->bg2TilemapBuffer);
break;
diff --git a/src/main_menu.c b/src/main_menu.c
index 2c27b673a..74af96da8 100644
--- a/src/main_menu.c
+++ b/src/main_menu.c
@@ -1799,7 +1799,7 @@ static void CB2_NewGameBirchSpeech_ReturnFromNamingScreen(void)
ResetBgsAndClearDma3BusyFlags(0);
SetGpuReg(REG_OFFSET_DISPCNT, 0);
SetGpuReg(REG_OFFSET_DISPCNT, DISPCNT_OBJ_ON | DISPCNT_OBJ_1D_MAP);
- InitBgsFromTemplates(0, sMainMenuBgTemplates, 2);
+ InitBgsFromTemplates(0, sMainMenuBgTemplates, ARRAY_COUNT(sMainMenuBgTemplates));
InitBgFromTemplate(&sBirchBgTemplate);
SetVBlankCallback(NULL);
SetGpuReg(REG_OFFSET_BG2CNT, 0);
@@ -2097,7 +2097,7 @@ static void NewGameBirchSpeech_ShowGenderMenu(void)
{
DrawMainMenuWindowBorder(&gNewGameBirchSpeechTextWindows[1], 0xF3);
FillWindowPixelBuffer(1, PIXEL_FILL(1));
- PrintMenuTable(1, 2, sMenuActions_Gender);
+ PrintMenuTable(1, ARRAY_COUNT(sMenuActions_Gender), sMenuActions_Gender);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(1, 2, 0);
PutWindowTilemap(1);
CopyWindowToVram(1, 3);
diff --git a/src/match_call.c b/src/match_call.c
index 723562ade..7e8d0c38a 100644
--- a/src/match_call.c
+++ b/src/match_call.c
@@ -1494,7 +1494,6 @@ static const struct MatchCallText *GetGeneralMatchCallText(int matchCallId, u8 *
int count;
u32 topic, id;
u16 rand;
- u16 var3;
rand = Random();
if (!(rand & 1))
diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c
index af68c6116..c97ee94f3 100644
--- a/src/mauville_old_man.c
+++ b/src/mauville_old_man.c
@@ -1324,7 +1324,6 @@ static void PrintStoryList(void)
{
s32 i;
s32 width = GetStringWidth(1, gText_Exit, 0);
- u8 tileWidth;
for (i = 0; i < NUM_STORYTELLER_TALES; i++)
{
s32 curWidth;
diff --git a/src/mevent_server.c b/src/mevent_server.c
index 0d3afea30..2e7b3d89a 100644
--- a/src/mevent_server.c
+++ b/src/mevent_server.c
@@ -288,8 +288,8 @@ static u32 (*const func_tbl[])(struct mevent_srv_common *) = {
static u32 mevent_srv_exec_common(struct mevent_srv_common * svr)
{
u32 response;
- AGB_ASSERT(svr->mainseqno < NELEMS(func_tbl));
+ AGB_ASSERT(svr->mainseqno < ARRAY_COUNT(func_tbl));
response = func_tbl[svr->mainseqno](svr);
- AGB_ASSERT(svr->mainseqno < NELEMS(func_tbl));
+ AGB_ASSERT(svr->mainseqno < ARRAY_COUNT(func_tbl));
return response;
}
diff --git a/src/minigame_countdown.c b/src/minigame_countdown.c
index cd5710d44..d2f7d3ea8 100644
--- a/src/minigame_countdown.c
+++ b/src/minigame_countdown.c
@@ -14,7 +14,6 @@ static void sub_802E83C(u8 taskId);
static void sub_802E8C8(u8 taskId);
static void sub_802EA50(u8 taskId);
static void sub_802EAB0(u8 taskId);
-static void sub_802EB98(u8 taskId);
static void Task_MinigameCountdown(u8 taskId);
static bool32 RunMinigameCountdownDigitsAnim(u8 spriteId);
static bool32 IsStartGraphicAnimRunning(u8 spriteId);
diff --git a/src/overworld.c b/src/overworld.c
index 72aa17929..cbfc70898 100644
--- a/src/overworld.c
+++ b/src/overworld.c
@@ -174,7 +174,6 @@ static u8 sPlayerTradingStates[MAX_LINK_PLAYERS];
static u16 (*sPlayerKeyInterceptCallback)(u32);
static bool8 sUnknown_03000E18;
static u8 sRfuKeepAliveTimer;
-static u32 sUnusedVar;
// IWRAM common
u16 *gBGTilemapBuffers1;
diff --git a/src/palette.c b/src/palette.c
index 788cb4d64..ece753d21 100644
--- a/src/palette.c
+++ b/src/palette.c
@@ -60,7 +60,7 @@ ALIGNED(4) EWRAM_DATA u16 gPlttBufferUnfaded[PLTT_BUFFER_SIZE] = {0};
ALIGNED(4) EWRAM_DATA u16 gPlttBufferFaded[PLTT_BUFFER_SIZE] = {0};
EWRAM_DATA struct PaletteStruct sPaletteStructs[0x10] = {0};
EWRAM_DATA struct PaletteFadeControl gPaletteFade = {0};
-static EWRAM_DATA u32 gFiller_2037FE0 = 0;
+static EWRAM_DATA u32 sFiller = 0;
static EWRAM_DATA u32 sPlttBufferTransferPending = 0;
EWRAM_DATA u8 gPaletteDecompressionBuffer[PLTT_DECOMP_BUFFER_SIZE] = {0};
diff --git a/src/party_menu.c b/src/party_menu.c
index 8aca27f47..256558985 100755
--- a/src/party_menu.c
+++ b/src/party_menu.c
@@ -151,7 +151,7 @@ static EWRAM_DATA u16 *sSlot1TilemapBuffer = 0; // for switching party slots
static EWRAM_DATA u16 *sSlot2TilemapBuffer = 0; //
EWRAM_DATA u8 gSelectedOrderFromParty[MAX_FRONTIER_PARTY_SIZE] = {0};
static EWRAM_DATA u16 sPartyMenuItemId = 0;
-static EWRAM_DATA u16 sUnused_0203CEFE = 0;
+static EWRAM_DATA u16 sUnused = 0;
EWRAM_DATA u8 gBattlePartyCurrentOrder[PARTY_SIZE / 2] = {0}; // bits 0-3 are the current pos of Slot 1, 4-7 are Slot 2, and so on
// IWRAM common
diff --git a/src/player_pc.c b/src/player_pc.c
index 928aac706..1f293a195 100644
--- a/src/player_pc.c
+++ b/src/player_pc.c
@@ -443,7 +443,7 @@ static void InitItemStorageMenu(u8 taskId, u8 var)
windowTemplate.width = GetMaxWidthInMenuTable(gPCText_ItemPCOptionsText, 4);
data[4] = AddWindow(&windowTemplate);
SetStandardWindowBorderStyle(data[4], 0);
- PrintMenuTable(data[4], 4, gPCText_ItemPCOptionsText);
+ PrintMenuTable(data[4], ARRAY_COUNT(gPCText_ItemPCOptionsText), gPCText_ItemPCOptionsText);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(data[4], 4, var);
ScheduleBgCopyTilemapToVram(0);
ItemStorageMenuPrint(gPCText_OptionDescList[var]);
@@ -686,7 +686,7 @@ static void Mailbox_ReturnToPlayerPC(u8 taskId)
static void Mailbox_PrintMailOptions(u8 taskId)
{
u8 r4 = sub_81D1C84(2);
- PrintMenuTable(r4, 4, gMailboxMailOptions);
+ PrintMenuTable(r4, ARRAY_COUNT(gMailboxMailOptions), gMailboxMailOptions);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(r4, 4, 0);
ScheduleBgCopyTilemapToVram(0);
gTasks[taskId].func = Mailbox_MailOptionsProcessInput;
@@ -1058,7 +1058,6 @@ static void ItemStorage_ProcessWithdrawTossInput(u8 taskId)
s16 *data;
bool32 toss;
u32 i, x;
- u8 windowId;
const u8* text;
data = gTasks[taskId].data;
diff --git a/src/pokeblock_feed.c b/src/pokeblock_feed.c
index 32db6c717..a930523ce 100644
--- a/src/pokeblock_feed.c
+++ b/src/pokeblock_feed.c
@@ -61,7 +61,6 @@ static void HandleInitWindows(void);
static void LaunchPokeblockFeedTask(void);
static void SetPokeblockSpritePal(u8 pokeblockCaseId);
static void sub_817A5CC(void);
-static void sub_8148108(u8 spriteId, bool8 a1);
static void DoPokeblockCaseThrowEffect(u8 spriteId, bool8 arg1);
static void PrepareMonToMoveToPokeblock(u8 spriteId);
static void Task_HandleMonAtePokeblock(u8 taskId);
diff --git a/src/pokedex.c b/src/pokedex.c
index 6aa347994..c0236020e 100644
--- a/src/pokedex.c
+++ b/src/pokedex.c
@@ -1373,7 +1373,7 @@ static const struct SearchOptionText sDexSearchColorOptions[] =
{},
};
-static const struct SearchOptionText sDexSearchTypeOptions[] =
+static const struct SearchOptionText sDexSearchTypeOptions[NUMBER_OF_MON_TYPES + 1] = // + 2 for "None" and terminator, - 1 for Mystery
{
{gText_DexEmptyString, gText_DexSearchTypeNone},
{gText_DexEmptyString, gTypeNames[TYPE_NORMAL]},
@@ -1407,7 +1407,7 @@ static const u8 sOrderOptions[] =
ORDER_SMALLEST,
};
-static const u8 sDexSearchTypeIds[] =
+static const u8 sDexSearchTypeIds[NUMBER_OF_MON_TYPES] =
{
TYPE_NONE,
TYPE_NORMAL,
@@ -1587,9 +1587,6 @@ static void ResetPokedexView(struct PokedexView *pokedexView)
void CB2_OpenPokedex(void)
{
- u8 *addr;
- u32 size;
-
switch (gMain.state)
{
case 0:
diff --git a/src/pokedex_area_screen.c b/src/pokedex_area_screen.c
index 7a3b38dc2..b63b00290 100755
--- a/src/pokedex_area_screen.c
+++ b/src/pokedex_area_screen.c
@@ -489,7 +489,6 @@ static bool8 MonListHasMon(const struct WildPokemonInfo *info, u16 species, u16
static void BuildAreaGlowTilemap(void)
{
u16 i, y, x, j;
- u16 val;
for (i = 0; i < ARRAY_COUNT(sPokedexAreaScreen->areaGlowTilemap); i++)
sPokedexAreaScreen->areaGlowTilemap[i] = 0;
diff --git a/src/pokemon.c b/src/pokemon.c
index 5829bbd0a..3a2e88aae 100644
--- a/src/pokemon.c
+++ b/src/pokemon.c
@@ -2304,14 +2304,14 @@ void CreateMonWithGenderNatureLetter(struct Pokemon *mon, u16 species, u8 level,
{
u32 personality;
- if ((u8)(unownLetter - 1) < 28)
+ if ((u8)(unownLetter - 1) < NUM_UNOWN_FORMS)
{
u16 actualLetter;
do
{
personality = Random32();
- actualLetter = ((((personality & 0x3000000) >> 18) | ((personality & 0x30000) >> 12) | ((personality & 0x300) >> 6) | (personality & 0x3)) % 28);
+ actualLetter = GET_UNOWN_LETTER(personality);
}
while (nature != GetNatureFromPersonality(personality)
|| gender != GetGenderFromSpeciesAndPersonality(species, personality)
@@ -4658,7 +4658,6 @@ bool8 PokemonUseItemEffects(struct Pokemon *mon, u16 item, u8 partyIndex, u8 mov
u32 var_28 = 0;
u16 heldItem;
u8 r10;
- u32 r4;
u32 r5;
s8 r2;
u16 evCount;
diff --git a/src/pokemon_icon.c b/src/pokemon_icon.c
index b85a29151..065b8e22e 100644
--- a/src/pokemon_icon.c
+++ b/src/pokemon_icon.c
@@ -1099,7 +1099,7 @@ u16 GetUnownLetterByPersonality(u32 personality)
if (!personality)
return 0;
else
- return (((personality & 0x3000000) >> 18) | ((personality & 0x30000) >> 12) | ((personality & 0x300) >> 6) | (personality & 0x3)) % 0x1C;
+ return GET_UNOWN_LETTER(personality);
}
u16 sub_80D2E84(u16 species)
diff --git a/src/pokemon_storage_system.c b/src/pokemon_storage_system.c
index 4be1cf729..50fc04372 100644
--- a/src/pokemon_storage_system.c
+++ b/src/pokemon_storage_system.c
@@ -8389,7 +8389,7 @@ static u8 sub_80D0894(void)
static void sub_80D08CC(void)
{
- s32 i, j, r8, r9;
+ s32 i, j;
s32 rowCount, columnCount;
u8 boxId;
u8 monArrayId;
diff --git a/src/pokenav_conditions_3.c b/src/pokenav_conditions_3.c
index d02d844d0..2a1dda1fa 100644
--- a/src/pokenav_conditions_3.c
+++ b/src/pokenav_conditions_3.c
@@ -419,7 +419,7 @@ static u32 LoopedTask_OpenConditionSearchResults(s32 state)
switch (state)
{
case 0:
- InitBgTemplates(sConditionSearchResultBgTemplates, NELEMS(sConditionSearchResultBgTemplates));
+ InitBgTemplates(sConditionSearchResultBgTemplates, ARRAY_COUNT(sConditionSearchResultBgTemplates));
DecompressAndCopyTileDataToVram(1, sConditionSearchResultTiles, 0, 0, 0);
SetBgTilemapBuffer(1, searchList->buff);
CopyToBgTilemapBuffer(1, sConditionSearchResultTilemap, 0, 0);
diff --git a/src/pokenav_menu_handler_2.c b/src/pokenav_menu_handler_2.c
index 3fcd41dc9..eea8131a9 100644
--- a/src/pokenav_menu_handler_2.c
+++ b/src/pokenav_menu_handler_2.c
@@ -750,7 +750,7 @@ static void LoadPokenavOptionPalettes(void)
{
s32 i;
- for (i = 0; i < NELEMS(sPokenavOptionsSpriteSheets); i++)
+ for (i = 0; i < ARRAY_COUNT(sPokenavOptionsSpriteSheets); i++)
LoadCompressedSpriteSheet(&sPokenavOptionsSpriteSheets[i]);
Pokenav_AllocAndLoadPalettes(sPokenavOptionsSpritePalettes);
}
diff --git a/src/pokenav_ribbons_1.c b/src/pokenav_ribbons_1.c
index 9c171dd45..397e1e749 100644
--- a/src/pokenav_ribbons_1.c
+++ b/src/pokenav_ribbons_1.c
@@ -427,7 +427,7 @@ static u32 LoopedTask_OpenRibbonsMonList(s32 state)
switch (state)
{
case 0:
- InitBgTemplates(sMonRibbonListBgTemplates, NELEMS(sMonRibbonListBgTemplates));
+ InitBgTemplates(sMonRibbonListBgTemplates, ARRAY_COUNT(sMonRibbonListBgTemplates));
DecompressAndCopyTileDataToVram(1, sMonRibbonListFrameTiles, 0, 0, 0);
SetBgTilemapBuffer(1, monMenu->buff);
CopyToBgTilemapBuffer(1, sMonRibbonListFrameTilemap, 0, 0);
diff --git a/src/record_mixing.c b/src/record_mixing.c
index 898459c0a..2028cc647 100644
--- a/src/record_mixing.c
+++ b/src/record_mixing.c
@@ -94,7 +94,6 @@ static void *sApprenticesSave;
static void *sBattleTowerSave_Duplicate;
static u32 sRecordStructSize;
static u8 gUnknown_03001160;
-static u32 filler_03001164;
static struct PlayerHallRecords *gUnknown_03001168[3];
static EWRAM_DATA struct RecordMixingDayCareMail gUnknown_02039F9C = {0};
diff --git a/src/region_map.c b/src/region_map.c
index c2a5b4e9c..22b925a6f 100644
--- a/src/region_map.c
+++ b/src/region_map.c
@@ -1677,7 +1677,7 @@ void CB2_OpenFlyMap(void)
break;
case 1:
ResetBgsAndClearDma3BusyFlags(0);
- InitBgsFromTemplates(1, sFlyMapBgTemplates, 3);
+ InitBgsFromTemplates(1, sFlyMapBgTemplates, ARRAY_COUNT(sFlyMapBgTemplates));
gMain.state++;
break;
case 2:
diff --git a/src/save_failed_screen.c b/src/save_failed_screen.c
index 9bf0e7ed4..50ceeb74e 100644
--- a/src/save_failed_screen.c
+++ b/src/save_failed_screen.c
@@ -62,7 +62,7 @@ static const struct OamData sClockOamData =
.affineParam = 0
};
-static const struct BgTemplate gUnknown_085EFD88[3] =
+static const struct BgTemplate sBgTemplates[3] =
{
{
.bg = 0,
@@ -212,7 +212,7 @@ static void CB2_SaveFailedScreen(void)
LZ77UnCompVram(gBirchGrassTilemap, (void *)(BG_SCREEN_ADDR(15)));
LZ77UnCompVram(sSaveFailedClockGfx, (void *)(VRAM + 0x10020));
ResetBgsAndClearDma3BusyFlags(0);
- InitBgsFromTemplates(0, gUnknown_085EFD88, 3);
+ InitBgsFromTemplates(0, sBgTemplates, ARRAY_COUNT(sBgTemplates));
SetBgTilemapBuffer(0, (void *)&gDecompressionBuffer[0x2000]);
CpuFill32(0, &gDecompressionBuffer[0x2000], 0x800);
LoadBgTiles(0, gTextWindowFrame1_Gfx, 0x120, 0x214);
diff --git a/src/script.c b/src/script.c
index 9ba1a7429..e6557aa75 100644
--- a/src/script.c
+++ b/src/script.c
@@ -11,9 +11,7 @@ extern const u8* gUnknown_020375C0;
// ewram bss
static u8 sScriptContext1Status;
-static u32 sUnusedVariable1;
static struct ScriptContext sScriptContext1;
-static u32 sUnusedVariable2;
static struct ScriptContext sScriptContext2;
static bool8 sScriptContext2Enabled;
diff --git a/src/secret_base.c b/src/secret_base.c
index 8e0929593..d49eef277 100644
--- a/src/secret_base.c
+++ b/src/secret_base.c
@@ -996,7 +996,7 @@ static void ShowRegistryMenuActions(u8 taskId)
template.width = GetMaxWidthInMenuTable(sRegistryMenuActions, 2);
data[7] = AddWindow(&template);
SetStandardWindowBorderStyle(data[7], 0);
- PrintMenuTable(data[7], 2, sRegistryMenuActions);
+ PrintMenuTable(data[7], ARRAY_COUNT(sRegistryMenuActions), sRegistryMenuActions);
InitMenuInUpperLeftCornerPlaySoundWhenAPressed(data[7], 2, 0);
ScheduleBgCopyTilemapToVram(0);
gTasks[taskId].func = HandleRegistryMenuActionsInput;
diff --git a/src/shop.c b/src/shop.c
index 44ab0885c..a447982fc 100755
--- a/src/shop.c
+++ b/src/shop.c
@@ -489,7 +489,6 @@ static void BuyMenuFreeMemory(void)
static void BuyMenuBuildListMenuTemplate(void)
{
u16 i;
- u16 itemCount;
gUnknown_02039F74 = Alloc((gMartInfo.itemCount + 1) * sizeof(*gUnknown_02039F74));
gUnknown_02039F78 = Alloc((gMartInfo.itemCount + 1) * sizeof(*gUnknown_02039F78));
diff --git a/src/starter_choose.c b/src/starter_choose.c
index 771db961e..f7ffcfc2c 100644
--- a/src/starter_choose.c
+++ b/src/starter_choose.c
@@ -378,7 +378,6 @@ static void VblankCB_StarterChoose(void)
void CB2_ChooseStarter(void)
{
- u16 savedIme;
u8 taskId;
u8 spriteId;
diff --git a/src/tv.c b/src/tv.c
index 748915c7a..1e112332f 100644
--- a/src/tv.c
+++ b/src/tv.c
@@ -2085,7 +2085,6 @@ static void sub_80EDE98(TVShow *show)
u16 k;
u8 n;
u8 deco;
- u8 x;
for (i = 0; i < DECOR_MAX_SECRET_BASE; i ++)
{
@@ -4095,7 +4094,6 @@ static void sub_80F0E58(PokeNews *dest[16], PokeNews *src[16])
static bool8 sub_80F0E84(PokeNews *dest, PokeNews *src, s8 slot)
{
u8 i;
- u8 kind;
if (src->kind == POKENEWS_NONE)
{
@@ -6602,7 +6600,6 @@ static void DoTVShowSpotTheCuties(void)
{
TVShow *show;
u8 state;
- u32 playerId;
show = &gSaveBlock1Ptr->tvShows[gSpecialVar_0x8004];
gSpecialVar_Result = FALSE;
@@ -6707,7 +6704,6 @@ static void DoTVShowPokemonNewsBattleFrontier(void)
{
TVShow *show;
u8 state;
- u32 playerId;
show = &gSaveBlock1Ptr->tvShows[gSpecialVar_0x8004];
gSpecialVar_Result = FALSE;
@@ -6856,7 +6852,6 @@ static void DoTVShowWhatsNo1InHoennToday(void)
{
TVShow *show;
u8 state;
- u32 playerId;
show = &gSaveBlock1Ptr->tvShows[gSpecialVar_0x8004];
gSpecialVar_Result = FALSE;