From a04f8f6ee3074cc48f56e99f70cdbce8d1c88799 Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Mon, 23 Apr 2018 21:44:46 +0100 Subject: Convert item data files to .c (not compiling) --- src/items.c | 6788 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 6788 insertions(+) create mode 100644 src/items.c (limited to 'src') diff --git a/src/items.c b/src/items.c new file mode 100644 index 000000000..e2427c4cc --- /dev/null +++ b/src/items.c @@ -0,0 +1,6788 @@ +#include "global.h" +#include "item.h" +#include "item_use.h" +#include "constants/items.h" + +const u8 gDummyItemDescription[] = _("?????$"); +//pokeballs +const u8 gMasterBallItemDescription[] = _("The best BALL that\ncatches a POKéMON\nwithout fail.$"); +const u8 gUltraBallItemDescription[] = _("A better BALL with\na higher catch rate\nthan a GREAT BALL.$"); +const u8 gGreatBallItemDescription[] = _("A good BALL with a\nhigher catch rate\nthan a POKé BALL.$"); +const u8 gPokeBallItemDescription[] = _("A tool used for\ncatching wild\nPOKéMON.$"); +const u8 gSafariBallItemDescription[] = _("A special BALL that\nis used only in the\nSAFARI ZONE.$"); +const u8 gNetBallItemDescription[] = _("A BALL that works\nwell on WATER- and\nBUG-type POKéMON.$"); +const u8 gDiveBallItemDescription[] = _("A BALL that works\nbetter on POKéMON\non the ocean floor.$"); +const u8 gNestBallItemDescription[] = _("A BALL that works\nbetter on weaker\nPOKéMON.$"); +const u8 gRepeatBallItemDescription[] = _("A BALL that works\nbetter on POKéMON\ncaught before.$"); +const u8 gTimerBallItemDescription[] = _("A BALL that gains\npower in battles\ntaking many turns.$"); +const u8 gLuxuryBallItemDescription[] = _("A cozy BALL that\nmakes POKéMON\nmore friendly.$"); +const u8 gPremierBallItemDescription[] = _("A rare BALL made\nin commemoration\nof some event.$"); +//medicine +const u8 gPotionItemDescription[] = _("Restores the HP of\na POKéMON by\n20 points.$"); +const u8 gAntidoteItemDescription[] = _("Heals a poisoned\nPOKéMON.$"); +const u8 gBurnHealItemDescription[] = _("Heals POKéMON\nof a burn.$"); +const u8 gIceHealItemDescription[] = _("Defrosts a frozen\nPOKéMON.$"); +const u8 gAwakeningItemDescription[] = _("Awakens a sleeping\nPOKéMON.$"); +const u8 gParalyzeHealItemDescription[] = _("Heals a paralyzed\nPOKéMON.$"); +const u8 gFullRestoreItemDescription[] = _("Fully restores the\nHP and status of a\nPOKéMON.$"); +const u8 gMaxPotionItemDescription[] = _("Fully restores the\nHP of a POKéMON.$"); +const u8 gHyperPotionItemDescription[] = _("Restores the HP of\na POKéMON by\n200 points.$"); +const u8 gSuperPotionItemDescription[] = _("Restores the HP of\na POKéMON by\n50 points.$"); +const u8 gFullHealItemDescription[] = _("Heals all the\nstatus problems of\none POKéMON.$"); +const u8 gReviveItemDescription[] = _("Revives a fainted\nPOKéMON with half\nits HP.$"); +const u8 gMaxReviveItemDescription[] = _("Revives a fainted\nPOKéMON with all\nits HP.$"); +const u8 gFreshWaterItemDescription[] = _("A mineral water\nthat restores HP\nby 50 points.$"); +const u8 gSodaPopItemDescription[] = _("A fizzy soda drink\nthat restores HP\nby 60 points.$"); +const u8 gLemonadeItemDescription[] = _("A very sweet drink\nthat restores HP\nby 80 points.$"); +const u8 gMoomooMilkItemDescription[] = _("A nutritious milk\nthat restores HP\nby 100 points.$"); +const u8 gEnergyPowderItemDescription[] = _("A bitter powder\nthat restores HP\nby 50 points.$"); +const u8 gEnergyRootItemDescription[] = _("A bitter root\nthat restores HP\nby 200 points.$"); +const u8 gHealPowderItemDescription[] = _("A bitter powder\nthat heals all\nstatus problems.$"); +const u8 gRevivalHerbItemDescription[] = _("A very bitter herb\nthat revives a\nfainted POKéMON.$"); +const u8 gEtherItemDescription[] = _("Restores the PP\nof a selected move\nby 10.$"); +const u8 gMaxEtherItemDescription[] = _("Fully restores the\nPP of a selected\nmove.$"); +const u8 gElixirItemDescription[] = _("Restores the PP\nof all moves by 10.$"); +const u8 gMaxElixirItemDescription[] = _("Fully restores the\nPP of a POKéMON’s\nmoves.$"); +const u8 gLavaCookieItemDescription[] = _("A local specialty\nthat heals all\nstatus problems.$"); +const u8 gBlueFluteItemDescription[] = _("A glass flute that\nawakens sleeping\nPOKéMON.$"); +const u8 gYellowFluteItemDescription[] = _("A glass flute that\nsnaps POKéMON\nout of confusion.$"); +const u8 gRedFluteItemDescription[] = _("A glass flute that\nsnaps POKéMON\nout of attraction.$"); +const u8 gBlackFluteItemDescription[] = _("A glass flute that\nkeeps away wild\nPOKéMON.$"); +const u8 gWhiteFluteItemDescription[] = _("A glass flute that\nlures wild POKéMON.$"); +const u8 gBerryJuiceItemDescription[] = _("A 100% pure juice\nthat restores HP\nby 20 points.$"); +const u8 gSacredAshItemDescription[] = _("Fully revives and\nrestores all\nfainted POKéMON.$"); +//collectibles +const u8 gShoalSaltItemDescription[] = _("Salt obtained from\ndeep inside the\nSHOAL CAVE.$"); +const u8 gShoalShellItemDescription[] = _("A seashell found\ndeep inside the\nSHOAL CAVE.$"); +const u8 gRedShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); +const u8 gBlueShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); +const u8 gYellowShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); +const u8 gGreenShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); +//vitamins +const u8 gHPUpItemDescription[] = _("Raises the base HP\nof one POKéMON.$"); +const u8 gProteinItemDescription[] = _("Raises the base\nATTACK stat of one\nPOKéMON.$"); +const u8 gIronItemDescription[] = _("Raises the base\nDEFENSE stat of\none POKéMON.$"); +const u8 gCarbosItemDescription[] = _("Raises the base\nSPEED stat of one\nPOKéMON.$"); +const u8 gCalciumItemDescription[] = _("Raises the base\nSP. ATK stat of one\nPOKéMON.$"); +const u8 gRareCandyItemDescription[] = _("Raises the level\nof a POKéMON by\none.$"); +const u8 gPPUpItemDescription[] = _("Raises the maximum\nPP of a selected\nmove.$"); +const u8 gZincItemDescription[] = _("Raises the base\nSP. DEF stat of one\nPOKéMON.$"); +const u8 gPPMaxItemDescription[] = _("Raises the PP of a\nmove to its maximum\npoints.$"); +//battle items +const u8 gGuardSpecItemDescription[] = _("Prevents stat\nreduction when\nused in battle.$"); +const u8 gDireHitItemDescription[] = _("Raises the\ncritical-hit ratio\nduring one battle.$"); +const u8 gXAttackItemDescription[] = _("Raises the stat\nATTACK during one\nbattle.$"); +const u8 gXDefendItemDescription[] = _("Raises the stat\nDEFENSE during one\nbattle.$"); +const u8 gXSpeedItemDescription[] = _("Raises the stat\nSPEED during one\nbattle.$"); +const u8 gXAccuracyItemDescription[] = _("Raises accuracy\nof attack moves\nduring one battle.$"); +const u8 gXSpecialItemDescription[] = _("Raises the stat\nSP. ATK during one\nbattle.$"); +const u8 gPokeDollItemDescription[] = _("Use to flee from\nany battle with\na wild POKéMON.$"); +const u8 gFluffyTailItemDescription[] = _("Use to flee from\nany battle with\na wild POKéMON.$"); +//field items +const u8 gSuperRepelItemDescription[] = _("Repels weak wild\nPOKéMON for 200\nsteps.$"); +const u8 gMaxRepelItemDescription[] = _("Repels weak wild\nPOKéMON for 250\nsteps.$"); +const u8 gEscapeRopeItemDescription[] = _("Use to escape\ninstantly from a\ncave or a dungeon.$"); +const u8 gRepelItemDescription[] = _("Repels weak wild\nPOKéMON for 100\nsteps.$"); +//evolution stones +const u8 gSunStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +const u8 gMoonStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +const u8 gFireStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +const u8 gThunderStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +const u8 gWaterStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +const u8 gLeafStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +//valuable items +const u8 gTinyMushroomItemDescription[] = _("A plain mushroom\nthat would sell\nat a cheap price.$"); +const u8 gBigMushroomItemDescription[] = _("A rare mushroom\nthat would sell at a\nhigh price.$"); +const u8 gPearlItemDescription[] = _("A pretty pearl\nthat would sell at a\ncheap price.$"); +const u8 gBigPearlItemDescription[] = _("A lovely large pearl\nthat would sell at a\nhigh price.$"); +const u8 gStardustItemDescription[] = _("Beautiful red sand.\nCan be sold at a\nhigh price.$"); +const u8 gStarPieceItemDescription[] = _("A red gem shard.\nIt would sell for a\nvery high price.$"); +const u8 gNuggetItemDescription[] = _("A nugget of pure\ngold. Can be sold at\na high price.$"); +const u8 gHeartScaleItemDescription[] = _("A lovely scale.\nIt is coveted by\ncollectors.$"); +//mail +const u8 gOrangeMailItemDescription[] = _("A ZIGZAGOON-print\nMAIL to be held by\na POKéMON.$"); +const u8 gHarborMailItemDescription[] = _("A WINGULL-print\nMAIL to be held by\na POKéMON.$"); +const u8 gGlitterMailItemDescription[] = _("A PIKACHU-print\nMAIL to be held by\na POKéMON.$"); +const u8 gMechMailItemDescription[] = _("A MAGNEMITE-print\nMAIL to be held by\na POKéMON.$"); +const u8 gWoodMailItemDescription[] = _("A SLAKOTH-print\nMAIL to be held by\na POKéMON.$"); +const u8 gWaveMailItemDescription[] = _("A WAILMER-print\nMAIL to be held by\na POKéMON.$"); +const u8 gBeadMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKéMON.$"); +const u8 gShadowMailItemDescription[] = _("A DUSKULL-print\nMAIL to be held by\na POKéMON.$"); +const u8 gTropicMailItemDescription[] = _("A BELLOSSOM-print\nMAIL to be held by\na POKéMON.$"); +const u8 gDreamMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKéMON.$"); +const u8 gFabMailItemDescription[] = _("A gorgeous-print\nMAIL to be held\nby a POKéMON.$"); +const u8 gRetroMailItemDescription[] = _("MAIL featuring the\ndrawings of three\nPOKéMON.$"); +//berries +const u8 gCheriBerryItemDescription[] = _("A hold item that\nheals paralysis\nin battle.$"); +const u8 gChestoBerryItemDescription[] = _("A hold item that\nawakens POKéMON\nin battle.$"); +const u8 gPechaBerryItemDescription[] = _("A hold item that\nheals poisoning\nin battle.$"); +const u8 gRawstBerryItemDescription[] = _("A hold item that\nheals a burn in\nbattle.$"); +const u8 gAspearBerryItemDescription[] = _("A hold item that\ndefrosts POKéMON\nin battle.$"); +const u8 gLeppaBerryItemDescription[] = _("A hold item that\nrestores 10 PP in\nbattle.$"); +const u8 gOranBerryItemDescription[] = _("A hold item that\nrestores 10 HP in\nbattle.$"); +const u8 gPersimBerryItemDescription[] = _("A hold item that\nheals confusion\nin battle.$"); +const u8 gLumBerryItemDescription[] = _("A hold item that\nheals any status\nproblem in battle.$"); +const u8 gSitrusBerryItemDescription[] = _("A hold item that\nrestores 30 HP in\nbattle.$"); +const u8 gFigyBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); +const u8 gWikiBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); +const u8 gMagoBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); +const u8 gAguavBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); +const u8 gIapapaBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); +const u8 gRazzBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow RAZZ.$"); +const u8 gBlukBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow BLUK.$"); +const u8 gNanabBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow NANAB.$"); +const u8 gWepearBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow WEPEAR.$"); +const u8 gPinapBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow PINAP.$"); +const u8 gPomegBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase HP.$"); +const u8 gKelpsyBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase ATTACK.$"); +const u8 gQualotBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase DEFENSE.$"); +const u8 gHondewBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase SP. ATK.$"); +const u8 gGrepaBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase SP. DEF.$"); +const u8 gTamatoBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase SPEED.$"); +const u8 gCornnBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow CORNN.$"); +const u8 gMagostBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow MAGOST.$"); +const u8 gRabutaBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow RABUTA.$"); +const u8 gNomelBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow NOMEL.$"); +const u8 gSpelonBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow SPELON.$"); +const u8 gPamtreBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow PAMTRE.$"); +const u8 gWatmelBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow WATMEL.$"); +const u8 gDurinBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow DURIN.$"); +const u8 gBelueBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow BELUE.$"); +const u8 gLiechiBerryItemDescription[] = _("A hold item that\nraises ATTACK in\na pinch.$"); +const u8 gGanlonBerryItemDescription[] = _("A hold item that\nraises DEFENSE in\na pinch.$"); +const u8 gSalacBerryItemDescription[] = _("A hold item that\nraises SPEED in\na pinch.$"); +const u8 gPetayaBerryItemDescription[] = _("A hold item that\nraises SP. ATK in\na pinch.$"); +const u8 gApicotBerryItemDescription[] = _("A hold item that\nraises SP. DEF in\na pinch.$"); +const u8 gLansatBerryItemDescription[] = _("A hold item that\nups the critical-\nhit rate in a pinch.$"); +const u8 gStarfBerryItemDescription[] = _("A hold item that\nsharply boosts a\nstat in a pinch.$"); +const u8 gEnigmaBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow a mystery.$"); +//hold items +const u8 gBrightPowderItemDescription[] = _("A hold item that\ncasts a glare to\nreduce accuracy.$"); +const u8 gWhiteHerbItemDescription[] = _("A hold item that\nrestores any\nlowered stat.$"); +const u8 gMachoBraceItemDescription[] = _("A hold item that\npromotes growth,\nbut reduces SPEED.$"); +const u8 gExpShareItemDescription[] = _("A hold item that\ngets EXP. points\nfrom battles.$"); +const u8 gQuickClawItemDescription[] = _("A hold item that\noccasionally allows\nthe first strike.$"); +const u8 gSootheBellItemDescription[] = _("A hold item that\ncalms spirits and\nfosters friendship.$"); +const u8 gMentalHerbItemDescription[] = _("A hold item that\nsnaps POKéMON out\nof infatuation.$"); +const u8 gChoiceBandItemDescription[] = _("Raises a move’s\npower, but permits\nonly that move.$"); +const u8 gKingsRockItemDescription[] = _("A hold item that\nmay cause flinching\nwhen the foe is hit.$"); +const u8 gSilverPowderItemDescription[] = _("A hold item that\nraises the power of\nBUG-type moves.$"); +const u8 gAmuletCoinItemDescription[] = _("Doubles money in\nbattle if the\nholder takes part.$"); +const u8 gCleanseTagItemDescription[] = _("A hold item that\nhelps repel wild\nPOKéMON.$"); +const u8 gSoulDewItemDescription[] = _("Hold item: raises\nSP. ATK & SP. DEF of\nLATIOS & LATIAS.$"); +const u8 gDeepSeaToothItemDescription[] = _("A hold item that\nraises the SP. ATK\nof CLAMPERL.$"); +const u8 gDeepSeaScaleItemDescription[] = _("A hold item that\nraises the SP. DEF\nof CLAMPERL.$"); +const u8 gSmokeBallItemDescription[] = _("A hold item that\nassures fleeing\nfrom wild POKéMON.$"); +const u8 gEverstoneItemDescription[] = _("A wondrous hold\nitem that prevents\nevolution.$"); +const u8 gFocusBandItemDescription[] = _("A hold item that\noccasionally\nprevents fainting.$"); +const u8 gLuckyEggItemDescription[] = _("A hold item that\nboosts EXP. points\nearned in battle.$"); +const u8 gScopeLensItemDescription[] = _("A hold item that\nimproves the\ncritical-hit rate.$"); +const u8 gMetalCoatItemDescription[] = _("A hold item that\nraises the power of\nSTEEL-type moves.$"); +const u8 gLeftoversItemDescription[] = _("A hold item that\ngradually restores\nHP in battle.$"); +const u8 gDragonScaleItemDescription[] = _("A strange scale\nheld by DRAGON-\ntype POKéMON.$"); +const u8 gLightBallItemDescription[] = _("A hold item that\nraises the SP. ATK\nof PIKACHU.$"); +const u8 gSoftSandItemDescription[] = _("A hold item that\nraises the power of\nGROUND-type moves.$"); +const u8 gHardStoneItemDescription[] = _("A hold item that\nraises the power of\nROCK-type moves.$"); +const u8 gMiracleSeedItemDescription[] = _("A hold item that\nraises the power of\nGRASS-type moves.$"); +const u8 gBlackGlassesItemDescription[] = _("A hold item that\nraises the power of\nDARK-type moves.$"); +const u8 gBlackBeltItemDescription[] = _("A hold item that\nboosts FIGHTING-\ntype moves.$"); +const u8 gMagnetItemDescription[] = _("A hold item that\nboosts ELECTRIC-\ntype moves.$"); +const u8 gMysticWaterItemDescription[] = _("A hold item that\nraises the power of\nWATER-type moves.$"); +const u8 gSharpBeakItemDescription[] = _("A hold item that\nraises the power of\nFLYING-type moves.$"); +const u8 gPoisonBarbItemDescription[] = _("A hold item that\nraises the power of\nPOISON-type moves.$"); +const u8 gNeverMeltIceItemDescription[] = _("A hold item that\nraises the power of\nICE-type moves.$"); +const u8 gSpellTagItemDescription[] = _("A hold item that\nraises the power of\nGHOST-type moves.$"); +const u8 gTwistedSpoonItemDescription[] = _("A hold item that\nboosts PSYCHIC-\ntype moves.$"); +const u8 gCharcoalItemDescription[] = _("A hold item that\nraises the power of\nFIRE-type moves.$"); +const u8 gDragonFangItemDescription[] = _("A hold item that\nraises the power of\nDRAGON-type moves.$"); +const u8 gSilkScarfItemDescription[] = _("A hold item that\nraises the power of\nNORMAL-type moves.$"); +const u8 gUpGradeItemDescription[] = _("A peculiar box made\nby SILPH CO.$"); +const u8 gShellBellItemDescription[] = _("A hold item that\nrestores HP upon\nstriking the foe.$"); +const u8 gSeaIncenseItemDescription[] = _("A hold item that\nslightly boosts\nWATER-type moves.$"); +const u8 gLaxIncenseItemDescription[] = _("A hold item that\nslightly lowers the\nfoe’s accuracy.$"); +const u8 gLuckyPunchItemDescription[] = _("A hold item that\nraises CHANSEY’s\ncritical-hit rate.$"); +const u8 gMetalPowderItemDescription[] = _("A hold item that\nraises DITTO’s\nDEFENSE.$"); +const u8 gThickClubItemDescription[] = _("A hold item that \nraises CUBONE or\nMAROWAK’s ATTACK.$"); +const u8 gStickItemDescription[] = _("A hold item that\nraises FARFETCH’D’s\ncritical-hit ratio.$"); +const u8 gRedScarfItemDescription[] = _("A hold item that\nraises COOL in\nCONTESTS.$"); +const u8 gBlueScarfItemDescription[] = _("A hold item that\nraises BEAUTY in\nCONTESTS.$"); +const u8 gPinkScarfItemDescription[] = _("A hold item that\nraises CUTE in\nCONTESTS.$"); +const u8 gGreenScarfItemDescription[] = _("A hold item that\nraises SMART in\nCONTESTS.$"); +const u8 gYellowScarfItemDescription[] = _("A hold item that\nraises TOUGH in\nCONTESTS.$"); +//key items +const u8 gMachBikeItemDescription[] = _("A folding bicycle\nthat doubles your\nspeed or better.$"); +const u8 gCoinCaseItemDescription[] = _("A case that holds\nup to 9,999 COINS.$"); +const u8 gItemfinderItemDescription[] = _("A device that\nsignals an invisible\nitem by sound.$"); +const u8 gOldRodItemDescription[] = _("Use by any body of\nwater to fish for\nwild POKéMON.$"); +const u8 gGoodRodItemDescription[] = _("A decent fishing\nrod for catching\nwild POKéMON.$"); +const u8 gSuperRodItemDescription[] = _("The best fishing\nrod for catching\nwild POKéMON.$"); +const u8 gSSTicketItemDescription[] = _("The ticket required\nfor sailing on a\nferry.$"); +const u8 gContestPassItemDescription[] = _("The pass required\nfor entering\nPOKéMON CONTESTS.$"); +const u8 gWailmerPailItemDescription[] = _("A tool used for\nwatering BERRIES\nand plants.$"); +const u8 gDevonGoodsItemDescription[] = _("A package that\ncontains DEVON’s\nmachine parts.$"); +const u8 gSootSackItemDescription[] = _("A sack used to\ngather and hold\nvolcanic ash.$"); +const u8 gBasementKeyItemDescription[] = _("The key for NEW\nMAUVILLE beneath\nMAUVILLE CITY.$"); +const u8 gAcroBikeItemDescription[] = _("A folding bicycle\ncapable of jumps\nand wheelies.$"); +const u8 gPokeblockCaseItemDescription[] = _("A case for holding\n{POKEBLOCK}S made with\na BERRY BLENDER.$"); +const u8 gLetterItemDescription[] = _("A letter to STEVEN\nfrom the PRESIDENT\nof the DEVON CORP.$"); +const u8 gEonTicketItemDescription[] = _("The ticket for a\nferry to a distant\nsouthern island.$"); +const u8 gRedOrbItemDescription[] = _("A red, glowing orb\nsaid to contain an\nancient power.$"); +const u8 gBlueOrbItemDescription[] = _("A blue, glowing orb\nsaid to contain an\nancient power.$"); +const u8 gScannerItemDescription[] = _("A device found\ninside the\nABANDONED SHIP.$"); +const u8 gGoGogglesItemDescription[] = _("Nifty goggles that\nprotect eyes from\ndesert sandstorms.$"); +const u8 gMeteoriteItemDescription[] = _("A meteorite found\nat METEOR FALLS.$"); +const u8 gRoom1KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); +const u8 gRoom2KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); +const u8 gRoom4KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); +const u8 gRoom6KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); +const u8 gStorageKeyItemDescription[] = _("The key to the\nstorage inside the\nABANDONED SHIP.$"); +const u8 gRootFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKéMON.$"); +const u8 gClawFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKéMON.$"); +const u8 gDevonScopeItemDescription[] = _("A device by DEVON\nthat signals any\nunseeable POKéMON.$"); +//TMs/HMs +const u8 gTM01ItemDescription[] = _("Powerful, but makes\nthe user flinch if\nhit by the foe.$"); +const u8 gTM02ItemDescription[] = _("Hooks and slashes\nthe foe with long,\nsharp claws.$"); +const u8 gTM03ItemDescription[] = _("Generates an\nultrasonic wave\nthat may confuse.$"); +const u8 gTM04ItemDescription[] = _("Raises SP. ATK and\nSP. DEF by focusing\nthe mind.$"); +const u8 gTM05ItemDescription[] = _("A savage roar that\nmakes the foe flee \nto end the battle.$"); +const u8 gTM06ItemDescription[] = _("Poisons the foe\nwith a toxin that\ngradually worsens.$"); +const u8 gTM07ItemDescription[] = _("Creates a hailstorm\nthat damages all\ntypes except ICE.$"); +const u8 gTM08ItemDescription[] = _("Bulks up the body\nto boost both\nATTACK & DEFENSE.$"); +const u8 gTM09ItemDescription[] = _("Shoots 2 to 5 seeds\nin a row to strike\nthe foe.$"); +const u8 gTM10ItemDescription[] = _("The attack power\nvaries among\ndifferent POKéMON.$"); +const u8 gTM11ItemDescription[] = _("Raises the power of\nFIRE-type moves\nfor 5 turns.$"); +const u8 gTM12ItemDescription[] = _("Enrages the foe so\nit can only use\nattack moves.$"); +const u8 gTM13ItemDescription[] = _("Fires an icy cold\nbeam that may\nfreeze the foe.$"); +const u8 gTM14ItemDescription[] = _("A brutal snow-and-\nwind attack that\nmay freeze the foe.$"); +const u8 gTM15ItemDescription[] = _("Powerful, but needs\nrecharging the\nnext turn.$"); +const u8 gTM16ItemDescription[] = _("Creates a wall of\nlight that lowers\nSP. ATK damage.$"); +const u8 gTM17ItemDescription[] = _("Negates all damage,\nbut may fail if used\nin succession.$"); +const u8 gTM18ItemDescription[] = _("Raises the power of\nWATER-type moves\nfor 5 turns.$"); +const u8 gTM19ItemDescription[] = _("Recovers half the\nHP of the damage \nthis move inflicts.$"); +const u8 gTM20ItemDescription[] = _("Prevents status\nabnormality with a\nmystical power.$"); +const u8 gTM21ItemDescription[] = _("The less the user\nlikes you, the more\npowerful this move.$"); +const u8 gTM22ItemDescription[] = _("Absorbs sunlight in\nthe 1st turn, then\nattacks next turn.$"); +const u8 gTM23ItemDescription[] = _("Slams the foe with\na hard tail. It may\nlower DEFENSE.$"); +const u8 gTM24ItemDescription[] = _("A powerful electric\nattack that may\ncause paralysis.$"); +const u8 gTM25ItemDescription[] = _("Strikes the foe\nwith a thunderbolt.\nIt may paralyze.$"); +const u8 gTM26ItemDescription[] = _("Causes a quake\nthat has no effect\non flying foes.$"); +const u8 gTM27ItemDescription[] = _("The more the user\nlikes you, the more\npowerful this move.$"); +const u8 gTM28ItemDescription[] = _("Digs underground\nthe 1st turn, then\nstrikes next turn.$"); +const u8 gTM29ItemDescription[] = _("A powerful psychic\nattack that may\nlower SP. DEF.$"); +const u8 gTM30ItemDescription[] = _("Hurls a dark lump\nat the foe. It may\nlower SP. DEF.$"); +const u8 gTM31ItemDescription[] = _("Destroys barriers\nlike LIGHT SCREEN\nand causes damage.$"); +const u8 gTM32ItemDescription[] = _("Creates illusory\ncopies to enhance\nelusiveness.$"); +const u8 gTM33ItemDescription[] = _("Creates a wall of\nlight that weakens\nphysical attacks.$"); +const u8 gTM34ItemDescription[] = _("Zaps the foe with a\njolt of electricity\nthat never misses.$"); +const u8 gTM35ItemDescription[] = _("Looses a stream of\nfire that may burn\nthe foe.$"); +const u8 gTM36ItemDescription[] = _("Hurls sludge at the\nfoe. It may poison\nthe foe.$"); +const u8 gTM37ItemDescription[] = _("Causes a sandstorm\nthat hits the foe\nover several turns.$"); +const u8 gTM38ItemDescription[] = _("A powerful fire\nattack that may\nburn the foe.$"); +const u8 gTM39ItemDescription[] = _("Stops the foe from\nmoving with rocks.\nMay lower SPEED.$"); +const u8 gTM40ItemDescription[] = _("An extremely fast\nattack that can’t\nbe avoided.$"); +const u8 gTM41ItemDescription[] = _("Prevents the foe\nfrom using the same\nmove in a row.$"); +const u8 gTM42ItemDescription[] = _("Raises ATTACK when\npoisoned, burned,\nor paralyzed.$"); +const u8 gTM43ItemDescription[] = _("Adds an effect to\nattack depending\non the location.$"); +const u8 gTM44ItemDescription[] = _("The user sleeps for\n2 turns to restore\nhealth and status.$"); +const u8 gTM45ItemDescription[] = _("Makes it tough to\nattack a foe of the\nopposite gender.$"); +const u8 gTM46ItemDescription[] = _("While attacking,\nit may steal the\nfoe’s held item.$"); +const u8 gTM47ItemDescription[] = _("Spreads hard-\nedged wings and\nslams into the foe.$"); +const u8 gTM48ItemDescription[] = _("Switches abilities\nwith the foe on the\nturn this is used.$"); +const u8 gTM49ItemDescription[] = _("Steals the effects\nof the move the foe\nis trying to use.$"); +const u8 gTM50ItemDescription[] = _("Enables full-power\nattack, but sharply\nlowers SP. ATK.$"); + +const u8 gHM01ItemDescription[] = _("Attacks the foe\nwith sharp blades\nor claws.$"); +const u8 gHM02ItemDescription[] = _("Flies up on the\nfirst turn, then\nattacks next turn.$"); +const u8 gHM03ItemDescription[] = _("Creates a huge\nwave, then crashes\nit down on the foe.$"); +const u8 gHM04ItemDescription[] = _("Builds enormous\npower, then slams\nthe foe.$"); +const u8 gHM05ItemDescription[] = _("Looses a powerful\nblast of light that\nreduces accuracy.$"); +const u8 gHM06ItemDescription[] = _("A rock-crushingly\ntough attack that\nmay lower DEFENSE.$"); +const u8 gHM07ItemDescription[] = _("Attacks the foe\nwith enough power\nto climb waterfalls.$"); +const u8 gHM08ItemDescription[] = _("Dives underwater\nthe 1st turn, then\nattacks next turn.$"); +//FireRed/LeafGreen specific key items +const u8 gOaksParcelItemDescription[] = _("A parcel for PROF.\nOAK from a POKéMON\nMART’s clerk.$"); +const u8 gPokeFluteItemDescription[] = _("A sweet-sounding\nflute that awakens\nPOKéMON.$"); +const u8 gSecretKeyItemDescription[] = _("The key to the\nCINNABAR ISLAND\nGYM’s entrance.$"); +const u8 gBikeVoucherItemDescription[] = _("A voucher for\nobtaining a bicycle\nfrom the BIKE SHOP.$"); +const u8 gGoldTeethItemDescription[] = _("Gold dentures lost\nby the SAFARI\nZONE’s WARDEN.$"); +const u8 gOldAmberItemDescription[] = _("A stone containing\nthe genes of an\nancient POKéMON.$"); +const u8 gCardKeyItemDescription[] = _("A card-type door\nkey used in SILPH\nCO’s office.$"); +const u8 gLiftKeyItemDescription[] = _("An elevator key\nused in TEAM\nROCKET’s HIDEOUT.$"); +const u8 gHelixFossilItemDescription[] = _("A piece of an\nancient marine\nPOKéMON’s seashell.$"); +const u8 gDomeFossilItemDescription[] = _("A piece of an\nancient marine\nPOKéMON’s shell.$"); +const u8 gSilphScopeItemDescription[] = _("SILPH CO’s scope\nmakes unseeable\nPOKéMON visible.$"); +const u8 gBicycleItemDescription[] = _("A folding bicycle\nthat is faster than\nthe RUNNING SHOES.$"); +const u8 gTownMapItemDescription[] = _("Can be viewed\nanytime. Shows your\npresent location.$"); +const u8 gVSSeekerItemDescription[] = _("A rechargeable unit\nthat flags battle-\nready TRAINERS.$"); +const u8 gFameCheckerItemDescription[] = _("Stores information\non famous people\nfor instant recall.$"); +const u8 gTMCaseItemDescription[] = _("A convenient case \nthat holds TMs and\nHMs.$"); +const u8 gBerryPouchItemDescription[] = _("A convenient\ncontainer that\nholds BERRIES.$"); +const u8 gTeachyTVItemDescription[] = _("A TV set tuned to\nan advice program\nfor TRAINERS.$"); +const u8 gTriPassItemDescription[] = _("A pass for ferries\nbetween ONE, TWO,\nand THREE ISLAND.$"); +const u8 gRainbowPassItemDescription[] = _("For ferries serving\nVERMILION and the\nSEVII ISLANDS.$"); +const u8 gTeaItemDescription[] = _("A thirst-quenching\ntea prepared by an\nold lady.$"); +const u8 gMysticTicketItemDescription[] = _("A ticket required\nto board the ship\nto NAVEL ROCK.$"); +const u8 gAuroraTicketItemDescription[] = _("A ticket required\nto board the ship\nto BIRTH ISLAND.$"); +const u8 gPowderJarItemDescription[] = _("Stores BERRY\nPOWDER made using\na BERRY CRUSHER.$"); +const u8 gRubyItemDescription[] = _("An exquisite, red-\nglowing gem that\nsymbolizes passion.$"); +const u8 gSapphireItemDescription[] = _("A brilliant blue gem\nthat symbolizes\nhonesty.$"); +//Emerald specific key items +const u8 gMagmaEmblemItemDescription[] = _("A medal-like item in\nthe same shape as\nTEAM MAGMA’s mark.$"); +const u8 gOldSeaMapItemDescription[] = _("A faded sea chart\nthat shows the way\nto a certain island.$"); + +const struct Item gItems[] = { + + [ITEM_NONE] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + //Pokeballs + + [ITEM_MASTER_BALL] = { + .name = _("MASTER BALL$"), + .itemId = ITEM_MASTER_BALL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMasterBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 0, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 0, + }, + + [ITEM_ULTRA_BALL] = { + .name = _("ULTRA BALL$"), + .itemId = ITEM_ULTRA_BALL, + .price = 1200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gUltraBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 1, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 1, + }, + + [ITEM_GREAT_BALL] = { + .name = _("GREAT BALL$"), + .itemId = ITEM_GREAT_BALL, + .price = 600, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGreatBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 2, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 2, + }, + + [ITEM_POKE_BALL] = { + .name = _("POKé BALL$"), + .itemId = ITEM_POKE_BALL, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPokeBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 3, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 3, + }, + + [ITEM_SAFARI_BALL] = { + .name = _("SAFARI BALL$"), + .itemId = ITEM_SAFARI_BALL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSafariBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 4, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 4, + }, + + [ITEM_NET_BALL] = { + .name = _("NET BALL$"), + .itemId = ITEM_NET_BALL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gNetBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 5, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 5, + }, + + [ITEM_DIVE_BALL] = { + .name = _("DIVE BALL$"), + .itemId = ITEM_DIVE_BALL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDiveBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 6, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 6, + }, + + [ITEM_NEST_BALL] = { + .name = _("NEST BALL$"), + .itemId = ITEM_NEST_BALL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gNestBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 7, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 7, + }, + + [ITEM_REPEAT_BALL] = { + .name = _("REPEAT BALL$"), + .itemId = ITEM_REPEAT_BALL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRepeatBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 8, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 8, + }, + + [ITEM_TIMER_BALL] = { + .name = _("TIMER BALL$"), + .itemId = ITEM_TIMER_BALL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTimerBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 9, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 9, + }, + + [ITEM_LUXURY_BALL] = { + .name = _("LUXURY BALL$"), + .itemId = ITEM_LUXURY_BALL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gLuxuryBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 10, + .ItemUseFunc fieldUseFunc = NULL, + .battleUsage = 2, + .ItemUseFunc battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 10, + }, + + [ITEM_PREMIER_BALL] = { + .name = _("PREMIER BALL$"), + .itemId = ITEM_PREMIER_BALL, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPremierBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_POKE_BALLS, + .type = 11, + .fieldUseFunc = NULL, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Pokeball, + .secondaryId = 11, + }, + + //Medicine + + [ITEM_POTION] = { + .name = _("POTION$"), + .itemId = ITEM_POTION, + .price = 300, + .holdEffect = 0, + .holdEffectParam = 20, + .description = gPotionItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_ANTIDOTE] = { + .name = _("ANTIDOTE$"), + .itemId = ITEM_ANTIDOTE, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gAntidoteItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_BURN_HEAL] = { + .name = _("BURN HEAL$"), + .itemId = ITEM_BURN_HEAL, + .price = 250, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBurnHealItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_ICE_HEAL] = { + .name = _("ICE HEAL$"), + .itemId = ITEM_ICE_HEAL, + .price = 250, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gIceHealItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_AWAKENING] = { + .name = _("AWAKENING$"), + .itemId = ITEM_AWAKENING, + .price = 250, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gAwakeningItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_PARALYZE_HEAL] = { + .name = _("PARLYZ HEAL$"), + .itemId = ITEM_PARALYZE_HEAL, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gParalyzeHealItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_FULL_RESTORE] = { + .name = _("FULL RESTORE$"), + .itemId = ITEM_FULL_RESTORE, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 255, + .description = gFullRestoreItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_MAX_POTION] = { + .name = _("MAX POTION$"), + .itemId = ITEM_MAX_POTION, + .price = 2500, + .holdEffect = 0, + .holdEffectParam = 255, + .description = gMaxPotionItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_HYPER_POTION] = { + .name = _("HYPER POTION$"), + .itemId = ITEM_HYPER_POTION, + .price = 1200, + .holdEffect = 0, + .holdEffectParam = 200, + .description = gHyperPotionItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_SUPER_POTION] = { + .name = _("SUPER POTION$"), + .itemId = ITEM_SUPER_POTION, + .price = 700, + .holdEffect = 0, + .holdEffectParam = 50, + .description = gSuperPotionItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_FULL_HEAL] = { + .name = _("FULL HEAL$"), + .itemId = ITEM_FULL_HEAL, + .price = 600, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gFullHealItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_REVIVE] = { + .name = _("REVIVE$"), + .itemId = ITEM_REVIVE, + .price = 1500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gReviveItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + [ITEM_MAX_REVIVE] = { + .name = _("MAX REVIVE$"), + .itemId = ITEM_MAX_REVIVE, + .price = 4000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMaxReviveItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + [ITEM_FRESH_WATER] = { + .name = _("FRESH WATER$"), + .itemId = ITEM_FRESH_wATER, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 50, + .description = gFreshWaterItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_SODA_POP] = { + .name = _("SODA POP$"), + .itemId = ITEM_SODA_POP, + .price = 300, + .holdEffect = 0, + .holdEffectParam = 60, + .description = gSodaPopItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_LEMONADE] = { + .name = _("LEMONADE$"), + .itemId = ITEM_LEMONADE, + .price = 350, + .holdEffect = 0, + .holdEffectParam = 80, + .description = gLemonadeItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_MOOMOO_MILK] = { + .name = _("MOOMOO MILK$"), + .itemId = ITEM_MOOMOO_MILK, + .price = 500, + .holdEffect = 0, + .holdEffectParam = 100, + .description = gMoomooMilkItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_ENERGY_POWDER] = { + .name = _("ENERGYPOWDER$"), + .itemId = ITEM_ENERGY_POWDER, + .price = 500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gEnergyPowderItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_ENERGY_ROOT] = { + .name = _("ENERGY ROOT$"), + .itemId = ITEM_ENERGY_ROOT, + .price = 800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gEnergyRootItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_HEAL_POWDER] = { + .name = _("HEAL POWDER$"), + .itemId = ITEM_HEAL_POWDER, + .price = 450, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHealPowderItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_REVIVAL_HERB] = { + .name = _("REVIVAL HERB$"), + .itemId = ITEM_REVIVAL_HERB, + .price = 2800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRevivalHerbItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_ETHER] = { + .name = _("ETHER$"), + .itemId = ITEM_ETHER, + .price = 1200, + .holdEffect = 0, + .holdEffectParam = 10, + .description = gEtherItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_PPRecovery, + .secondaryId = 0, + }, + + [ITEM_MAX_ETHER] = { + .name = _("MAX ETHER$"), + .itemId = ITEM_MAX_ETHER, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 255, + .description = gMaxEtherItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_PPRecovery, + .secondaryId = 0, + }, + + [ITEM_ELIXIR] = { + .name = _("ELIXIR$"), + .itemId = ITEM_ELIXIR, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 10, + .description = gElixirItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_PPRecovery, + .secondaryId = 0, + }, + + [ITEM_MAX_ELIXIR] = { + .name = _("MAX ELIXIR$"), + .itemId = ITEM_MAX_ELIXIR, + .price = 4500, + .holdEffect = 0, + .holdEffectParam = 255, + .description = gMaxElixirItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_PPRecovery, + .secondaryId = 0, + }, + + [ITEM_LAVA_COOKIE] = { + .name = _("LAVA COOKIE$"), + .itemId = ITEM_LAVA_COOKIE, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gLavaCookieItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_BLUE_FLUTE] = { + .name = _("BLUE FLUTE$"), + .itemId = ITEM_BLUE_FLUTE, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBlueFluteItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_YELLOW_FLUTE] = { + .name = _("YELLOW FLUTE$"), + .itemId = ITEM_YELLOW_FLUTE, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gYellowFluteItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_RED_FLUTE] = { + .name = _("RED FLUTE$"), + .itemId = ITEM_RED_FLUTE, + .price = 300, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRedFluteItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + //Not medicine + + [ITEM_BLACK_FLUTE] = { + .name = _("BLACK FLUTE$"), + .itemId = ITEM_BLACK_FLUTE, + .price = 400, + .holdEffect = 0, + .holdEffectParam = 50, + .description = gBlackFluteItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_BlackWhiteFlute, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WHITE_FLUTE] = { + .name = _("WHITE FLUTE$"), + .itemId = ITEM_WHITE_FLUTE, + .price = 500, + .holdEffect = 0, + .holdEffectParam = 150, + .description = gWhiteFluteItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_BlackWhiteFlute, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + //Medicine again + + [ITEM_BERRY_JUICE] = { + .name = _("BERRY JUICE$"), + .itemId = ITEM_BERRY_JUICE, + .price = 100, + .holdEffect = 1, + .holdEffectParam = 20, + .description = gBerryJuiceItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_SACRED_ASH] = { + .name = _("SACRED ASH$"), + .itemId = ITEM_SACRED_ASH, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSacredAshItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_SacredAsh, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + //Collectibles + + [ITEM_SHOAL_SALT] = { + .name = _("SHOAL SALT$"), + .itemId = ITEM_SHOAL_SALT, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gShoalSaltItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SHOAL_SHELL] = { + .name = _("SHOAL SHELL$"), + .itemId = ITEM_SHOAL_SHELL, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gShoalShellItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_RED_SHARD] = { + .name = _("RED SHARD$"), + .itemId = ITEM_RED_SHARD, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRedShardItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BLUE_SHARD] = { + .name = _("BLUE SHARD$"), + .itemId = ITEM_BLUE_SHARD, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBlueShardItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_YELLOW_SHARD] = { + .name = _("YELLOW SHARD$"), + .itemId = ITEM_YELLOW_SHARD, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gYellowShardItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GREEN_SHARD] = { + .name = _("GREEN SHARD$"), + .itemId = ITEM_GREEN_SHARD, + .price = 200, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + //Empty Items + + [ITEM_034] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_035] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_036] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_037] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + [ITEM_038] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + [ITEM_039] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + [ITEM_03A] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_03B] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_03C] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_03D] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_03E] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + //Vitamins + + [ITEM_HP_UP] = { + .name = _("HP UP$"), + .itemId = ITEM_HP_UP, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHpUpItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PROTEIN] = { + .name = _("PROTEIN$"), + .itemId = ITEM_PROTEIN, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gProteinItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_IRON] = { + .name = _("IRON$"), + .itemId = ITEM_IRON, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gIronItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CARBOS] = { + .name = _("CARBOS$"), + .itemId = ITEM_, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gCarbosItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CALCIUM] = { + .name = _("CALCIUM$"), + .itemId = ITEM_CALCIUM, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gCalciumItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_RARE_CANDY] = { + .name = _("RARE CANDY$"), + .itemId = ITEM_RARE_CANDY, + .price = 4800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRareCandyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_RareCandy, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PP_UP] = { + .name = _("PP UP$"), + .itemId = ITEM_PP_UP, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPPUpItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPUp, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ZINC] = { + .name = _("ZINC$"), + .itemId = ITEM_ZINC, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gZincItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PP_MAX] = { + .name = _("PP MAX$"), + .itemId = ITEM_PP_MAX, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPPMaxItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPUp, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_048] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + //battle items + + [ITEM_GUARD_SPEC] = { + .name = _("GUARD SPEC.$"), + .itemId = ITEM_GUARD_SPEC, + .price = 700, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGuardSpecItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_DIRE_HIT] = { + .name = _("DIRE HIT$"), + .itemId = ITEM_DIRE_HIT, + .price = 650, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDireHitItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_X_ATTACK] = { + .name = _("X ATTACK$"), + .itemId = ITEM_X_ATTACK, + .price = 500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gXAttackItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_X_DEFEND] = { + .name = _("X DEFEND$"), + .itemId = ITEM_X_DEFEND, + .price = 550, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gXDefendItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_X_SPEED] = { + .name = _("X SPEED$"), + .itemId = ITEM_X_SPEED, + .price = 350, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gXSpeedItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_X_ACCURACY] = { + .name = _("X ACCURACY$"), + .itemId = ITEM_X_ACCURACY, + .price = 950, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gXAccuracyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_X_SPECIAL] = { + .name = _("X SPECIAL$"), + .itemId = ITEM_X_SPECIAL, + .price = 350, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gXSpecialItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_StatIncrease, + .secondaryId = 0, + }, + + [ITEM_POKE_DOLL] = { + .name = _("POKé DOLL$"), + .itemId = ITEM_POKE_DOLL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPokeDollItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Escape, + .secondaryId = 0, + }, + + [ITEM_FLUFFY_TAIL] = { + .name = _("FLUFFY TAIL$"), + .itemId = ITEM_FLUFFY_TAIL, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gFluffyTailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 2, + .battleUseFunc = ItemUseInBattle_Escape, + .secondaryId = 0, + }, + + [ITEM_052] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//field items + + [ITEM_SUPER_REPEL] = { + .name = _("SUPER REPEL$"), + .itemId = ITEM_SUPER_REPEL, + .price = 500, + .holdEffect = 0, + .holdEffectParam = 200, + .description = gSuperRepelItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_Repel, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MAX_REPEL] = { + .name = _("MAX REPEL$"), + .itemId = ITEM_MAX_REPEL, + .price = 700, + .holdEffect = 0, + .holdEffectParam = 250, + .description = gMaxRepelItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_Repel, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ESCAPE_ROPE] = { + .name = _("ESCAPE ROPE$"), + .itemId = ITEM_ESCAPE_ROPE, + .price = 550, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gEscapeRopeItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_EscapeRope, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_REPEL] = { + .name = _("REPEL$"), + .itemId = ITEM_REPEL, + .price = 350, + .holdEffect = 0, + .holdEffectParam = 100, + .description = gRepelItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_Repel, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Empty items #2 + + [ITEM_057] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_058] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_059] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_05A] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_05B] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_05C] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Evolution Stones + + [ITEM_SUN_STONE] = { + .name = _("SUN STONE$"), + .itemId = ITEM_SUN_STONE, + .price = 2100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSunStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MOON_STONE] = { + .name = _("MOON STONE$"), + .itemId = ITEM_MOON_STONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMoonStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_FIRE_STONE] = { + .name = _("FIRE STONE$"), + .itemId = ITEM_FIRE_STONE, + .price = 2100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gFireStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_THUNDER_STONE] = { + .name = _("THUNDERSTONE$"), + .itemId = ITEM_THUNDER_STONE, + .price = 2100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gThunderStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WATER_STONE] = { + .name = _("WATER STONE$"), + .itemId = ITEM_WATER_STONE, + .price = 2100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gWaterStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LEAF_STONE] = { + .name = _("LEAF STONE$"), + .itemId = ITEM_LEAF_STONE, + .price = 2100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gLeafStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Empty items #3 + + [ITEM_063] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_064] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_065] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_066] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Valuable items + [ITEM_TINY_MUSHROOM] = { + .name = _("TINYMUSHROOM$"), + .itemId = ITEM_TINY_MUSHROOM, + .price = 500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTinyMushroomItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BIG_MUSHROOM] = { + .name = _("BIG MUSHROOM$"), + .itemId = ITEM_BIG_MUSHROOM, + .price = 5000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBigMushroomItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_069] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PEARL] = { + .name = _("PEARL$"), + .itemId = ITEM_PEARL, + .price = 1400, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPearlItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BIG_PEARL] = { + .name = _("BIG PEARL$"), + .itemId = ITEM_BIG_PEARL, + .price = 7500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBigPearlItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_STARDUST] = { + .name = _("STARDUST$"), + .itemId = ITEM_STARDUST, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gStardustItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_STAR_PIECE] = { + .name = _("STAR PIECE$"), + .itemId = ITEM_STAR_PIECE, + .price = 9800, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gStarPieceItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_NUGGET] = { + .name = _("NUGGET$"), + .itemId = ITEM_NUGGET, + .price = 10000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gNuggetItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HEART_SCALE] = { + .name = _("HEART SCALE$"), + .itemId = ITEM_HEART_SCALE, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHeartScaleItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//empty items + + [ITEM_070] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_071] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_072] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_073] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_074] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_075] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_076] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_077] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_078] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//mail + + [ITEM_ORANGE_MAIL] = { + .name = _("ORANGE MAIL$"), + .itemId = ITEM_ORANGE_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gOrangeMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HARBOR_MAIL] = { + .name = _("HARBOR MAIL$"), + .itemId = ITEM_HARBOR_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHarborMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 1, + }, + + [ITEM_GLITTER_MAIL] = { + .name = _("GLITTER MAIL$"), + .itemId = ITEM_GLITTER_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGlitterMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 2, + }, + + [ITEM_MECH_MAIL] = { + .name = _("MECH MAIL$"), + .itemId = ITEM_MECH_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMechMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 3, + }, + + [ITEM_WOOD_MAIL] = { + .name = _("WOOD MAIL$"), + .itemId = ITEM_WOOD_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gWoodMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 4, + }, + + [ITEM_WAVE_MAIL] = { + .name = _("WAVE MAIL$"), + .itemId = ITEM_WAVE_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gWaveMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 5, + }, + + [ITEM_BEAD_MAIL] = { + .name = _("BEAD MAIL$"), + .itemId = ITEM_BEAD_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBeadMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 6, + }, + + [ITEM_SHADOW_MAIL] = { + .name = _("SHADOW MAIL$"), + .itemId = ITEM_SHADOW_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gShadowMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 7, + }, + + [ITEM_TROPIC_MAIL] = { + .name = _("TROPIC MAIL$"), + .itemId = ITEM_TROPIC_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTropicMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 8, + }, + + [ITEM_DREAM_MAIL] = { + .name = _("DREAM MAIL$"), + .itemId = ITEM_DREAM_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDreamMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 9, + }, + + [ITEM_FAB_MAIL] = { + .name = _("FAB MAIL$"), + .itemId = ITEM_FAB_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gFabMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 10, + }, + + [ITEM_RETRO_MAIL] = { + .name = _("RETRO MAIL$"), + .itemId = ITEM_RETRO_MAIL, + .price = 50, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRetroMailItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 0, + .fieldUseFunc = ItemUseOutOfBattle_Mail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 11, + }, + +//berries + + [ITEM_CHERI_BERRY] = { + .name = _("CHERI BERRY$"), + .itemId = ITEM_CHERI_BERRY, + .price = 20, + .holdEffect = 2, + .holdEffectParam = 0, + .description = gCheriBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_CHESTO_BERRY] = { + .name = _("CHESTO BERRY$"), + .itemId = ITEM_CHESTO_BERRY, + .price = 20, + .holdEffect = 3, + .holdEffectParam = 0, + .description = gChestoBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_PECHA_BERRY] = { + .name = _("PECHA BERRY$"), + .itemId = ITEM_PECHA_BERRY, + .price = 20, + .holdEffect = 4, + .holdEffectParam = 0, + .description = gPechaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_RAWST_BERRY] = { + .name = _("RAWST BERRY$"), + .itemId = ITEM_RAWST_BERRY, + .price = 20, + .holdEffect = 5, + .holdEffectParam = 0, + .description = gRawstBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_ASPEAR_BERRY] = { + .name = _("ASPEAR BERRY$"), + .itemId = ITEM_ASPEAR_BERRY, + .price = 20, + .holdEffect = 6, + .holdEffectParam = 0, + .description = gAspearBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_LEPPA_BERRY] = { + .name = _("LEPPA BERRY$"), + .itemId = ITEM_LEPPA_BERRY, + .price = 20, + .holdEffect = 7, + .holdEffectParam = 10, + .description = gLeppaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_PPRecovery, + .secondaryId = 0, + }, + + [ITEM_ORAN_BERRY] = { + .name = _("ORAN BERRY$"), + .itemId = ITEM_ORAN_BERRY, + .price = 20, + .holdEffect = 1, + .holdEffectParam = 10, + .description = gOranBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_PERSIM_BERRY] = { + .name = _("PERSIM BERRY$"), + .itemId = ITEM_PERSIM_BERRY, + .price = 20, + .holdEffect = 8, + .holdEffectParam = 0, + .description = gPersimBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_LUM_BERRY] = { + .name = _("LUM BERRY$"), + .itemId = ITEM_LUM_BERRY, + .price = 20, + .holdEffect = 9, + .holdEffectParam = 0, + .description = gLumBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_SITRUS_BERRY] = { + .name = _("SITRUS BERRY$"), + .itemId = ITEM_SITRUS_BERRY, + .price = 20, + .holdEffect = 1, + .holdEffectParam = 30, + .description = gSitrusBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_Medicine, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_Medicine, + .secondaryId = 0, + }, + + [ITEM_FIGY_BERRY] = { + .name = _("FIGY BERRY$"), + .itemId = ITEM_FIGY_BERRY, + .price = 20, + .holdEffect = 10, + .holdEffectParam = 8, + .description = gFigyBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WIKI_BERRY] = { + .name = _("WIKI BERRY$"), + .itemId = ITEM_WIKI_BERRY, + .price = 20, + .holdEffect = 11, + .holdEffectParam = 8, + .description = gWikiBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MAGO_BERRY] = { + .name = _("MAGO BERRY$"), + .itemId = ITEM_MAGO_BERRY, + .price = 20, + .holdEffect = 12, + .holdEffectParam = 8, + .description = gMagoBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_AGUAV_BERRY] = { + .name = _("AGUAV BERRY$"), + .itemId = ITEM_AGUAV_BERRY, + .price = 20, + .holdEffect = 13, + .holdEffectParam = 8, + .description = gAguavBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_IAPAPA_BERRY] = { + .name = _("IAPAPA BERRY$"), + .itemId = ITEM_IAPAPA_BERRY, + .price = 20, + .holdEffect = 14, + .holdEffectParam = 8, + .description = gIapapaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_RAZZ_BERRY] = { + .name = _("RAZZ BERRY$"), + .itemId = ITEM_RAZZ_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRazzBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BLUK_BERRY] = { + .name = _("BLUK BERRY$"), + .itemId = ITEM_BLUK_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBlukBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_NANAB_BERRY] = { + .name = _("NANAB BERRY$"), + .itemId = ITEM_NANAB_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gNanabBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WEPEAR_BERRY] = { + .name = _("WEAPER BERRY$"), + .itemId = ITEM_WEAPER_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gWepearBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PINAP_BERRY] = { + .name = _("PINAP BERRY$"), + .itemId = ITEM_PINAP_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPinapBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_POMEG_BERRY] = { + .name = _("POMEG BERRY$"), + .itemId = ITEM_POMEG_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPomegBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_KELPSY_BERRY] = { + .name = _("KELPSY BERRY$"), + .itemId = ITEM_KELPSY_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gKelpsyBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_QUALOT_BERRY] = { + .name = _("QUALOT BERRY$"), + .itemId = ITEM_QUALOT_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gQualotBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HONDEW_BERRY] = { + .name = _("HONDEW BERRY$"), + .itemId = ITEM_HONDEW_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHondewBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GREPA_BERRY] = { + .name = _("GREPA BERRY$"), + .itemId = ITEM_GREPA_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGrepaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TAMATO_BERRY] = { + .name = _("TAMATO BERRY$"), + .itemId = ITEM_TAMATO_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTamatoBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CORNN_BERRY] = { + .name = _("CORNN BERRY$"), + .itemId = ITEM_CORNN_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gCornnBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MAGOST_BERRY] = { + .name = _("MAGOST BERRY$"), + .itemId = ITEM_MAGOST_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMagostBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_RABUTA_BERRY] = { + .name = _("RABUTA BERRY$"), + .itemId = ITEM_RABUTA_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRabutaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_NOMEL_BERRY] = { + .name = _("NOMEL BERRY$"), + .itemId = ITEM_NOMEL_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gNomelBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SPELON_BERRY] = { + .name = _("SPELON BERRY$"), + .itemId = ITEM_SPELON_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSpelonBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PAMTRE_BERRY] = { + .name = _("PAMTRE BERRY$"), + .itemId = ITEM_PAMTRE_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPamtreBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WATMEL_BERRY] = { + .name = _("WATMEL BERRY$"), + .itemId = ITEM_WATMEL_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gWatmelBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DURIN_BERRY] = { + .name = _("DURIN BERRY$"), + .itemId = ITEM_DURIN_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDurinBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BELUE_BERRY] = { + .name = _("BELUE BERRY$"), + .itemId = ITEM_BELUE_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBelueBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LIECHI_BERRY] = { + .name = _("LIECHI BERRY$"), + .itemId = ITEM_LIECHI_BERRY, + .price = 20, + .holdEffect = 15, + .holdEffectParam = 4, + .description = gLiechiBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GANLON_BERRY] = { + .name = _("GANLON BERRY$"), + .itemId = ITEM_GANLON_BERRY, + .price = 20, + .holdEffect = 16, + .holdEffectParam = 4, + .description = gGanlonBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SALAC_BERRY] = { + .name = _("SALAC BERRY$"), + .itemId = ITEM_SALAC_BERRY, + .price = 20, + .holdEffect = 17, + .holdEffectParam = 4, + .description = gSalacBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PETAYA_BERRY] = { + .name = _("PETAYA BERRY$"), + .itemId = ITEM_PETAYA_BERRY, + .price = 20, + .holdEffect = 18, + .holdEffectParam = 4, + .description = gPetayaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_APICOT_BERRY] = { + .name = _("APICOT BERRY$"), + .itemId = ITEM_APICOT_BERRY, + .price = 20, + .holdEffect = 19, + .holdEffectParam = 4, + .description = gApicotBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LANSAT_BERRY] = { + .name = _("LANSAT BERRY$"), + .itemId = ITEM_LANSAT_BERRY, + .price = 20, + .holdEffect = 20, + .holdEffectParam = 4, + .description = gLansatBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_STARF_BERRY] = { + .name = _("STARF BERRY$"), + .itemId = ITEM_STARF_BERRY, + .price = 20, + .holdEffect = 21, + .holdEffectParam = 4, + .description = gStarfBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ENIGMA_BERRY] = { + .name = _("ENIGMA BERRY$"), + .itemId = ITEM_ENIGMA_BERRY, + .price = 20, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gEnigmaBerryItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_BERRIES, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_EnigmaBerry, + .battleUsage = 1, + .battleUseFunc = ItemUseInBattle_EnigmaBerry, + .secondaryId = 0, + }, + +//empty items + + [ITEM_0B0] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0B1] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0B2] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//hold items + + [ITEM_BRIGHT_POWDER] = { + .name = _("BRIGHTPOWDER$"), + .itemId = ITEM_BRIGHT_POWDER, + .price = 10, + .holdEffect = 22, + .holdEffectParam = 10, + .description = gBrightPowderItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WHITE_HERB] = { + .name = _("WHITE HERB$"), + .itemId = ITEM_WHITE_HERB, + .price = 100, + .holdEffect = 23, + .holdEffectParam = 0, + .description = gWhiteHerbItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MACHO_BRACE] = { + .name = _("MACHO BRACE$"), + .itemId = ITEM_MACHO_BRACE, + .price = 3000, + .holdEffect = 24, + .holdEffectParam = 0, + .description = gMachoBraceItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_EXP_SHARE] = { + .name = _("EXP. SHARE$"), + .itemId = ITEM_EXP_SHARE, + .price = 3000, + .holdEffect = 25, + .holdEffectParam = 0, + .description = gExpShareItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_QUICK_CLAW] = { + .name = _("QUICK CLAW$"), + .itemId = ITEM_QUICK_CLAW, + .price = 100, + .holdEffect = 26, + .holdEffectParam = 20, + .description = gQuickClawItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SOOTHE_BELL] = { + .name = _("SOOTHE BELL$"), + .itemId = ITEM_SOOTHE_BELL, + .price = 100, + .holdEffect = 27, + .holdEffectParam = 0, + .description = gSootheBellItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MENTAL_HERB] = { + .name = _("MENTAL HERB$"), + .itemId = ITEM_MENTAL_HERB, + .price = 100, + .holdEffect = 28, + .holdEffectParam = 0, + .description = gMentalHerbItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CHOICE_BAND] = { + .name = _("CHOICE BAND$"), + .itemId = ITEM_CHOICE_BAND, + .price = 100, + .holdEffect = 29, + .holdEffectParam = 0, + .description = gChoiceBandItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_KINGS_ROCK] = { + .name = _("KING'S ROCK$"), + .itemId = ITEM_KINGS_ROCK, + .price = 100, + .holdEffect = 30, + .holdEffectParam = 10, + .description = gKingsRockItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SILVER_POWDER] = { + .name = _("SILVERPOWDER$"), + .itemId = ITEM_SILVER_POWDER, + .price = 100, + .holdEffect = 31, + .holdEffectParam = 10, + .description = gSilverPowderItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_AMULET_COIN] = { + .name = _("AMULET COIN$"), + .itemId = ITEM_AMULET_COIN, + .price = 100, + .holdEffect = 32, + .holdEffectParam = 10, + .description = gAmuletCoinItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CLEANSE_TAG] = { + .name = _("CLEANSE TAG$"), + .itemId = ITEM_CLEANSE_TAG, + .price = 200, + .holdEffect = 33, + .holdEffectParam = 0, + .description = gCleanseTagItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SOUL_DEW] = { + .name = _("SOUL DEW$"), + .itemId = ITEM_SOUL_DEW, + .price = 200, + .holdEffect = 34, + .holdEffectParam = 0, + .description = gSoulDewItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DEEP_SEA_TOOTH] = { + .name = _("DEEPSEATOOTH$"), + .itemId = ITEM_DEEP_SEA_TOOTH, + .price = 200, + .holdEffect = 35, + .holdEffectParam = 0, + .description = gDeepSeaToothItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DEEP_SEA_SCALE] = { + .name = _("DEEPSEASCALE$"), + .itemId = ITEM_DEEP_SEA_SCALE, + .price = 200, + .holdEffect = 36, + .holdEffectParam = 0, + .description = gDeepSeaScaleItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SMOKE_BALL] = { + .name = _("SMOKE BALL$"), + .itemId = ITEM_SMOKE_BALL, + .price = 200, + .holdEffect = 37, + .holdEffectParam = 0, + .description = gSmokeBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_EVERSTONE] = { + .name = _("EVERSTONE$"), + .itemId = ITEM_EVERSTONE, + .price = 200, + .holdEffect = 38, + .holdEffectParam = 0, + .description = gEverstoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_FOCUS_BAND] = { + .name = _("FOCUS BAND$"), + .itemId = ITEM_FOCUS_BAND, + .price = 200, + .holdEffect = 39, + .holdEffectParam = 10, + .description = gFocusBandItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LUCKY_EGG] = { + .name = _("LUCKY EGG$"), + .itemId = ITEM_LUCKY_EGG, + .price = 200, + .holdEffect = 40, + .holdEffectParam = 0, + .description = gLuckyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SCOPE_LENS] = { + .name = _("SCOPE LENS$"), + .itemId = ITEM_SCOPE_LENS, + .price = 200, + .holdEffect = 41, + .holdEffectParam = 0, + .description = gScopeLensItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_METAL_COAT] = { + .name = _("METAL COAT$"), + .itemId = ITEM_METAL_COAT, + .price = 100, + .holdEffect = 42, + .holdEffectParam = 10, + .description = gMetalCoatItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LEFTOVERS] = { + .name = _("LEFTOVERS$"), + .itemId = ITEM_LEFTOVERS, + .price = 200, + .holdEffect = 43, + .holdEffectParam = 10, + .description = gLeftoversItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DRAGON_SCALE] = { + .name = _("DRAGON SCALE$"), + .itemId = ITEM_DRAGON_SCALE, + .price = 2100, + .holdEffect = 44, + .holdEffectParam = 10, + .description = gDragonScaleItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LIGHT_BALL] = { + .name = _("LIGHT BALL$"), + .itemId = ITEM_LIGHT_BALL, + .price = 100, + .holdEffect = 45, + .holdEffectParam = 0, + .description = gLightBallItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SOFT_SAND] = { + .name = _("SOFT SAND$"), + .itemId = ITEM_SOFT_SAND, + .price = 100, + .holdEffect = 46, + .holdEffectParam = 10, + .description = gSoftSandItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HARD_STONE] = { + .name = _("HARD STONE$"), + .itemId = ITEM_HARD_STONE, + .price = 100, + .holdEffect = 47, + .holdEffectParam = 10, + .description = gHardStoneItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MIRACLE_SEED] = { + .name = _("MIRACLE SEED$"), + .itemId = ITEM_MIRACLE_SEED, + .price = 100, + .holdEffect = 48, + .holdEffectParam = 10, + .description = gMiracleSeedItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BLACK_GLASSES] = { + .name = _("BLACKGLASSES$"), + .itemId = ITEM_BLACK_GLASSES, + .price = 100, + .holdEffect = 49, + .holdEffectParam = 10, + .description = gBlackGlassesItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BLACK_BELT] = { + .name = _("BLACK BELT$"), + .itemId = ITEM_BLACK_BELT, + .price = 100, + .holdEffect = 50, + .holdEffectParam = 10, + .description = gBlackBeltItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MAGNET] = { + .name = _("MAGNET$"), + .itemId = ITEM_MAGNET, + .price = 100, + .holdEffect = 51, + .holdEffectParam = 10, + .description = gMagnetItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MYSTIC_wATER] = { + .name = _("MYSTIC WATER$"), + .itemId = ITEM_MYSTIC_WATER, + .price = 100, + .holdEffect = 52, + .holdEffectParam = 10, + .description = gMysticWaterItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SHARP_BEAK] = { + .name = _("SHARP BEAK$"), + .itemId = ITEM_SHARP_BEAK, + .price = 100, + .holdEffect = 53, + .holdEffectParam = 10, + .description = gSharpBeakItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_POISON_BARB] = { + .name = _("POISON BARB$"), + .itemId = ITEM_POISON_BARB, + .price = 100, + .holdEffect = 54, + .holdEffectParam = 10, + .description = gPoisonBarbItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_NEVER_MELT_ICE] = { + .name = _("NEVERMELTICE$"), + .itemId = ITEM_NEVER_MELT_ICE, + .price = 100, + .holdEffect = 55, + .holdEffectParam = 10, + .description = gNeverMeltIceItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SPELL_TAG] = { + .name = _("SPELL TAG$"), + .itemId = ITEM_SPELL_TAG, + .price = 100, + .holdEffect = 56, + .holdEffectParam = 10, + .description = gSpellTagItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TWISTED_SPOON] = { + .name = _("TWISTEDSPOON$"), + .itemId = ITEM_TWISTED_SPOON, + .price = 100, + .holdEffect = 57, + .holdEffectParam = 10, + .description = gTwistedSpoonItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CHARCOAL] = { + .name = _("CHARCOAL$"), + .itemId = ITEM_CHARCOAL, + .price = 9800, + .holdEffect = 58, + .holdEffectParam = 10, + .description = gCharcoalItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DRAGON_FANG] = { + .name = _("DRAGON FANG$"), + .itemId = ITEM_DRAGON_FANG, + .price = 100, + .holdEffect = 59, + .holdEffectParam = 10, + .description = gDragonFangItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SILK_SCARF] = { + .name = _("SILK SCARF$"), + .itemId = ITEM_SILK_SCARF, + .price = 100, + .holdEffect = 60, + .holdEffectParam = 10, + .description = gSilScarfItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_UP_GRADE] = { + .name = _("UP-GRADE$"), + .itemId = ITEM_UP_GRADE, + .price = 2100, + .holdEffect = 61, + .holdEffectParam = 0, + .description = gUpGradeItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SHELL_BELL] = { + .name = _("SHELL BELL$"), + .itemId = ITEM_SHELL_BELL, + .price = 200, + .holdEffect = 62, + .holdEffectParam = 8, + .description = gShellBellItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SEA_INCENSE] = { + .name = _("SEA INCENSE$"), + .itemId = ITEM_SEA_INCENSE, + .price = 9600, + .holdEffect = 52, + .holdEffectParam = 5, + .description = gSeaIncenseItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LAX_INCENSE] = { + .name = _("LAX INCENSE$"), + .itemId = ITEM_LAX_INCENSE, + .price = 9600, + .holdEffect = 22, + .holdEffectParam = 5, + .description = gLaxIncenseItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LUCKY_PUNCH] = { + .name = _("LUCKY PUNCH$"), + .itemId = ITEM_LUCKY_PUNCH, + .price = 10, + .holdEffect = 63, + .holdEffectParam = 0, + .description = gLuckyPunchItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_METAL_POWDER] = { + .name = _("METAL POWDER$"), + .itemId = ITEM_METAL_POWDER, + .price = 10, + .holdEffect = 64, + .holdEffectParam = 0, + .description = gMetalPowderItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_THICK_CLUB] = { + .name = _("THICK CLUB$"), + .itemId = ITEM_THICK_CLUB, + .price = 500, + .holdEffect = 65, + .holdEffectParam = 0, + .description = gThickClubItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_STICK] = { + .name = _("STICK$"), + .itemId = ITEM_STICK, + .price = 200, + .holdEffect = 66, + .holdEffectParam = 0, + .description = gStickItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//empty items + + [ITEM_0E2] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E3] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E4] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E5] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E6] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E7] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E8] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0E9] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0EA] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0EB] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0EC] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0ED] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0EE] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0EF] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F0] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F1] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F2] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F3] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F4] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F5] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F6] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F7] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F8] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0F9] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0FA] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0FB] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0FC] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_0FD] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//hold items continued + + [ITEM_RED_SCARF] = { + .name = _("RED SCARF$"), + .itemId = ITEM_RED_SCARF, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRedScarfItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BLUE_SCARF] = { + .name = _("BLUE SCARF$"), + .itemId = ITEM_BLUE_SCARF, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBlueScarfItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_PINK_SCARF] = { + .name = _("PINK SCARF$"), + .itemId = ITEM_PINK_SCARF, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPinkScarfItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GREEN_SCARF] = { + .name = _("GREEN SCARF$"), + .itemId = ITEM_GREEN_SCARF, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGreenScarfItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_YELLOW_SCARF] = { + .name = _("YELLOW SCARF$"), + .itemId = ITEM_YELLOW_SCARF, + .price = 100, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gYellowScarfItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Key items + + [ITEM_MACH_BIKE] = { + .name = _("MACH BIKE$"), + .itemId = ITEM_MACH_BIKE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMachBikeItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_Bike, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_COIN_CASE] = { + .name = _("COIN CASE$"), + .itemId = ITEM_COIN_CASE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gCoinCaseItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CoinCase, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ITEMFINDER] = { + .name = _("ITEMFINDER$"), + .itemId = ITEM_ITEMFINDER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gItemfinderItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_Itemfinder, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_OLD_ROD] = { + .name = _("OLD ROD$"), + .itemId = ITEM_OLD_ROD, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gOldRodItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_Rod, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GOOD_ROD] = { + .name = _("GOOD ROD$"), + .itemId = ITEM_GOOD_ROD, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGoodRodItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_Rod, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 1, + }, + + [ITEM_SUPER_ROD] = { + .name = _("SUPER ROD$"), + .itemId = ITEM_SUPER_ROD, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSuperRodItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_Rod, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 2, + }, + + [ITEM_SS_TICKET] = { + .name = _("S.S. TICKET$"), + .itemId = ITEM_SS_TICKET, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSSTicketItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CONTEST_PASS] = { + .name = _("CONTEST PASS$"), + .itemId = ITEM_CONTEST_PASS, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gContestPassItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_10B] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_WAILMER_PAIL] = { + .name = _("WAILMER PAIL$"), + .itemId = ITEM_WAILMER_PAIL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gWailmerPailItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_WailmerPail, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DEVON_GOODS] = { + .name = _("DEVON GOODS$"), + .itemId = ITEM_DEVON_GOODS, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDevonGoodsItemDescription, + .importance = 2, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SOOT_SACK] = { + .name = _("SOOT SACK$"), + .itemId = ITEM_SOOT_SACK, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSootSackItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BASEMENT_KEY] = { + .name = _("BASEMENT KEY$"), + .itemId = ITEM_BASEMENT_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBasementKeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ACRO_BIKE] = { + .name = _("ACRO BIKE$"), + .itemId = ITEM_ACRO_BIKE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gAcroBikeItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_Bike, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 1, + }, + + [ITEM_POKEBLOCK_CASE] = { + .name = _("{POKEBLOCK} CASE$"), + .itemId = ITEM_POKEBLOCK_CASE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPokeblockCaseItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 3, + .fieldUseFunc = ItemUseOutOfBattle_PokeblockCase, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LETTER] = { + .name = _("LETTER$"), + .itemId = ITEM_LETTER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gLetterItemDescription, + .importance = 2, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_EON_TICKET] = { + .name = _("EON TICKET$"), + .itemId = ITEM_EON_TICKET, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gEonTicketItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 1, + }, + + [ITEM_RED_ORB] = { + .name = _("RED ORB$"), + .itemId = ITEM_RED_ORB, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRedOrbItemDescription, + .importance = 2, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BLUE_ORB] = { + .name = _("BLUE ORB$"), + .itemId = ITEM_BLUE_ORB, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBlueOrbItemDescription, + .importance = 2, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SCANNER] = { + .name = _("SCANNER$"), + .itemId = ITEM_SCANNER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gScannerItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GO_GOGGLES] = { + .name = _("GO-GOGGLES$"), + .itemId = ITEM_GO_GOGGLES, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGoGogglesItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_METEORITE] = { + .name = _("METEORITE$"), + .itemId = ITEM_METEORITE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMeteoriteItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ROOM_1_KEY] = { + .name = _("RM. 1 KEY$"), + .itemId = ITEM_ROOM_1_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRoom1KeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ROOM_2_KEY] = { + .name = _("RM. 2 KEY$"), + .itemId = ITEM_ROOM_2_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRoom2KeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ROOM_4_KEY] = { + .name = _("RM. 4 KEY$"), + .itemId = ITEM_ROOM_4_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRoom4KeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ROOM_6_KEY] = { + .name = _("RM. 6 KEY$"), + .itemId = ITEM_ROOM_6_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRoom6KeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_STORAGE_KEY] = { + .name = _("STORAGE KEY$"), + .itemId = ITEM_STORAGE_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gStorageKeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_ROOT_FOSSIL] = { + .name = _("ROOT FOSSIL$"), + .itemId = ITEM_ROOT_FOSSIL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRootFossilItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CLAW_FOSSIL] = { + .name = _("CLAW FOSSIL$"), + .itemId = ITEM_CLAW_FOSSIL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gClawFossilItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DEVON_SCOPE] = { + .name = _("DEVON SCOPE$"), + .itemId = ITEM_DEVON_SCOPE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDevonScopeItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//TMs/HMs + + [ITEM_TM01] = { + .name = _("TM$01"), + .itemId = ITEM_01TM, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM01ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM02] = { + .name = _("TM02$"), + .itemId = ITEM_02TM, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM02ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM03] = { + .name = _("TM03$"), + .itemId = ITEM_03TM, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM03ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM04] = { + .name = _("TM04$"), + .itemId = ITEM_TM04, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM04ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM05] = { + .name = _("TM05$"), + .itemId = ITEM_TM05, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM05ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM06] = { + .name = _("TM06$"), + .itemId = ITEM_TM06, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTMItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM07] = { + .name = _("TM07$"), + .itemId = ITEM_TM07, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM07ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM08] = { + .name = _("TM08$"), + .itemId = ITEM_TM08, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM08ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM09] = { + .name = _("TM09$"), + .itemId = ITEM_TM09, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM09ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM10] = { + .name = _("TM10$"), + .itemId = ITEM_TM10, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM10ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM11] = { + .name = _("TM11$"), + .itemId = ITEM_TM11, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM11ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM12] = { + .name = _("TM12$"), + .itemId = ITEM_TM12, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM12ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM13] = { + .name = _("TM13$"), + .itemId = ITEM_TM13, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM13ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM14] = { + .name = _("TM14$"), + .itemId = ITEM_TM14, + .price = 5500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM14ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM15] = { + .name = _("TM15$"), + .itemId = ITEM_TM15, + .price = 7500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM15ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM16] = { + .name = _("TM16$"), + .itemId = ITEM_TM16, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM16ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM17] = { + .name = _("TM17$"), + .itemId = ITEM_TM17, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM17ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM18] = { + .name = _("TM18$"), + .itemId = ITEM_TM18, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM18ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM19] = { + .name = _("TM19$"), + .itemId = ITEM_TM19, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM19ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM20] = { + .name = _("TM20$"), + .itemId = ITEM_TM20, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM20ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM21] = { + .name = _("TM21$"), + .itemId = ITEM_TM21, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM21ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM22] = { + .name = _("TM22$"), + .itemId = ITEM_TM22, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM22ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM23] = { + .name = _("TM23$"), + .itemId = ITEM_TM23, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM23ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM24] = { + .name = _("TM24$"), + .itemId = ITEM_TM24, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM24ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM25] = { + .name = _("TM25$"), + .itemId = ITEM_TM25, + .price = 5500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM25ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM26] = { + .name = _("TM26$"), + .itemId = ITEM_TM26, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM26ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM27] = { + .name = _("TM27$"), + .itemId = ITEM_TM27, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM27ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM28] = { + .name = _("TM28$"), + .itemId = ITEM_TM28, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM28ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM29] = { + .name = _("TM29$"), + .itemId = ITEM_TM29, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM29ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM30] = { + .name = _("TM30$"), + .itemId = ITEM_TM30, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM30ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM31] = { + .name = _("TM31$"), + .itemId = ITEM_TM31, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM31ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM32] = { + .name = _("TM32$"), + .itemId = ITEM_TM32, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM32ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM33] = { + .name = _("TM33$"), + .itemId = ITEM_TM33, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM33ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM34] = { + .name = _("TM34$"), + .itemId = ITEM_TM34, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM34ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM35] = { + .name = _("TM35$"), + .itemId = ITEM_TM35, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM35ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM36] = { + .name = _("TM36$"), + .itemId = ITEM_TM36, + .price = 1000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM36ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM37] = { + .name = _("TM37$"), + .itemId = ITEM_TM37, + .price = 2000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM37ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM38] = { + .name = _("TM38$"), + .itemId = ITEM_TM38, + .price = 5500, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM38ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM39] = { + .name = _("TM39$"), + .itemId = ITEM_TM39, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM39ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM40] = { + .name = _("TM40$"), + .itemId = ITEM_TM40, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM40ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM41] = { + .name = _("TM41$"), + .itemId = ITEM_TM41, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM41ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM42] = { + .name = _("TM42$"), + .itemId = ITEM_TM42, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM42ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM43] = { + .name = _("TM43$"), + .itemId = ITEM_TM43, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM43ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM44] = { + .name = _("TM44$"), + .itemId = ITEM_TM44, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM44ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM45] = { + .name = _("TM45$"), + .itemId = ITEM_TM45, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM45ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM46] = { + .name = _("TM46$"), + .itemId = ITEM_TM46, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM46ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM47] = { + .name = _("TM47$"), + .itemId = ITEM_TM47, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM47ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM48] = { + .name = _("TM48$"), + .itemId = ITEM_TM48, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM48ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM49] = { + .name = _("TM49$"), + .itemId = ITEM_TM49, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM49ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM50] = { + .name = _("TM50$"), + .itemId = ITEM_TM50, + .price = 3000, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTM50ItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM01] = { + .name = _("HM01$"), + .itemId = ITEM_HM01, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM01ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM02] = { + .name = _("HM02$"), + .itemId = ITEM_HM02, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM02ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM03] = { + .name = _("HM03$"), + .itemId = ITEM_HM03, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM03ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM04] = { + .name = _("HM04$"), + .itemId = ITEM_HM04, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM04ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM05] = { + .name = _("HM05$"), + .itemId = ITEM_HM05, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM05ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM06] = { + .name = _("HM06$"), + .itemId = ITEM_HM06, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM06ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM07] = { + .name = _("HM07$"), + .itemId = ITEM_HM07, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM07ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HM08] = { + .name = _("HM08$"), + .itemId = ITEM_HM08, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHM08ItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_TM_HM, + .type = 1, + .fieldUseFunc = ItemUseOutOfBattle_TMHM, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Empty items + + [ITEM_15B] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_15C] = { + .name = _("????????$"), + .itemId = ITEM_NONE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDummyItemDescription, + .importance = 0, + .unk19 = 0, + .pocket = POCKET_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//FireRed/LeafGreen key items + + [ITEM_OAKS_PARCEL] = { + .name = _("OAK’S PARCEL$"), + .itemId = ITEM_OAKS_PARCEL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gOaksParcelItemDescription, + .importance = 2, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_POKE_FLUTE] = { + .name = _("POKé FLUTE$"), + .itemId = ITEM_POKE_FLUTE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPokeFluteItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SECRET_KEY] = { + .name = _("SECRET KEY$"), + .itemId = ITEM_SECRET_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSecretKeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BIKE_VOUCHER] = { + .name = _("BIKE VOUCHER$"), + .itemId = ITEM_BIKE_VOUCHER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBikeVoucherItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_GOLD_TEETH] = { + .name = _("GOLD TEETH$"), + .itemId = ITEM_GOLD_TEETH, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gGoldTeethItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_OLD_AMBER] = { + .name = _("OLD AMBER$"), + .itemId = ITEM_OLD_AMBER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_CARD_KEY] = { + .name = _("CARD KEY$"), + .itemId = ITEM_CARD_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gCardKeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_LIFT_KEY] = { + .name = _("LIFT KEY$"), + .itemId = ITEM_LIFT_KEY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gLiftKeyItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_HELIX_FOSSIL] = { + .name = _("HELIX FOSSIL$"), + .itemId = ITEM_HELIX_FOSSIL, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gHelixFossilItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_DOME_FOSSIL] = { + .name = _("DOME FOSSIL$"), + .itemId = ITEM_DOME_FOSSILE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gDomeFossilItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SILPH_SCOPE] = { + .name = _("SILPH SCOPE$"), + .itemId = ITEM_SILPH_SCOPE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSilphScopeItemDescription, + .importance = 1, + .unk19 = 0, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BICYCLE] = { + .name = _("BICYCLE$"), + .itemId = ITEM_BICYCLE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBicycleItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TOWN_MAP] = { + .name = _("TOWN MAP$"), + .itemId = ITEM_TOWN_MAP, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTownMapItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_VS_SEEKER] = { + .name = _("VS SEEKER$"), + .itemId = ITEM_VS_SEEKER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gVSSeekerItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_FAME_CHECKER] = { + .name = _("FAME CHECKER$"), + .itemId = ITEM_FAME_CHECKER, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gFameCheckerItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TM_CASE] = { + .name = _("TM CASE$"), + .itemId = ITEM_TM_CASE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTMCaseItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_BERRY_POUCH] = { + .name = _("BERRY POUCH$"), + .itemId = ITEM_BERRY_POUCH, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gBerryPouchItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TEACHY_TV] = { + .name = _("TEACHY TV$"), + .itemId = ITEM_TEACHY_TV, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTeachyTVItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 2, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TRI_PASS] = { + .name = _("TRI-PASS$"), + .itemId = ITEM_TRI_PASS, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTriPassItemDescription, + .importance = 1, + .unk19 = 4, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_RAINBOW_PASS] = { + .name = _("RAINBOW PASS$"), + .itemId = ITEM_RAINBOW_PASS, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRainbowPassItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_TEA] = { + .name = _("TEA$"), + .itemId = ITEM_TEA, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gTeaItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_MYSTIC_TICKET] = { + .name = _("MYSTICTICKET$"), + .itemId = ITEM_MYSTIC_TICKET, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMysticTicketItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_AURORA_TICKET] = { + .name = _("AURORATICKET$"), + .itemId = ITEM_AURORA_TICKET, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gAuroraTicketItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_POWDER_JAR] = { + .name = _("POWDER JAR$"), + .itemId = ITEM_POWDER_JAR, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gPowderJarItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_PowderJar, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_RUBY] = { + .name = _("RUBY$"), + .itemId = ITEM_RUBY, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gRubyItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_SAPPHIRE] = { + .name = _("SAPPHIRE$"), + .itemId = ITEM_SAPPHIRE, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gSapphireItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +//Emerald-specific key items + + [ITEM_MAGMA_EMBLEM] = { + .name = _("MAGMA EMBLEM$"), + .itemId = ITEM_MAGMA_EMBLEM, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gMagmaEmblemItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + + [ITEM_OLD_SEA_MAP] = { + .name = _("OLD SEA MAP$"), + .itemId = ITEM_OLD_SEA_MAP, + .price = 0, + .holdEffect = 0, + .holdEffectParam = 0, + .description = gOldSeaMapItemDescription, + .importance = 1, + .unk19 = 1, + .pocket = POCKET_KEY_ITEMS, + .type = 4, + .fieldUseFunc = ItemUseOutOfBattle_CannotUse, + .battleUsage = 0, + .battleUseFunc = NULL, + .secondaryId = 0, + }, + +}; -- cgit v1.2.3 From f56067bb63e0b8c2d4ffed9cef2448e7229919db Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Mon, 23 Apr 2018 22:14:30 +0100 Subject: Update items.c --- src/items.c | 208 ++++++++++++++++++++++++++++++------------------------------ 1 file changed, 104 insertions(+), 104 deletions(-) (limited to 'src') diff --git a/src/items.c b/src/items.c index e2427c4cc..9d92acfca 100644 --- a/src/items.c +++ b/src/items.c @@ -2,35 +2,35 @@ #include "item.h" #include "item_use.h" #include "constants/items.h" - +//encode test const u8 gDummyItemDescription[] = _("?????$"); //pokeballs -const u8 gMasterBallItemDescription[] = _("The best BALL that\ncatches a POKéMON\nwithout fail.$"); +const u8 gMasterBallItemDescription[] = _("The best BALL that\ncatches a POKĂ©MON\nwithout fail.$"); const u8 gUltraBallItemDescription[] = _("A better BALL with\na higher catch rate\nthan a GREAT BALL.$"); -const u8 gGreatBallItemDescription[] = _("A good BALL with a\nhigher catch rate\nthan a POKé BALL.$"); -const u8 gPokeBallItemDescription[] = _("A tool used for\ncatching wild\nPOKéMON.$"); +const u8 gGreatBallItemDescription[] = _("A good BALL with a\nhigher catch rate\nthan a POKĂ© BALL.$"); +const u8 gPokeBallItemDescription[] = _("A tool used for\ncatching wild\nPOKĂ©MON.$"); const u8 gSafariBallItemDescription[] = _("A special BALL that\nis used only in the\nSAFARI ZONE.$"); -const u8 gNetBallItemDescription[] = _("A BALL that works\nwell on WATER- and\nBUG-type POKéMON.$"); -const u8 gDiveBallItemDescription[] = _("A BALL that works\nbetter on POKéMON\non the ocean floor.$"); -const u8 gNestBallItemDescription[] = _("A BALL that works\nbetter on weaker\nPOKéMON.$"); -const u8 gRepeatBallItemDescription[] = _("A BALL that works\nbetter on POKéMON\ncaught before.$"); +const u8 gNetBallItemDescription[] = _("A BALL that works\nwell on WATER- and\nBUG-type POKĂ©MON.$"); +const u8 gDiveBallItemDescription[] = _("A BALL that works\nbetter on POKĂ©MON\non the ocean floor.$"); +const u8 gNestBallItemDescription[] = _("A BALL that works\nbetter on weaker\nPOKĂ©MON.$"); +const u8 gRepeatBallItemDescription[] = _("A BALL that works\nbetter on POKĂ©MON\ncaught before.$"); const u8 gTimerBallItemDescription[] = _("A BALL that gains\npower in battles\ntaking many turns.$"); -const u8 gLuxuryBallItemDescription[] = _("A cozy BALL that\nmakes POKéMON\nmore friendly.$"); +const u8 gLuxuryBallItemDescription[] = _("A cozy BALL that\nmakes POKĂ©MON\nmore friendly.$"); const u8 gPremierBallItemDescription[] = _("A rare BALL made\nin commemoration\nof some event.$"); //medicine -const u8 gPotionItemDescription[] = _("Restores the HP of\na POKéMON by\n20 points.$"); -const u8 gAntidoteItemDescription[] = _("Heals a poisoned\nPOKéMON.$"); -const u8 gBurnHealItemDescription[] = _("Heals POKéMON\nof a burn.$"); -const u8 gIceHealItemDescription[] = _("Defrosts a frozen\nPOKéMON.$"); -const u8 gAwakeningItemDescription[] = _("Awakens a sleeping\nPOKéMON.$"); -const u8 gParalyzeHealItemDescription[] = _("Heals a paralyzed\nPOKéMON.$"); -const u8 gFullRestoreItemDescription[] = _("Fully restores the\nHP and status of a\nPOKéMON.$"); -const u8 gMaxPotionItemDescription[] = _("Fully restores the\nHP of a POKéMON.$"); -const u8 gHyperPotionItemDescription[] = _("Restores the HP of\na POKéMON by\n200 points.$"); -const u8 gSuperPotionItemDescription[] = _("Restores the HP of\na POKéMON by\n50 points.$"); -const u8 gFullHealItemDescription[] = _("Heals all the\nstatus problems of\none POKéMON.$"); -const u8 gReviveItemDescription[] = _("Revives a fainted\nPOKéMON with half\nits HP.$"); -const u8 gMaxReviveItemDescription[] = _("Revives a fainted\nPOKéMON with all\nits HP.$"); +const u8 gPotionItemDescription[] = _("Restores the HP of\na POKĂ©MON by\n20 points.$"); +const u8 gAntidoteItemDescription[] = _("Heals a poisoned\nPOKĂ©MON.$"); +const u8 gBurnHealItemDescription[] = _("Heals POKĂ©MON\nof a burn.$"); +const u8 gIceHealItemDescription[] = _("Defrosts a frozen\nPOKĂ©MON.$"); +const u8 gAwakeningItemDescription[] = _("Awakens a sleeping\nPOKĂ©MON.$"); +const u8 gParalyzeHealItemDescription[] = _("Heals a paralyzed\nPOKĂ©MON.$"); +const u8 gFullRestoreItemDescription[] = _("Fully restores the\nHP and status of a\nPOKĂ©MON.$"); +const u8 gMaxPotionItemDescription[] = _("Fully restores the\nHP of a POKĂ©MON.$"); +const u8 gHyperPotionItemDescription[] = _("Restores the HP of\na POKĂ©MON by\n200 points.$"); +const u8 gSuperPotionItemDescription[] = _("Restores the HP of\na POKĂ©MON by\n50 points.$"); +const u8 gFullHealItemDescription[] = _("Heals all the\nstatus problems of\none POKĂ©MON.$"); +const u8 gReviveItemDescription[] = _("Revives a fainted\nPOKĂ©MON with half\nits HP.$"); +const u8 gMaxReviveItemDescription[] = _("Revives a fainted\nPOKĂ©MON with all\nits HP.$"); const u8 gFreshWaterItemDescription[] = _("A mineral water\nthat restores HP\nby 50 points.$"); const u8 gSodaPopItemDescription[] = _("A fizzy soda drink\nthat restores HP\nby 60 points.$"); const u8 gLemonadeItemDescription[] = _("A very sweet drink\nthat restores HP\nby 80 points.$"); @@ -38,19 +38,19 @@ const u8 gMoomooMilkItemDescription[] = _("A nutritious milk\nthat restores HP\n const u8 gEnergyPowderItemDescription[] = _("A bitter powder\nthat restores HP\nby 50 points.$"); const u8 gEnergyRootItemDescription[] = _("A bitter root\nthat restores HP\nby 200 points.$"); const u8 gHealPowderItemDescription[] = _("A bitter powder\nthat heals all\nstatus problems.$"); -const u8 gRevivalHerbItemDescription[] = _("A very bitter herb\nthat revives a\nfainted POKéMON.$"); +const u8 gRevivalHerbItemDescription[] = _("A very bitter herb\nthat revives a\nfainted POKĂ©MON.$"); const u8 gEtherItemDescription[] = _("Restores the PP\nof a selected move\nby 10.$"); const u8 gMaxEtherItemDescription[] = _("Fully restores the\nPP of a selected\nmove.$"); const u8 gElixirItemDescription[] = _("Restores the PP\nof all moves by 10.$"); -const u8 gMaxElixirItemDescription[] = _("Fully restores the\nPP of a POKéMON’s\nmoves.$"); +const u8 gMaxElixirItemDescription[] = _("Fully restores the\nPP of a POKĂ©MON’s\nmoves.$"); const u8 gLavaCookieItemDescription[] = _("A local specialty\nthat heals all\nstatus problems.$"); -const u8 gBlueFluteItemDescription[] = _("A glass flute that\nawakens sleeping\nPOKéMON.$"); -const u8 gYellowFluteItemDescription[] = _("A glass flute that\nsnaps POKéMON\nout of confusion.$"); -const u8 gRedFluteItemDescription[] = _("A glass flute that\nsnaps POKéMON\nout of attraction.$"); -const u8 gBlackFluteItemDescription[] = _("A glass flute that\nkeeps away wild\nPOKéMON.$"); -const u8 gWhiteFluteItemDescription[] = _("A glass flute that\nlures wild POKéMON.$"); +const u8 gBlueFluteItemDescription[] = _("A glass flute that\nawakens sleeping\nPOKĂ©MON.$"); +const u8 gYellowFluteItemDescription[] = _("A glass flute that\nsnaps POKĂ©MON\nout of confusion.$"); +const u8 gRedFluteItemDescription[] = _("A glass flute that\nsnaps POKĂ©MON\nout of attraction.$"); +const u8 gBlackFluteItemDescription[] = _("A glass flute that\nkeeps away wild\nPOKĂ©MON.$"); +const u8 gWhiteFluteItemDescription[] = _("A glass flute that\nlures wild POKĂ©MON.$"); const u8 gBerryJuiceItemDescription[] = _("A 100% pure juice\nthat restores HP\nby 20 points.$"); -const u8 gSacredAshItemDescription[] = _("Fully revives and\nrestores all\nfainted POKéMON.$"); +const u8 gSacredAshItemDescription[] = _("Fully revives and\nrestores all\nfainted POKĂ©MON.$"); //collectibles const u8 gShoalSaltItemDescription[] = _("Salt obtained from\ndeep inside the\nSHOAL CAVE.$"); const u8 gShoalShellItemDescription[] = _("A seashell found\ndeep inside the\nSHOAL CAVE.$"); @@ -59,14 +59,14 @@ const u8 gBlueShardItemDescription[] = _("A shard from an\nancient item. Can\nbe const u8 gYellowShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); const u8 gGreenShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); //vitamins -const u8 gHPUpItemDescription[] = _("Raises the base HP\nof one POKéMON.$"); -const u8 gProteinItemDescription[] = _("Raises the base\nATTACK stat of one\nPOKéMON.$"); -const u8 gIronItemDescription[] = _("Raises the base\nDEFENSE stat of\none POKéMON.$"); -const u8 gCarbosItemDescription[] = _("Raises the base\nSPEED stat of one\nPOKéMON.$"); -const u8 gCalciumItemDescription[] = _("Raises the base\nSP. ATK stat of one\nPOKéMON.$"); -const u8 gRareCandyItemDescription[] = _("Raises the level\nof a POKéMON by\none.$"); +const u8 gHPUpItemDescription[] = _("Raises the base HP\nof one POKĂ©MON.$"); +const u8 gProteinItemDescription[] = _("Raises the base\nATTACK stat of one\nPOKĂ©MON.$"); +const u8 gIronItemDescription[] = _("Raises the base\nDEFENSE stat of\none POKĂ©MON.$"); +const u8 gCarbosItemDescription[] = _("Raises the base\nSPEED stat of one\nPOKĂ©MON.$"); +const u8 gCalciumItemDescription[] = _("Raises the base\nSP. ATK stat of one\nPOKĂ©MON.$"); +const u8 gRareCandyItemDescription[] = _("Raises the level\nof a POKĂ©MON by\none.$"); const u8 gPPUpItemDescription[] = _("Raises the maximum\nPP of a selected\nmove.$"); -const u8 gZincItemDescription[] = _("Raises the base\nSP. DEF stat of one\nPOKéMON.$"); +const u8 gZincItemDescription[] = _("Raises the base\nSP. DEF stat of one\nPOKĂ©MON.$"); const u8 gPPMaxItemDescription[] = _("Raises the PP of a\nmove to its maximum\npoints.$"); //battle items const u8 gGuardSpecItemDescription[] = _("Prevents stat\nreduction when\nused in battle.$"); @@ -76,20 +76,20 @@ const u8 gXDefendItemDescription[] = _("Raises the stat\nDEFENSE during one\nbat const u8 gXSpeedItemDescription[] = _("Raises the stat\nSPEED during one\nbattle.$"); const u8 gXAccuracyItemDescription[] = _("Raises accuracy\nof attack moves\nduring one battle.$"); const u8 gXSpecialItemDescription[] = _("Raises the stat\nSP. ATK during one\nbattle.$"); -const u8 gPokeDollItemDescription[] = _("Use to flee from\nany battle with\na wild POKéMON.$"); -const u8 gFluffyTailItemDescription[] = _("Use to flee from\nany battle with\na wild POKéMON.$"); +const u8 gPokeDollItemDescription[] = _("Use to flee from\nany battle with\na wild POKĂ©MON.$"); +const u8 gFluffyTailItemDescription[] = _("Use to flee from\nany battle with\na wild POKĂ©MON.$"); //field items -const u8 gSuperRepelItemDescription[] = _("Repels weak wild\nPOKéMON for 200\nsteps.$"); -const u8 gMaxRepelItemDescription[] = _("Repels weak wild\nPOKéMON for 250\nsteps.$"); +const u8 gSuperRepelItemDescription[] = _("Repels weak wild\nPOKĂ©MON for 200\nsteps.$"); +const u8 gMaxRepelItemDescription[] = _("Repels weak wild\nPOKĂ©MON for 250\nsteps.$"); const u8 gEscapeRopeItemDescription[] = _("Use to escape\ninstantly from a\ncave or a dungeon.$"); -const u8 gRepelItemDescription[] = _("Repels weak wild\nPOKéMON for 100\nsteps.$"); +const u8 gRepelItemDescription[] = _("Repels weak wild\nPOKĂ©MON for 100\nsteps.$"); //evolution stones -const u8 gSunStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); -const u8 gMoonStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); -const u8 gFireStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); -const u8 gThunderStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); -const u8 gWaterStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); -const u8 gLeafStoneItemDescription[] = _("Makes certain\nspecies of POKéMON\nevolve.$"); +const u8 gSunStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); +const u8 gMoonStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); +const u8 gFireStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); +const u8 gThunderStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); +const u8 gWaterStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); +const u8 gLeafStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); //valuable items const u8 gTinyMushroomItemDescription[] = _("A plain mushroom\nthat would sell\nat a cheap price.$"); const u8 gBigMushroomItemDescription[] = _("A rare mushroom\nthat would sell at a\nhigh price.$"); @@ -100,24 +100,24 @@ const u8 gStarPieceItemDescription[] = _("A red gem shard.\nIt would sell for a\ const u8 gNuggetItemDescription[] = _("A nugget of pure\ngold. Can be sold at\na high price.$"); const u8 gHeartScaleItemDescription[] = _("A lovely scale.\nIt is coveted by\ncollectors.$"); //mail -const u8 gOrangeMailItemDescription[] = _("A ZIGZAGOON-print\nMAIL to be held by\na POKéMON.$"); -const u8 gHarborMailItemDescription[] = _("A WINGULL-print\nMAIL to be held by\na POKéMON.$"); -const u8 gGlitterMailItemDescription[] = _("A PIKACHU-print\nMAIL to be held by\na POKéMON.$"); -const u8 gMechMailItemDescription[] = _("A MAGNEMITE-print\nMAIL to be held by\na POKéMON.$"); -const u8 gWoodMailItemDescription[] = _("A SLAKOTH-print\nMAIL to be held by\na POKéMON.$"); -const u8 gWaveMailItemDescription[] = _("A WAILMER-print\nMAIL to be held by\na POKéMON.$"); -const u8 gBeadMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKéMON.$"); -const u8 gShadowMailItemDescription[] = _("A DUSKULL-print\nMAIL to be held by\na POKéMON.$"); -const u8 gTropicMailItemDescription[] = _("A BELLOSSOM-print\nMAIL to be held by\na POKéMON.$"); -const u8 gDreamMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKéMON.$"); -const u8 gFabMailItemDescription[] = _("A gorgeous-print\nMAIL to be held\nby a POKéMON.$"); -const u8 gRetroMailItemDescription[] = _("MAIL featuring the\ndrawings of three\nPOKéMON.$"); +const u8 gOrangeMailItemDescription[] = _("A ZIGZAGOON-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gHarborMailItemDescription[] = _("A WINGULL-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gGlitterMailItemDescription[] = _("A PIKACHU-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gMechMailItemDescription[] = _("A MAGNEMITE-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gWoodMailItemDescription[] = _("A SLAKOTH-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gWaveMailItemDescription[] = _("A WAILMER-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gBeadMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKĂ©MON.$"); +const u8 gShadowMailItemDescription[] = _("A DUSKULL-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gTropicMailItemDescription[] = _("A BELLOSSOM-print\nMAIL to be held by\na POKĂ©MON.$"); +const u8 gDreamMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKĂ©MON.$"); +const u8 gFabMailItemDescription[] = _("A gorgeous-print\nMAIL to be held\nby a POKĂ©MON.$"); +const u8 gRetroMailItemDescription[] = _("MAIL featuring the\ndrawings of three\nPOKĂ©MON.$"); //berries const u8 gCheriBerryItemDescription[] = _("A hold item that\nheals paralysis\nin battle.$"); -const u8 gChestoBerryItemDescription[] = _("A hold item that\nawakens POKéMON\nin battle.$"); +const u8 gChestoBerryItemDescription[] = _("A hold item that\nawakens POKĂ©MON\nin battle.$"); const u8 gPechaBerryItemDescription[] = _("A hold item that\nheals poisoning\nin battle.$"); const u8 gRawstBerryItemDescription[] = _("A hold item that\nheals a burn in\nbattle.$"); -const u8 gAspearBerryItemDescription[] = _("A hold item that\ndefrosts POKéMON\nin battle.$"); +const u8 gAspearBerryItemDescription[] = _("A hold item that\ndefrosts POKĂ©MON\nin battle.$"); const u8 gLeppaBerryItemDescription[] = _("A hold item that\nrestores 10 PP in\nbattle.$"); const u8 gOranBerryItemDescription[] = _("A hold item that\nrestores 10 HP in\nbattle.$"); const u8 gPersimBerryItemDescription[] = _("A hold item that\nheals confusion\nin battle.$"); @@ -133,12 +133,12 @@ const u8 gBlukBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loam const u8 gNanabBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow NANAB.$"); const u8 gWepearBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow WEPEAR.$"); const u8 gPinapBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow PINAP.$"); -const u8 gPomegBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase HP.$"); -const u8 gKelpsyBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase ATTACK.$"); -const u8 gQualotBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase DEFENSE.$"); -const u8 gHondewBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase SP. ATK.$"); -const u8 gGrepaBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase SP. DEF.$"); -const u8 gTamatoBerryItemDescription[] = _("Makes a POKéMON\nfriendly but lowers\nbase SPEED.$"); +const u8 gPomegBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase HP.$"); +const u8 gKelpsyBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase ATTACK.$"); +const u8 gQualotBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase DEFENSE.$"); +const u8 gHondewBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase SP. ATK.$"); +const u8 gGrepaBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase SP. DEF.$"); +const u8 gTamatoBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase SPEED.$"); const u8 gCornnBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow CORNN.$"); const u8 gMagostBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow MAGOST.$"); const u8 gRabutaBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow RABUTA.$"); @@ -163,23 +163,23 @@ const u8 gMachoBraceItemDescription[] = _("A hold item that\npromotes growth,\nb const u8 gExpShareItemDescription[] = _("A hold item that\ngets EXP. points\nfrom battles.$"); const u8 gQuickClawItemDescription[] = _("A hold item that\noccasionally allows\nthe first strike.$"); const u8 gSootheBellItemDescription[] = _("A hold item that\ncalms spirits and\nfosters friendship.$"); -const u8 gMentalHerbItemDescription[] = _("A hold item that\nsnaps POKéMON out\nof infatuation.$"); -const u8 gChoiceBandItemDescription[] = _("Raises a move’s\npower, but permits\nonly that move.$"); +const u8 gMentalHerbItemDescription[] = _("A hold item that\nsnaps POKĂ©MON out\nof infatuation.$"); +const u8 gChoiceBandItemDescription[] = _("Raises a move’s\npower, but permits\nonly that move.$"); const u8 gKingsRockItemDescription[] = _("A hold item that\nmay cause flinching\nwhen the foe is hit.$"); const u8 gSilverPowderItemDescription[] = _("A hold item that\nraises the power of\nBUG-type moves.$"); const u8 gAmuletCoinItemDescription[] = _("Doubles money in\nbattle if the\nholder takes part.$"); -const u8 gCleanseTagItemDescription[] = _("A hold item that\nhelps repel wild\nPOKéMON.$"); +const u8 gCleanseTagItemDescription[] = _("A hold item that\nhelps repel wild\nPOKĂ©MON.$"); const u8 gSoulDewItemDescription[] = _("Hold item: raises\nSP. ATK & SP. DEF of\nLATIOS & LATIAS.$"); const u8 gDeepSeaToothItemDescription[] = _("A hold item that\nraises the SP. ATK\nof CLAMPERL.$"); const u8 gDeepSeaScaleItemDescription[] = _("A hold item that\nraises the SP. DEF\nof CLAMPERL.$"); -const u8 gSmokeBallItemDescription[] = _("A hold item that\nassures fleeing\nfrom wild POKéMON.$"); +const u8 gSmokeBallItemDescription[] = _("A hold item that\nassures fleeing\nfrom wild POKĂ©MON.$"); const u8 gEverstoneItemDescription[] = _("A wondrous hold\nitem that prevents\nevolution.$"); const u8 gFocusBandItemDescription[] = _("A hold item that\noccasionally\nprevents fainting.$"); const u8 gLuckyEggItemDescription[] = _("A hold item that\nboosts EXP. points\nearned in battle.$"); const u8 gScopeLensItemDescription[] = _("A hold item that\nimproves the\ncritical-hit rate.$"); const u8 gMetalCoatItemDescription[] = _("A hold item that\nraises the power of\nSTEEL-type moves.$"); const u8 gLeftoversItemDescription[] = _("A hold item that\ngradually restores\nHP in battle.$"); -const u8 gDragonScaleItemDescription[] = _("A strange scale\nheld by DRAGON-\ntype POKéMON.$"); +const u8 gDragonScaleItemDescription[] = _("A strange scale\nheld by DRAGON-\ntype POKĂ©MON.$"); const u8 gLightBallItemDescription[] = _("A hold item that\nraises the SP. ATK\nof PIKACHU.$"); const u8 gSoftSandItemDescription[] = _("A hold item that\nraises the power of\nGROUND-type moves.$"); const u8 gHardStoneItemDescription[] = _("A hold item that\nraises the power of\nROCK-type moves.$"); @@ -199,11 +199,11 @@ const u8 gSilkScarfItemDescription[] = _("A hold item that\nraises the power of\ const u8 gUpGradeItemDescription[] = _("A peculiar box made\nby SILPH CO.$"); const u8 gShellBellItemDescription[] = _("A hold item that\nrestores HP upon\nstriking the foe.$"); const u8 gSeaIncenseItemDescription[] = _("A hold item that\nslightly boosts\nWATER-type moves.$"); -const u8 gLaxIncenseItemDescription[] = _("A hold item that\nslightly lowers the\nfoe’s accuracy.$"); -const u8 gLuckyPunchItemDescription[] = _("A hold item that\nraises CHANSEY’s\ncritical-hit rate.$"); -const u8 gMetalPowderItemDescription[] = _("A hold item that\nraises DITTO’s\nDEFENSE.$"); -const u8 gThickClubItemDescription[] = _("A hold item that \nraises CUBONE or\nMAROWAK’s ATTACK.$"); -const u8 gStickItemDescription[] = _("A hold item that\nraises FARFETCH’D’s\ncritical-hit ratio.$"); +const u8 gLaxIncenseItemDescription[] = _("A hold item that\nslightly lowers the\nfoe’s accuracy.$"); +const u8 gLuckyPunchItemDescription[] = _("A hold item that\nraises CHANSEY’s\ncritical-hit rate.$"); +const u8 gMetalPowderItemDescription[] = _("A hold item that\nraises DITTO’s\nDEFENSE.$"); +const u8 gThickClubItemDescription[] = _("A hold item that \nraises CUBONE or\nMAROWAK’s ATTACK.$"); +const u8 gStickItemDescription[] = _("A hold item that\nraises FARFETCH’D’s\ncritical-hit ratio.$"); const u8 gRedScarfItemDescription[] = _("A hold item that\nraises COOL in\nCONTESTS.$"); const u8 gBlueScarfItemDescription[] = _("A hold item that\nraises BEAUTY in\nCONTESTS.$"); const u8 gPinkScarfItemDescription[] = _("A hold item that\nraises CUTE in\nCONTESTS.$"); @@ -213,13 +213,13 @@ const u8 gYellowScarfItemDescription[] = _("A hold item that\nraises TOUGH in\nC const u8 gMachBikeItemDescription[] = _("A folding bicycle\nthat doubles your\nspeed or better.$"); const u8 gCoinCaseItemDescription[] = _("A case that holds\nup to 9,999 COINS.$"); const u8 gItemfinderItemDescription[] = _("A device that\nsignals an invisible\nitem by sound.$"); -const u8 gOldRodItemDescription[] = _("Use by any body of\nwater to fish for\nwild POKéMON.$"); -const u8 gGoodRodItemDescription[] = _("A decent fishing\nrod for catching\nwild POKéMON.$"); -const u8 gSuperRodItemDescription[] = _("The best fishing\nrod for catching\nwild POKéMON.$"); +const u8 gOldRodItemDescription[] = _("Use by any body of\nwater to fish for\nwild POKĂ©MON.$"); +const u8 gGoodRodItemDescription[] = _("A decent fishing\nrod for catching\nwild POKĂ©MON.$"); +const u8 gSuperRodItemDescription[] = _("The best fishing\nrod for catching\nwild POKĂ©MON.$"); const u8 gSSTicketItemDescription[] = _("The ticket required\nfor sailing on a\nferry.$"); -const u8 gContestPassItemDescription[] = _("The pass required\nfor entering\nPOKéMON CONTESTS.$"); +const u8 gContestPassItemDescription[] = _("The pass required\nfor entering\nPOKĂ©MON CONTESTS.$"); const u8 gWailmerPailItemDescription[] = _("A tool used for\nwatering BERRIES\nand plants.$"); -const u8 gDevonGoodsItemDescription[] = _("A package that\ncontains DEVON’s\nmachine parts.$"); +const u8 gDevonGoodsItemDescription[] = _("A package that\ncontains DEVON’s\nmachine parts.$"); const u8 gSootSackItemDescription[] = _("A sack used to\ngather and hold\nvolcanic ash.$"); const u8 gBasementKeyItemDescription[] = _("The key for NEW\nMAUVILLE beneath\nMAUVILLE CITY.$"); const u8 gAcroBikeItemDescription[] = _("A folding bicycle\ncapable of jumps\nand wheelies.$"); @@ -236,9 +236,9 @@ const u8 gRoom2KeyItemDescription[] = _("A key that opens a\ndoor inside the\nAB const u8 gRoom4KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); const u8 gRoom6KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); const u8 gStorageKeyItemDescription[] = _("The key to the\nstorage inside the\nABANDONED SHIP.$"); -const u8 gRootFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKéMON.$"); -const u8 gClawFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKéMON.$"); -const u8 gDevonScopeItemDescription[] = _("A device by DEVON\nthat signals any\nunseeable POKéMON.$"); +const u8 gRootFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKĂ©MON.$"); +const u8 gClawFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKĂ©MON.$"); +const u8 gDevonScopeItemDescription[] = _("A device by DEVON\nthat signals any\nunseeable POKĂ©MON.$"); //TMs/HMs const u8 gTM01ItemDescription[] = _("Powerful, but makes\nthe user flinch if\nhit by the foe.$"); const u8 gTM02ItemDescription[] = _("Hooks and slashes\nthe foe with long,\nsharp claws.$"); @@ -249,7 +249,7 @@ const u8 gTM06ItemDescription[] = _("Poisons the foe\nwith a toxin that\ngradual const u8 gTM07ItemDescription[] = _("Creates a hailstorm\nthat damages all\ntypes except ICE.$"); const u8 gTM08ItemDescription[] = _("Bulks up the body\nto boost both\nATTACK & DEFENSE.$"); const u8 gTM09ItemDescription[] = _("Shoots 2 to 5 seeds\nin a row to strike\nthe foe.$"); -const u8 gTM10ItemDescription[] = _("The attack power\nvaries among\ndifferent POKéMON.$"); +const u8 gTM10ItemDescription[] = _("The attack power\nvaries among\ndifferent POKĂ©MON.$"); const u8 gTM11ItemDescription[] = _("Raises the power of\nFIRE-type moves\nfor 5 turns.$"); const u8 gTM12ItemDescription[] = _("Enrages the foe so\nit can only use\nattack moves.$"); const u8 gTM13ItemDescription[] = _("Fires an icy cold\nbeam that may\nfreeze the foe.$"); @@ -279,13 +279,13 @@ const u8 gTM36ItemDescription[] = _("Hurls sludge at the\nfoe. It may poison\nth const u8 gTM37ItemDescription[] = _("Causes a sandstorm\nthat hits the foe\nover several turns.$"); const u8 gTM38ItemDescription[] = _("A powerful fire\nattack that may\nburn the foe.$"); const u8 gTM39ItemDescription[] = _("Stops the foe from\nmoving with rocks.\nMay lower SPEED.$"); -const u8 gTM40ItemDescription[] = _("An extremely fast\nattack that can’t\nbe avoided.$"); +const u8 gTM40ItemDescription[] = _("An extremely fast\nattack that can’t\nbe avoided.$"); const u8 gTM41ItemDescription[] = _("Prevents the foe\nfrom using the same\nmove in a row.$"); const u8 gTM42ItemDescription[] = _("Raises ATTACK when\npoisoned, burned,\nor paralyzed.$"); const u8 gTM43ItemDescription[] = _("Adds an effect to\nattack depending\non the location.$"); const u8 gTM44ItemDescription[] = _("The user sleeps for\n2 turns to restore\nhealth and status.$"); const u8 gTM45ItemDescription[] = _("Makes it tough to\nattack a foe of the\nopposite gender.$"); -const u8 gTM46ItemDescription[] = _("While attacking,\nit may steal the\nfoe’s held item.$"); +const u8 gTM46ItemDescription[] = _("While attacking,\nit may steal the\nfoe’s held item.$"); const u8 gTM47ItemDescription[] = _("Spreads hard-\nedged wings and\nslams into the foe.$"); const u8 gTM48ItemDescription[] = _("Switches abilities\nwith the foe on the\nturn this is used.$"); const u8 gTM49ItemDescription[] = _("Steals the effects\nof the move the foe\nis trying to use.$"); @@ -300,17 +300,17 @@ const u8 gHM06ItemDescription[] = _("A rock-crushingly\ntough attack that\nmay l const u8 gHM07ItemDescription[] = _("Attacks the foe\nwith enough power\nto climb waterfalls.$"); const u8 gHM08ItemDescription[] = _("Dives underwater\nthe 1st turn, then\nattacks next turn.$"); //FireRed/LeafGreen specific key items -const u8 gOaksParcelItemDescription[] = _("A parcel for PROF.\nOAK from a POKéMON\nMART’s clerk.$"); -const u8 gPokeFluteItemDescription[] = _("A sweet-sounding\nflute that awakens\nPOKéMON.$"); -const u8 gSecretKeyItemDescription[] = _("The key to the\nCINNABAR ISLAND\nGYM’s entrance.$"); +const u8 gOaksParcelItemDescription[] = _("A parcel for PROF.\nOAK from a POKĂ©MON\nMART’s clerk.$"); +const u8 gPokeFluteItemDescription[] = _("A sweet-sounding\nflute that awakens\nPOKĂ©MON.$"); +const u8 gSecretKeyItemDescription[] = _("The key to the\nCINNABAR ISLAND\nGYM’s entrance.$"); const u8 gBikeVoucherItemDescription[] = _("A voucher for\nobtaining a bicycle\nfrom the BIKE SHOP.$"); -const u8 gGoldTeethItemDescription[] = _("Gold dentures lost\nby the SAFARI\nZONE’s WARDEN.$"); -const u8 gOldAmberItemDescription[] = _("A stone containing\nthe genes of an\nancient POKéMON.$"); -const u8 gCardKeyItemDescription[] = _("A card-type door\nkey used in SILPH\nCO’s office.$"); -const u8 gLiftKeyItemDescription[] = _("An elevator key\nused in TEAM\nROCKET’s HIDEOUT.$"); -const u8 gHelixFossilItemDescription[] = _("A piece of an\nancient marine\nPOKéMON’s seashell.$"); -const u8 gDomeFossilItemDescription[] = _("A piece of an\nancient marine\nPOKéMON’s shell.$"); -const u8 gSilphScopeItemDescription[] = _("SILPH CO’s scope\nmakes unseeable\nPOKéMON visible.$"); +const u8 gGoldTeethItemDescription[] = _("Gold dentures lost\nby the SAFARI\nZONE’s WARDEN.$"); +const u8 gOldAmberItemDescription[] = _("A stone containing\nthe genes of an\nancient POKĂ©MON.$"); +const u8 gCardKeyItemDescription[] = _("A card-type door\nkey used in SILPH\nCO’s office.$"); +const u8 gLiftKeyItemDescription[] = _("An elevator key\nused in TEAM\nROCKET’s HIDEOUT.$"); +const u8 gHelixFossilItemDescription[] = _("A piece of an\nancient marine\nPOKĂ©MON’s seashell.$"); +const u8 gDomeFossilItemDescription[] = _("A piece of an\nancient marine\nPOKĂ©MON’s shell.$"); +const u8 gSilphScopeItemDescription[] = _("SILPH CO’s scope\nmakes unseeable\nPOKĂ©MON visible.$"); const u8 gBicycleItemDescription[] = _("A folding bicycle\nthat is faster than\nthe RUNNING SHOES.$"); const u8 gTownMapItemDescription[] = _("Can be viewed\nanytime. Shows your\npresent location.$"); const u8 gVSSeekerItemDescription[] = _("A rechargeable unit\nthat flags battle-\nready TRAINERS.$"); @@ -327,7 +327,7 @@ const u8 gPowderJarItemDescription[] = _("Stores BERRY\nPOWDER made using\na BER const u8 gRubyItemDescription[] = _("An exquisite, red-\nglowing gem that\nsymbolizes passion.$"); const u8 gSapphireItemDescription[] = _("A brilliant blue gem\nthat symbolizes\nhonesty.$"); //Emerald specific key items -const u8 gMagmaEmblemItemDescription[] = _("A medal-like item in\nthe same shape as\nTEAM MAGMA’s mark.$"); +const u8 gMagmaEmblemItemDescription[] = _("A medal-like item in\nthe same shape as\nTEAM MAGMA’s mark.$"); const u8 gOldSeaMapItemDescription[] = _("A faded sea chart\nthat shows the way\nto a certain island.$"); const struct Item gItems[] = { @@ -403,7 +403,7 @@ const struct Item gItems[] = { }, [ITEM_POKE_BALL] = { - .name = _("POKé BALL$"), + .name = _("POKĂ© BALL$"), .itemId = ITEM_POKE_BALL, .price = 200, .holdEffect = 0, @@ -1704,7 +1704,7 @@ const struct Item gItems[] = { }, [ITEM_POKE_DOLL] = { - .name = _("POKé DOLL$"), + .name = _("POKĂ© DOLL$"), .itemId = ITEM_POKE_DOLL, .price = 1000, .holdEffect = 0, @@ -6308,7 +6308,7 @@ const struct Item gItems[] = { //FireRed/LeafGreen key items [ITEM_OAKS_PARCEL] = { - .name = _("OAK’S PARCEL$"), + .name = _("OAK’S PARCEL$"), .itemId = ITEM_OAKS_PARCEL, .price = 0, .holdEffect = 0, @@ -6325,7 +6325,7 @@ const struct Item gItems[] = { }, [ITEM_POKE_FLUTE] = { - .name = _("POKé FLUTE$"), + .name = _("POKĂ© FLUTE$"), .itemId = ITEM_POKE_FLUTE, .price = 0, .holdEffect = 0, -- cgit v1.2.3 From 2d4ab9f4acba8a3c91ea52eca17d395ac21f12e4 Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Mon, 23 Apr 2018 23:25:03 +0100 Subject: Updated items.c Working but non-matching --- src/items.c | 66 +++++++++++++++++++++++++++++++++---------------------------- 1 file changed, 36 insertions(+), 30 deletions(-) (limited to 'src') diff --git a/src/items.c b/src/items.c index 9d92acfca..f48760169 100644 --- a/src/items.c +++ b/src/items.c @@ -2,7 +2,13 @@ #include "item.h" #include "item_use.h" #include "constants/items.h" -//encode test +//#include "item_data_constants.h" +#define POCKET_ITEMS 0x01 +#define POCKET_POKE_BALLS 0x02 +#define POCKET_TM_HM 0x03 +#define POCKET_BERRIES 0x04 +#define POCKET_KEY_ITEMS 0x05 + const u8 gDummyItemDescription[] = _("?????$"); //pokeballs const u8 gMasterBallItemDescription[] = _("The best BALL that\ncatches a POKĂ©MON\nwithout fail.$"); @@ -364,7 +370,7 @@ const struct Item gItems[] = { .type = 0, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 0, }, @@ -381,7 +387,7 @@ const struct Item gItems[] = { .type = 1, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 1, }, @@ -398,7 +404,7 @@ const struct Item gItems[] = { .type = 2, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 2, }, @@ -415,7 +421,7 @@ const struct Item gItems[] = { .type = 3, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 3, }, @@ -432,7 +438,7 @@ const struct Item gItems[] = { .type = 4, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 4, }, @@ -449,7 +455,7 @@ const struct Item gItems[] = { .type = 5, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 5, }, @@ -466,7 +472,7 @@ const struct Item gItems[] = { .type = 6, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 6, }, @@ -483,7 +489,7 @@ const struct Item gItems[] = { .type = 7, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 7, }, @@ -500,7 +506,7 @@ const struct Item gItems[] = { .type = 8, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 8, }, @@ -517,7 +523,7 @@ const struct Item gItems[] = { .type = 9, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 9, }, @@ -532,9 +538,9 @@ const struct Item gItems[] = { .unk19 = 0, .pocket = POCKET_POKE_BALLS, .type = 10, - .ItemUseFunc fieldUseFunc = NULL, + .fieldUseFunc = NULL, .battleUsage = 2, - .ItemUseFunc battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 10, }, @@ -551,7 +557,7 @@ const struct Item gItems[] = { .type = 11, .fieldUseFunc = NULL, .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Pokeball, + .battleUseFunc = ItemUseInBattle_PokeBall, .secondaryId = 11, }, @@ -778,7 +784,7 @@ const struct Item gItems[] = { }, [ITEM_FRESH_WATER] = { .name = _("FRESH WATER$"), - .itemId = ITEM_FRESH_wATER, + .itemId = ITEM_FRESH_WATER, .price = 200, .holdEffect = 0, .holdEffectParam = 50, @@ -1213,7 +1219,7 @@ const struct Item gItems[] = { .price = 200, .holdEffect = 0, .holdEffectParam = 0, - .description = gItemDescription, + .description = gGreenShardItemDescription, .importance = 0, .unk19 = 0, .pocket = POCKET_ITEMS, @@ -1418,7 +1424,7 @@ const struct Item gItems[] = { .price = 9800, .holdEffect = 0, .holdEffectParam = 0, - .description = gHpUpItemDescription, + .description = gHPUpItemDescription, .importance = 0, .unk19 = 0, .pocket = POCKET_ITEMS, @@ -1465,7 +1471,7 @@ const struct Item gItems[] = { [ITEM_CARBOS] = { .name = _("CARBOS$"), - .itemId = ITEM_, + .itemId = ITEM_CARBOS, .price = 9800, .holdEffect = 0, .holdEffectParam = 0, @@ -2926,8 +2932,8 @@ const struct Item gItems[] = { }, [ITEM_WEPEAR_BERRY] = { - .name = _("WEAPER BERRY$"), - .itemId = ITEM_WEAPER_BERRY, + .name = _("WEPEAR BERRY$"), + .itemId = ITEM_WEPEAR_BERRY, .price = 20, .holdEffect = 0, .holdEffectParam = 0, @@ -3542,7 +3548,7 @@ const struct Item gItems[] = { }, [ITEM_KINGS_ROCK] = { - .name = _("KING'S ROCK$"), + .name = _("KING’S ROCK$"), .itemId = ITEM_KINGS_ROCK, .price = 100, .holdEffect = 30, @@ -3717,7 +3723,7 @@ const struct Item gItems[] = { .price = 200, .holdEffect = 40, .holdEffectParam = 0, - .description = gLuckyItemDescription, + .description = gLuckyEggItemDescription, .importance = 0, .unk19 = 0, .pocket = POCKET_ITEMS, @@ -3915,7 +3921,7 @@ const struct Item gItems[] = { .secondaryId = 0, }, - [ITEM_MYSTIC_wATER] = { + [ITEM_MYSTIC_WATER] = { .name = _("MYSTIC WATER$"), .itemId = ITEM_MYSTIC_WATER, .price = 100, @@ -4057,7 +4063,7 @@ const struct Item gItems[] = { .price = 100, .holdEffect = 60, .holdEffectParam = 10, - .description = gSilScarfItemDescription, + .description = gSilkScarfItemDescription, .importance = 0, .unk19 = 0, .pocket = POCKET_ITEMS, @@ -5285,7 +5291,7 @@ const struct Item gItems[] = { [ITEM_TM01] = { .name = _("TM$01"), - .itemId = ITEM_01TM, + .itemId = ITEM_TM01, .price = 3000, .holdEffect = 0, .holdEffectParam = 0, @@ -5302,7 +5308,7 @@ const struct Item gItems[] = { [ITEM_TM02] = { .name = _("TM02$"), - .itemId = ITEM_02TM, + .itemId = ITEM_TM02, .price = 3000, .holdEffect = 0, .holdEffectParam = 0, @@ -5319,7 +5325,7 @@ const struct Item gItems[] = { [ITEM_TM03] = { .name = _("TM03$"), - .itemId = ITEM_03TM, + .itemId = ITEM_TM03, .price = 3000, .holdEffect = 0, .holdEffectParam = 0, @@ -5374,7 +5380,7 @@ const struct Item gItems[] = { .price = 3000, .holdEffect = 0, .holdEffectParam = 0, - .description = gTMItemDescription, + .description = gTM06ItemDescription, .importance = 0, .unk19 = 0, .pocket = POCKET_TM_HM, @@ -6398,7 +6404,7 @@ const struct Item gItems[] = { .price = 0, .holdEffect = 0, .holdEffectParam = 0, - .description = gItemDescription, + .description = gOldAmberItemDescription, .importance = 1, .unk19 = 0, .pocket = POCKET_KEY_ITEMS, @@ -6462,7 +6468,7 @@ const struct Item gItems[] = { [ITEM_DOME_FOSSIL] = { .name = _("DOME FOSSIL$"), - .itemId = ITEM_DOME_FOSSILE, + .itemId = ITEM_DOME_FOSSIL, .price = 0, .holdEffect = 0, .holdEffectParam = 0, -- cgit v1.2.3 From a9d65ae6b66405d9470951e932a4d3b4b2f794df Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Tue, 24 Apr 2018 00:58:14 +0100 Subject: Move files to include/data --- src/item.c | 11 + src/items.c | 6794 ----------------------------------------------------------- 2 files changed, 11 insertions(+), 6794 deletions(-) delete mode 100644 src/items.c (limited to 'src') diff --git a/src/item.c b/src/item.c index a17599db9..9e521db77 100644 --- a/src/item.c +++ b/src/item.c @@ -25,6 +25,17 @@ enum KEYITEMS_POCKET }; +enum +{ + POCKET_ITEMS = 1, + POCKET_POKE_BALLS, + POCKET_TM_HM, + POCKET_BERRIES, + POCKET_KEY_ITEMS, +}; +#include "item_use.h" +#include "data/text/item_descriptions.h" +#include "data/items.h" u16 GetBagItemQuantity(u16* quantity) { return gSaveBlock2Ptr->encryptionKey ^ *quantity; diff --git a/src/items.c b/src/items.c deleted file mode 100644 index f48760169..000000000 --- a/src/items.c +++ /dev/null @@ -1,6794 +0,0 @@ -#include "global.h" -#include "item.h" -#include "item_use.h" -#include "constants/items.h" -//#include "item_data_constants.h" -#define POCKET_ITEMS 0x01 -#define POCKET_POKE_BALLS 0x02 -#define POCKET_TM_HM 0x03 -#define POCKET_BERRIES 0x04 -#define POCKET_KEY_ITEMS 0x05 - -const u8 gDummyItemDescription[] = _("?????$"); -//pokeballs -const u8 gMasterBallItemDescription[] = _("The best BALL that\ncatches a POKĂ©MON\nwithout fail.$"); -const u8 gUltraBallItemDescription[] = _("A better BALL with\na higher catch rate\nthan a GREAT BALL.$"); -const u8 gGreatBallItemDescription[] = _("A good BALL with a\nhigher catch rate\nthan a POKĂ© BALL.$"); -const u8 gPokeBallItemDescription[] = _("A tool used for\ncatching wild\nPOKĂ©MON.$"); -const u8 gSafariBallItemDescription[] = _("A special BALL that\nis used only in the\nSAFARI ZONE.$"); -const u8 gNetBallItemDescription[] = _("A BALL that works\nwell on WATER- and\nBUG-type POKĂ©MON.$"); -const u8 gDiveBallItemDescription[] = _("A BALL that works\nbetter on POKĂ©MON\non the ocean floor.$"); -const u8 gNestBallItemDescription[] = _("A BALL that works\nbetter on weaker\nPOKĂ©MON.$"); -const u8 gRepeatBallItemDescription[] = _("A BALL that works\nbetter on POKĂ©MON\ncaught before.$"); -const u8 gTimerBallItemDescription[] = _("A BALL that gains\npower in battles\ntaking many turns.$"); -const u8 gLuxuryBallItemDescription[] = _("A cozy BALL that\nmakes POKĂ©MON\nmore friendly.$"); -const u8 gPremierBallItemDescription[] = _("A rare BALL made\nin commemoration\nof some event.$"); -//medicine -const u8 gPotionItemDescription[] = _("Restores the HP of\na POKĂ©MON by\n20 points.$"); -const u8 gAntidoteItemDescription[] = _("Heals a poisoned\nPOKĂ©MON.$"); -const u8 gBurnHealItemDescription[] = _("Heals POKĂ©MON\nof a burn.$"); -const u8 gIceHealItemDescription[] = _("Defrosts a frozen\nPOKĂ©MON.$"); -const u8 gAwakeningItemDescription[] = _("Awakens a sleeping\nPOKĂ©MON.$"); -const u8 gParalyzeHealItemDescription[] = _("Heals a paralyzed\nPOKĂ©MON.$"); -const u8 gFullRestoreItemDescription[] = _("Fully restores the\nHP and status of a\nPOKĂ©MON.$"); -const u8 gMaxPotionItemDescription[] = _("Fully restores the\nHP of a POKĂ©MON.$"); -const u8 gHyperPotionItemDescription[] = _("Restores the HP of\na POKĂ©MON by\n200 points.$"); -const u8 gSuperPotionItemDescription[] = _("Restores the HP of\na POKĂ©MON by\n50 points.$"); -const u8 gFullHealItemDescription[] = _("Heals all the\nstatus problems of\none POKĂ©MON.$"); -const u8 gReviveItemDescription[] = _("Revives a fainted\nPOKĂ©MON with half\nits HP.$"); -const u8 gMaxReviveItemDescription[] = _("Revives a fainted\nPOKĂ©MON with all\nits HP.$"); -const u8 gFreshWaterItemDescription[] = _("A mineral water\nthat restores HP\nby 50 points.$"); -const u8 gSodaPopItemDescription[] = _("A fizzy soda drink\nthat restores HP\nby 60 points.$"); -const u8 gLemonadeItemDescription[] = _("A very sweet drink\nthat restores HP\nby 80 points.$"); -const u8 gMoomooMilkItemDescription[] = _("A nutritious milk\nthat restores HP\nby 100 points.$"); -const u8 gEnergyPowderItemDescription[] = _("A bitter powder\nthat restores HP\nby 50 points.$"); -const u8 gEnergyRootItemDescription[] = _("A bitter root\nthat restores HP\nby 200 points.$"); -const u8 gHealPowderItemDescription[] = _("A bitter powder\nthat heals all\nstatus problems.$"); -const u8 gRevivalHerbItemDescription[] = _("A very bitter herb\nthat revives a\nfainted POKĂ©MON.$"); -const u8 gEtherItemDescription[] = _("Restores the PP\nof a selected move\nby 10.$"); -const u8 gMaxEtherItemDescription[] = _("Fully restores the\nPP of a selected\nmove.$"); -const u8 gElixirItemDescription[] = _("Restores the PP\nof all moves by 10.$"); -const u8 gMaxElixirItemDescription[] = _("Fully restores the\nPP of a POKĂ©MON’s\nmoves.$"); -const u8 gLavaCookieItemDescription[] = _("A local specialty\nthat heals all\nstatus problems.$"); -const u8 gBlueFluteItemDescription[] = _("A glass flute that\nawakens sleeping\nPOKĂ©MON.$"); -const u8 gYellowFluteItemDescription[] = _("A glass flute that\nsnaps POKĂ©MON\nout of confusion.$"); -const u8 gRedFluteItemDescription[] = _("A glass flute that\nsnaps POKĂ©MON\nout of attraction.$"); -const u8 gBlackFluteItemDescription[] = _("A glass flute that\nkeeps away wild\nPOKĂ©MON.$"); -const u8 gWhiteFluteItemDescription[] = _("A glass flute that\nlures wild POKĂ©MON.$"); -const u8 gBerryJuiceItemDescription[] = _("A 100% pure juice\nthat restores HP\nby 20 points.$"); -const u8 gSacredAshItemDescription[] = _("Fully revives and\nrestores all\nfainted POKĂ©MON.$"); -//collectibles -const u8 gShoalSaltItemDescription[] = _("Salt obtained from\ndeep inside the\nSHOAL CAVE.$"); -const u8 gShoalShellItemDescription[] = _("A seashell found\ndeep inside the\nSHOAL CAVE.$"); -const u8 gRedShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); -const u8 gBlueShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); -const u8 gYellowShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); -const u8 gGreenShardItemDescription[] = _("A shard from an\nancient item. Can\nbe sold cheaply.$"); -//vitamins -const u8 gHPUpItemDescription[] = _("Raises the base HP\nof one POKĂ©MON.$"); -const u8 gProteinItemDescription[] = _("Raises the base\nATTACK stat of one\nPOKĂ©MON.$"); -const u8 gIronItemDescription[] = _("Raises the base\nDEFENSE stat of\none POKĂ©MON.$"); -const u8 gCarbosItemDescription[] = _("Raises the base\nSPEED stat of one\nPOKĂ©MON.$"); -const u8 gCalciumItemDescription[] = _("Raises the base\nSP. ATK stat of one\nPOKĂ©MON.$"); -const u8 gRareCandyItemDescription[] = _("Raises the level\nof a POKĂ©MON by\none.$"); -const u8 gPPUpItemDescription[] = _("Raises the maximum\nPP of a selected\nmove.$"); -const u8 gZincItemDescription[] = _("Raises the base\nSP. DEF stat of one\nPOKĂ©MON.$"); -const u8 gPPMaxItemDescription[] = _("Raises the PP of a\nmove to its maximum\npoints.$"); -//battle items -const u8 gGuardSpecItemDescription[] = _("Prevents stat\nreduction when\nused in battle.$"); -const u8 gDireHitItemDescription[] = _("Raises the\ncritical-hit ratio\nduring one battle.$"); -const u8 gXAttackItemDescription[] = _("Raises the stat\nATTACK during one\nbattle.$"); -const u8 gXDefendItemDescription[] = _("Raises the stat\nDEFENSE during one\nbattle.$"); -const u8 gXSpeedItemDescription[] = _("Raises the stat\nSPEED during one\nbattle.$"); -const u8 gXAccuracyItemDescription[] = _("Raises accuracy\nof attack moves\nduring one battle.$"); -const u8 gXSpecialItemDescription[] = _("Raises the stat\nSP. ATK during one\nbattle.$"); -const u8 gPokeDollItemDescription[] = _("Use to flee from\nany battle with\na wild POKĂ©MON.$"); -const u8 gFluffyTailItemDescription[] = _("Use to flee from\nany battle with\na wild POKĂ©MON.$"); -//field items -const u8 gSuperRepelItemDescription[] = _("Repels weak wild\nPOKĂ©MON for 200\nsteps.$"); -const u8 gMaxRepelItemDescription[] = _("Repels weak wild\nPOKĂ©MON for 250\nsteps.$"); -const u8 gEscapeRopeItemDescription[] = _("Use to escape\ninstantly from a\ncave or a dungeon.$"); -const u8 gRepelItemDescription[] = _("Repels weak wild\nPOKĂ©MON for 100\nsteps.$"); -//evolution stones -const u8 gSunStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); -const u8 gMoonStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); -const u8 gFireStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); -const u8 gThunderStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); -const u8 gWaterStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); -const u8 gLeafStoneItemDescription[] = _("Makes certain\nspecies of POKĂ©MON\nevolve.$"); -//valuable items -const u8 gTinyMushroomItemDescription[] = _("A plain mushroom\nthat would sell\nat a cheap price.$"); -const u8 gBigMushroomItemDescription[] = _("A rare mushroom\nthat would sell at a\nhigh price.$"); -const u8 gPearlItemDescription[] = _("A pretty pearl\nthat would sell at a\ncheap price.$"); -const u8 gBigPearlItemDescription[] = _("A lovely large pearl\nthat would sell at a\nhigh price.$"); -const u8 gStardustItemDescription[] = _("Beautiful red sand.\nCan be sold at a\nhigh price.$"); -const u8 gStarPieceItemDescription[] = _("A red gem shard.\nIt would sell for a\nvery high price.$"); -const u8 gNuggetItemDescription[] = _("A nugget of pure\ngold. Can be sold at\na high price.$"); -const u8 gHeartScaleItemDescription[] = _("A lovely scale.\nIt is coveted by\ncollectors.$"); -//mail -const u8 gOrangeMailItemDescription[] = _("A ZIGZAGOON-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gHarborMailItemDescription[] = _("A WINGULL-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gGlitterMailItemDescription[] = _("A PIKACHU-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gMechMailItemDescription[] = _("A MAGNEMITE-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gWoodMailItemDescription[] = _("A SLAKOTH-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gWaveMailItemDescription[] = _("A WAILMER-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gBeadMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKĂ©MON.$"); -const u8 gShadowMailItemDescription[] = _("A DUSKULL-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gTropicMailItemDescription[] = _("A BELLOSSOM-print\nMAIL to be held by\na POKĂ©MON.$"); -const u8 gDreamMailItemDescription[] = _("MAIL featuring a\nsketch of the\nholding POKĂ©MON.$"); -const u8 gFabMailItemDescription[] = _("A gorgeous-print\nMAIL to be held\nby a POKĂ©MON.$"); -const u8 gRetroMailItemDescription[] = _("MAIL featuring the\ndrawings of three\nPOKĂ©MON.$"); -//berries -const u8 gCheriBerryItemDescription[] = _("A hold item that\nheals paralysis\nin battle.$"); -const u8 gChestoBerryItemDescription[] = _("A hold item that\nawakens POKĂ©MON\nin battle.$"); -const u8 gPechaBerryItemDescription[] = _("A hold item that\nheals poisoning\nin battle.$"); -const u8 gRawstBerryItemDescription[] = _("A hold item that\nheals a burn in\nbattle.$"); -const u8 gAspearBerryItemDescription[] = _("A hold item that\ndefrosts POKĂ©MON\nin battle.$"); -const u8 gLeppaBerryItemDescription[] = _("A hold item that\nrestores 10 PP in\nbattle.$"); -const u8 gOranBerryItemDescription[] = _("A hold item that\nrestores 10 HP in\nbattle.$"); -const u8 gPersimBerryItemDescription[] = _("A hold item that\nheals confusion\nin battle.$"); -const u8 gLumBerryItemDescription[] = _("A hold item that\nheals any status\nproblem in battle.$"); -const u8 gSitrusBerryItemDescription[] = _("A hold item that\nrestores 30 HP in\nbattle.$"); -const u8 gFigyBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); -const u8 gWikiBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); -const u8 gMagoBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); -const u8 gAguavBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); -const u8 gIapapaBerryItemDescription[] = _("A hold item that\nrestores HP but\nmay confuse.$"); -const u8 gRazzBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow RAZZ.$"); -const u8 gBlukBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow BLUK.$"); -const u8 gNanabBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow NANAB.$"); -const u8 gWepearBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow WEPEAR.$"); -const u8 gPinapBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow PINAP.$"); -const u8 gPomegBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase HP.$"); -const u8 gKelpsyBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase ATTACK.$"); -const u8 gQualotBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase DEFENSE.$"); -const u8 gHondewBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase SP. ATK.$"); -const u8 gGrepaBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase SP. DEF.$"); -const u8 gTamatoBerryItemDescription[] = _("Makes a POKĂ©MON\nfriendly but lowers\nbase SPEED.$"); -const u8 gCornnBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow CORNN.$"); -const u8 gMagostBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow MAGOST.$"); -const u8 gRabutaBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow RABUTA.$"); -const u8 gNomelBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow NOMEL.$"); -const u8 gSpelonBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow SPELON.$"); -const u8 gPamtreBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow PAMTRE.$"); -const u8 gWatmelBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow WATMEL.$"); -const u8 gDurinBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow DURIN.$"); -const u8 gBelueBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow BELUE.$"); -const u8 gLiechiBerryItemDescription[] = _("A hold item that\nraises ATTACK in\na pinch.$"); -const u8 gGanlonBerryItemDescription[] = _("A hold item that\nraises DEFENSE in\na pinch.$"); -const u8 gSalacBerryItemDescription[] = _("A hold item that\nraises SPEED in\na pinch.$"); -const u8 gPetayaBerryItemDescription[] = _("A hold item that\nraises SP. ATK in\na pinch.$"); -const u8 gApicotBerryItemDescription[] = _("A hold item that\nraises SP. DEF in\na pinch.$"); -const u8 gLansatBerryItemDescription[] = _("A hold item that\nups the critical-\nhit rate in a pinch.$"); -const u8 gStarfBerryItemDescription[] = _("A hold item that\nsharply boosts a\nstat in a pinch.$"); -const u8 gEnigmaBerryItemDescription[] = _("{POKEBLOCK} ingredient.\nPlant in loamy soil\nto grow a mystery.$"); -//hold items -const u8 gBrightPowderItemDescription[] = _("A hold item that\ncasts a glare to\nreduce accuracy.$"); -const u8 gWhiteHerbItemDescription[] = _("A hold item that\nrestores any\nlowered stat.$"); -const u8 gMachoBraceItemDescription[] = _("A hold item that\npromotes growth,\nbut reduces SPEED.$"); -const u8 gExpShareItemDescription[] = _("A hold item that\ngets EXP. points\nfrom battles.$"); -const u8 gQuickClawItemDescription[] = _("A hold item that\noccasionally allows\nthe first strike.$"); -const u8 gSootheBellItemDescription[] = _("A hold item that\ncalms spirits and\nfosters friendship.$"); -const u8 gMentalHerbItemDescription[] = _("A hold item that\nsnaps POKĂ©MON out\nof infatuation.$"); -const u8 gChoiceBandItemDescription[] = _("Raises a move’s\npower, but permits\nonly that move.$"); -const u8 gKingsRockItemDescription[] = _("A hold item that\nmay cause flinching\nwhen the foe is hit.$"); -const u8 gSilverPowderItemDescription[] = _("A hold item that\nraises the power of\nBUG-type moves.$"); -const u8 gAmuletCoinItemDescription[] = _("Doubles money in\nbattle if the\nholder takes part.$"); -const u8 gCleanseTagItemDescription[] = _("A hold item that\nhelps repel wild\nPOKĂ©MON.$"); -const u8 gSoulDewItemDescription[] = _("Hold item: raises\nSP. ATK & SP. DEF of\nLATIOS & LATIAS.$"); -const u8 gDeepSeaToothItemDescription[] = _("A hold item that\nraises the SP. ATK\nof CLAMPERL.$"); -const u8 gDeepSeaScaleItemDescription[] = _("A hold item that\nraises the SP. DEF\nof CLAMPERL.$"); -const u8 gSmokeBallItemDescription[] = _("A hold item that\nassures fleeing\nfrom wild POKĂ©MON.$"); -const u8 gEverstoneItemDescription[] = _("A wondrous hold\nitem that prevents\nevolution.$"); -const u8 gFocusBandItemDescription[] = _("A hold item that\noccasionally\nprevents fainting.$"); -const u8 gLuckyEggItemDescription[] = _("A hold item that\nboosts EXP. points\nearned in battle.$"); -const u8 gScopeLensItemDescription[] = _("A hold item that\nimproves the\ncritical-hit rate.$"); -const u8 gMetalCoatItemDescription[] = _("A hold item that\nraises the power of\nSTEEL-type moves.$"); -const u8 gLeftoversItemDescription[] = _("A hold item that\ngradually restores\nHP in battle.$"); -const u8 gDragonScaleItemDescription[] = _("A strange scale\nheld by DRAGON-\ntype POKĂ©MON.$"); -const u8 gLightBallItemDescription[] = _("A hold item that\nraises the SP. ATK\nof PIKACHU.$"); -const u8 gSoftSandItemDescription[] = _("A hold item that\nraises the power of\nGROUND-type moves.$"); -const u8 gHardStoneItemDescription[] = _("A hold item that\nraises the power of\nROCK-type moves.$"); -const u8 gMiracleSeedItemDescription[] = _("A hold item that\nraises the power of\nGRASS-type moves.$"); -const u8 gBlackGlassesItemDescription[] = _("A hold item that\nraises the power of\nDARK-type moves.$"); -const u8 gBlackBeltItemDescription[] = _("A hold item that\nboosts FIGHTING-\ntype moves.$"); -const u8 gMagnetItemDescription[] = _("A hold item that\nboosts ELECTRIC-\ntype moves.$"); -const u8 gMysticWaterItemDescription[] = _("A hold item that\nraises the power of\nWATER-type moves.$"); -const u8 gSharpBeakItemDescription[] = _("A hold item that\nraises the power of\nFLYING-type moves.$"); -const u8 gPoisonBarbItemDescription[] = _("A hold item that\nraises the power of\nPOISON-type moves.$"); -const u8 gNeverMeltIceItemDescription[] = _("A hold item that\nraises the power of\nICE-type moves.$"); -const u8 gSpellTagItemDescription[] = _("A hold item that\nraises the power of\nGHOST-type moves.$"); -const u8 gTwistedSpoonItemDescription[] = _("A hold item that\nboosts PSYCHIC-\ntype moves.$"); -const u8 gCharcoalItemDescription[] = _("A hold item that\nraises the power of\nFIRE-type moves.$"); -const u8 gDragonFangItemDescription[] = _("A hold item that\nraises the power of\nDRAGON-type moves.$"); -const u8 gSilkScarfItemDescription[] = _("A hold item that\nraises the power of\nNORMAL-type moves.$"); -const u8 gUpGradeItemDescription[] = _("A peculiar box made\nby SILPH CO.$"); -const u8 gShellBellItemDescription[] = _("A hold item that\nrestores HP upon\nstriking the foe.$"); -const u8 gSeaIncenseItemDescription[] = _("A hold item that\nslightly boosts\nWATER-type moves.$"); -const u8 gLaxIncenseItemDescription[] = _("A hold item that\nslightly lowers the\nfoe’s accuracy.$"); -const u8 gLuckyPunchItemDescription[] = _("A hold item that\nraises CHANSEY’s\ncritical-hit rate.$"); -const u8 gMetalPowderItemDescription[] = _("A hold item that\nraises DITTO’s\nDEFENSE.$"); -const u8 gThickClubItemDescription[] = _("A hold item that \nraises CUBONE or\nMAROWAK’s ATTACK.$"); -const u8 gStickItemDescription[] = _("A hold item that\nraises FARFETCH’D’s\ncritical-hit ratio.$"); -const u8 gRedScarfItemDescription[] = _("A hold item that\nraises COOL in\nCONTESTS.$"); -const u8 gBlueScarfItemDescription[] = _("A hold item that\nraises BEAUTY in\nCONTESTS.$"); -const u8 gPinkScarfItemDescription[] = _("A hold item that\nraises CUTE in\nCONTESTS.$"); -const u8 gGreenScarfItemDescription[] = _("A hold item that\nraises SMART in\nCONTESTS.$"); -const u8 gYellowScarfItemDescription[] = _("A hold item that\nraises TOUGH in\nCONTESTS.$"); -//key items -const u8 gMachBikeItemDescription[] = _("A folding bicycle\nthat doubles your\nspeed or better.$"); -const u8 gCoinCaseItemDescription[] = _("A case that holds\nup to 9,999 COINS.$"); -const u8 gItemfinderItemDescription[] = _("A device that\nsignals an invisible\nitem by sound.$"); -const u8 gOldRodItemDescription[] = _("Use by any body of\nwater to fish for\nwild POKĂ©MON.$"); -const u8 gGoodRodItemDescription[] = _("A decent fishing\nrod for catching\nwild POKĂ©MON.$"); -const u8 gSuperRodItemDescription[] = _("The best fishing\nrod for catching\nwild POKĂ©MON.$"); -const u8 gSSTicketItemDescription[] = _("The ticket required\nfor sailing on a\nferry.$"); -const u8 gContestPassItemDescription[] = _("The pass required\nfor entering\nPOKĂ©MON CONTESTS.$"); -const u8 gWailmerPailItemDescription[] = _("A tool used for\nwatering BERRIES\nand plants.$"); -const u8 gDevonGoodsItemDescription[] = _("A package that\ncontains DEVON’s\nmachine parts.$"); -const u8 gSootSackItemDescription[] = _("A sack used to\ngather and hold\nvolcanic ash.$"); -const u8 gBasementKeyItemDescription[] = _("The key for NEW\nMAUVILLE beneath\nMAUVILLE CITY.$"); -const u8 gAcroBikeItemDescription[] = _("A folding bicycle\ncapable of jumps\nand wheelies.$"); -const u8 gPokeblockCaseItemDescription[] = _("A case for holding\n{POKEBLOCK}S made with\na BERRY BLENDER.$"); -const u8 gLetterItemDescription[] = _("A letter to STEVEN\nfrom the PRESIDENT\nof the DEVON CORP.$"); -const u8 gEonTicketItemDescription[] = _("The ticket for a\nferry to a distant\nsouthern island.$"); -const u8 gRedOrbItemDescription[] = _("A red, glowing orb\nsaid to contain an\nancient power.$"); -const u8 gBlueOrbItemDescription[] = _("A blue, glowing orb\nsaid to contain an\nancient power.$"); -const u8 gScannerItemDescription[] = _("A device found\ninside the\nABANDONED SHIP.$"); -const u8 gGoGogglesItemDescription[] = _("Nifty goggles that\nprotect eyes from\ndesert sandstorms.$"); -const u8 gMeteoriteItemDescription[] = _("A meteorite found\nat METEOR FALLS.$"); -const u8 gRoom1KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); -const u8 gRoom2KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); -const u8 gRoom4KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); -const u8 gRoom6KeyItemDescription[] = _("A key that opens a\ndoor inside the\nABANDONED SHIP.$"); -const u8 gStorageKeyItemDescription[] = _("The key to the\nstorage inside the\nABANDONED SHIP.$"); -const u8 gRootFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKĂ©MON.$"); -const u8 gClawFossilItemDescription[] = _("A fossil of an\nancient, seafloor-\ndwelling POKĂ©MON.$"); -const u8 gDevonScopeItemDescription[] = _("A device by DEVON\nthat signals any\nunseeable POKĂ©MON.$"); -//TMs/HMs -const u8 gTM01ItemDescription[] = _("Powerful, but makes\nthe user flinch if\nhit by the foe.$"); -const u8 gTM02ItemDescription[] = _("Hooks and slashes\nthe foe with long,\nsharp claws.$"); -const u8 gTM03ItemDescription[] = _("Generates an\nultrasonic wave\nthat may confuse.$"); -const u8 gTM04ItemDescription[] = _("Raises SP. ATK and\nSP. DEF by focusing\nthe mind.$"); -const u8 gTM05ItemDescription[] = _("A savage roar that\nmakes the foe flee \nto end the battle.$"); -const u8 gTM06ItemDescription[] = _("Poisons the foe\nwith a toxin that\ngradually worsens.$"); -const u8 gTM07ItemDescription[] = _("Creates a hailstorm\nthat damages all\ntypes except ICE.$"); -const u8 gTM08ItemDescription[] = _("Bulks up the body\nto boost both\nATTACK & DEFENSE.$"); -const u8 gTM09ItemDescription[] = _("Shoots 2 to 5 seeds\nin a row to strike\nthe foe.$"); -const u8 gTM10ItemDescription[] = _("The attack power\nvaries among\ndifferent POKĂ©MON.$"); -const u8 gTM11ItemDescription[] = _("Raises the power of\nFIRE-type moves\nfor 5 turns.$"); -const u8 gTM12ItemDescription[] = _("Enrages the foe so\nit can only use\nattack moves.$"); -const u8 gTM13ItemDescription[] = _("Fires an icy cold\nbeam that may\nfreeze the foe.$"); -const u8 gTM14ItemDescription[] = _("A brutal snow-and-\nwind attack that\nmay freeze the foe.$"); -const u8 gTM15ItemDescription[] = _("Powerful, but needs\nrecharging the\nnext turn.$"); -const u8 gTM16ItemDescription[] = _("Creates a wall of\nlight that lowers\nSP. ATK damage.$"); -const u8 gTM17ItemDescription[] = _("Negates all damage,\nbut may fail if used\nin succession.$"); -const u8 gTM18ItemDescription[] = _("Raises the power of\nWATER-type moves\nfor 5 turns.$"); -const u8 gTM19ItemDescription[] = _("Recovers half the\nHP of the damage \nthis move inflicts.$"); -const u8 gTM20ItemDescription[] = _("Prevents status\nabnormality with a\nmystical power.$"); -const u8 gTM21ItemDescription[] = _("The less the user\nlikes you, the more\npowerful this move.$"); -const u8 gTM22ItemDescription[] = _("Absorbs sunlight in\nthe 1st turn, then\nattacks next turn.$"); -const u8 gTM23ItemDescription[] = _("Slams the foe with\na hard tail. It may\nlower DEFENSE.$"); -const u8 gTM24ItemDescription[] = _("A powerful electric\nattack that may\ncause paralysis.$"); -const u8 gTM25ItemDescription[] = _("Strikes the foe\nwith a thunderbolt.\nIt may paralyze.$"); -const u8 gTM26ItemDescription[] = _("Causes a quake\nthat has no effect\non flying foes.$"); -const u8 gTM27ItemDescription[] = _("The more the user\nlikes you, the more\npowerful this move.$"); -const u8 gTM28ItemDescription[] = _("Digs underground\nthe 1st turn, then\nstrikes next turn.$"); -const u8 gTM29ItemDescription[] = _("A powerful psychic\nattack that may\nlower SP. DEF.$"); -const u8 gTM30ItemDescription[] = _("Hurls a dark lump\nat the foe. It may\nlower SP. DEF.$"); -const u8 gTM31ItemDescription[] = _("Destroys barriers\nlike LIGHT SCREEN\nand causes damage.$"); -const u8 gTM32ItemDescription[] = _("Creates illusory\ncopies to enhance\nelusiveness.$"); -const u8 gTM33ItemDescription[] = _("Creates a wall of\nlight that weakens\nphysical attacks.$"); -const u8 gTM34ItemDescription[] = _("Zaps the foe with a\njolt of electricity\nthat never misses.$"); -const u8 gTM35ItemDescription[] = _("Looses a stream of\nfire that may burn\nthe foe.$"); -const u8 gTM36ItemDescription[] = _("Hurls sludge at the\nfoe. It may poison\nthe foe.$"); -const u8 gTM37ItemDescription[] = _("Causes a sandstorm\nthat hits the foe\nover several turns.$"); -const u8 gTM38ItemDescription[] = _("A powerful fire\nattack that may\nburn the foe.$"); -const u8 gTM39ItemDescription[] = _("Stops the foe from\nmoving with rocks.\nMay lower SPEED.$"); -const u8 gTM40ItemDescription[] = _("An extremely fast\nattack that can’t\nbe avoided.$"); -const u8 gTM41ItemDescription[] = _("Prevents the foe\nfrom using the same\nmove in a row.$"); -const u8 gTM42ItemDescription[] = _("Raises ATTACK when\npoisoned, burned,\nor paralyzed.$"); -const u8 gTM43ItemDescription[] = _("Adds an effect to\nattack depending\non the location.$"); -const u8 gTM44ItemDescription[] = _("The user sleeps for\n2 turns to restore\nhealth and status.$"); -const u8 gTM45ItemDescription[] = _("Makes it tough to\nattack a foe of the\nopposite gender.$"); -const u8 gTM46ItemDescription[] = _("While attacking,\nit may steal the\nfoe’s held item.$"); -const u8 gTM47ItemDescription[] = _("Spreads hard-\nedged wings and\nslams into the foe.$"); -const u8 gTM48ItemDescription[] = _("Switches abilities\nwith the foe on the\nturn this is used.$"); -const u8 gTM49ItemDescription[] = _("Steals the effects\nof the move the foe\nis trying to use.$"); -const u8 gTM50ItemDescription[] = _("Enables full-power\nattack, but sharply\nlowers SP. ATK.$"); - -const u8 gHM01ItemDescription[] = _("Attacks the foe\nwith sharp blades\nor claws.$"); -const u8 gHM02ItemDescription[] = _("Flies up on the\nfirst turn, then\nattacks next turn.$"); -const u8 gHM03ItemDescription[] = _("Creates a huge\nwave, then crashes\nit down on the foe.$"); -const u8 gHM04ItemDescription[] = _("Builds enormous\npower, then slams\nthe foe.$"); -const u8 gHM05ItemDescription[] = _("Looses a powerful\nblast of light that\nreduces accuracy.$"); -const u8 gHM06ItemDescription[] = _("A rock-crushingly\ntough attack that\nmay lower DEFENSE.$"); -const u8 gHM07ItemDescription[] = _("Attacks the foe\nwith enough power\nto climb waterfalls.$"); -const u8 gHM08ItemDescription[] = _("Dives underwater\nthe 1st turn, then\nattacks next turn.$"); -//FireRed/LeafGreen specific key items -const u8 gOaksParcelItemDescription[] = _("A parcel for PROF.\nOAK from a POKĂ©MON\nMART’s clerk.$"); -const u8 gPokeFluteItemDescription[] = _("A sweet-sounding\nflute that awakens\nPOKĂ©MON.$"); -const u8 gSecretKeyItemDescription[] = _("The key to the\nCINNABAR ISLAND\nGYM’s entrance.$"); -const u8 gBikeVoucherItemDescription[] = _("A voucher for\nobtaining a bicycle\nfrom the BIKE SHOP.$"); -const u8 gGoldTeethItemDescription[] = _("Gold dentures lost\nby the SAFARI\nZONE’s WARDEN.$"); -const u8 gOldAmberItemDescription[] = _("A stone containing\nthe genes of an\nancient POKĂ©MON.$"); -const u8 gCardKeyItemDescription[] = _("A card-type door\nkey used in SILPH\nCO’s office.$"); -const u8 gLiftKeyItemDescription[] = _("An elevator key\nused in TEAM\nROCKET’s HIDEOUT.$"); -const u8 gHelixFossilItemDescription[] = _("A piece of an\nancient marine\nPOKĂ©MON’s seashell.$"); -const u8 gDomeFossilItemDescription[] = _("A piece of an\nancient marine\nPOKĂ©MON’s shell.$"); -const u8 gSilphScopeItemDescription[] = _("SILPH CO’s scope\nmakes unseeable\nPOKĂ©MON visible.$"); -const u8 gBicycleItemDescription[] = _("A folding bicycle\nthat is faster than\nthe RUNNING SHOES.$"); -const u8 gTownMapItemDescription[] = _("Can be viewed\nanytime. Shows your\npresent location.$"); -const u8 gVSSeekerItemDescription[] = _("A rechargeable unit\nthat flags battle-\nready TRAINERS.$"); -const u8 gFameCheckerItemDescription[] = _("Stores information\non famous people\nfor instant recall.$"); -const u8 gTMCaseItemDescription[] = _("A convenient case \nthat holds TMs and\nHMs.$"); -const u8 gBerryPouchItemDescription[] = _("A convenient\ncontainer that\nholds BERRIES.$"); -const u8 gTeachyTVItemDescription[] = _("A TV set tuned to\nan advice program\nfor TRAINERS.$"); -const u8 gTriPassItemDescription[] = _("A pass for ferries\nbetween ONE, TWO,\nand THREE ISLAND.$"); -const u8 gRainbowPassItemDescription[] = _("For ferries serving\nVERMILION and the\nSEVII ISLANDS.$"); -const u8 gTeaItemDescription[] = _("A thirst-quenching\ntea prepared by an\nold lady.$"); -const u8 gMysticTicketItemDescription[] = _("A ticket required\nto board the ship\nto NAVEL ROCK.$"); -const u8 gAuroraTicketItemDescription[] = _("A ticket required\nto board the ship\nto BIRTH ISLAND.$"); -const u8 gPowderJarItemDescription[] = _("Stores BERRY\nPOWDER made using\na BERRY CRUSHER.$"); -const u8 gRubyItemDescription[] = _("An exquisite, red-\nglowing gem that\nsymbolizes passion.$"); -const u8 gSapphireItemDescription[] = _("A brilliant blue gem\nthat symbolizes\nhonesty.$"); -//Emerald specific key items -const u8 gMagmaEmblemItemDescription[] = _("A medal-like item in\nthe same shape as\nTEAM MAGMA’s mark.$"); -const u8 gOldSeaMapItemDescription[] = _("A faded sea chart\nthat shows the way\nto a certain island.$"); - -const struct Item gItems[] = { - - [ITEM_NONE] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - //Pokeballs - - [ITEM_MASTER_BALL] = { - .name = _("MASTER BALL$"), - .itemId = ITEM_MASTER_BALL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMasterBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 0, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 0, - }, - - [ITEM_ULTRA_BALL] = { - .name = _("ULTRA BALL$"), - .itemId = ITEM_ULTRA_BALL, - .price = 1200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gUltraBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 1, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 1, - }, - - [ITEM_GREAT_BALL] = { - .name = _("GREAT BALL$"), - .itemId = ITEM_GREAT_BALL, - .price = 600, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGreatBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 2, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 2, - }, - - [ITEM_POKE_BALL] = { - .name = _("POKĂ© BALL$"), - .itemId = ITEM_POKE_BALL, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPokeBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 3, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 3, - }, - - [ITEM_SAFARI_BALL] = { - .name = _("SAFARI BALL$"), - .itemId = ITEM_SAFARI_BALL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSafariBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 4, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 4, - }, - - [ITEM_NET_BALL] = { - .name = _("NET BALL$"), - .itemId = ITEM_NET_BALL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gNetBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 5, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 5, - }, - - [ITEM_DIVE_BALL] = { - .name = _("DIVE BALL$"), - .itemId = ITEM_DIVE_BALL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDiveBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 6, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 6, - }, - - [ITEM_NEST_BALL] = { - .name = _("NEST BALL$"), - .itemId = ITEM_NEST_BALL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gNestBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 7, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 7, - }, - - [ITEM_REPEAT_BALL] = { - .name = _("REPEAT BALL$"), - .itemId = ITEM_REPEAT_BALL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRepeatBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 8, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 8, - }, - - [ITEM_TIMER_BALL] = { - .name = _("TIMER BALL$"), - .itemId = ITEM_TIMER_BALL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTimerBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 9, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 9, - }, - - [ITEM_LUXURY_BALL] = { - .name = _("LUXURY BALL$"), - .itemId = ITEM_LUXURY_BALL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gLuxuryBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 10, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 10, - }, - - [ITEM_PREMIER_BALL] = { - .name = _("PREMIER BALL$"), - .itemId = ITEM_PREMIER_BALL, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPremierBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_POKE_BALLS, - .type = 11, - .fieldUseFunc = NULL, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_PokeBall, - .secondaryId = 11, - }, - - //Medicine - - [ITEM_POTION] = { - .name = _("POTION$"), - .itemId = ITEM_POTION, - .price = 300, - .holdEffect = 0, - .holdEffectParam = 20, - .description = gPotionItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_ANTIDOTE] = { - .name = _("ANTIDOTE$"), - .itemId = ITEM_ANTIDOTE, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gAntidoteItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_BURN_HEAL] = { - .name = _("BURN HEAL$"), - .itemId = ITEM_BURN_HEAL, - .price = 250, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBurnHealItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_ICE_HEAL] = { - .name = _("ICE HEAL$"), - .itemId = ITEM_ICE_HEAL, - .price = 250, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gIceHealItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_AWAKENING] = { - .name = _("AWAKENING$"), - .itemId = ITEM_AWAKENING, - .price = 250, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gAwakeningItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_PARALYZE_HEAL] = { - .name = _("PARLYZ HEAL$"), - .itemId = ITEM_PARALYZE_HEAL, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gParalyzeHealItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_FULL_RESTORE] = { - .name = _("FULL RESTORE$"), - .itemId = ITEM_FULL_RESTORE, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 255, - .description = gFullRestoreItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_MAX_POTION] = { - .name = _("MAX POTION$"), - .itemId = ITEM_MAX_POTION, - .price = 2500, - .holdEffect = 0, - .holdEffectParam = 255, - .description = gMaxPotionItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_HYPER_POTION] = { - .name = _("HYPER POTION$"), - .itemId = ITEM_HYPER_POTION, - .price = 1200, - .holdEffect = 0, - .holdEffectParam = 200, - .description = gHyperPotionItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_SUPER_POTION] = { - .name = _("SUPER POTION$"), - .itemId = ITEM_SUPER_POTION, - .price = 700, - .holdEffect = 0, - .holdEffectParam = 50, - .description = gSuperPotionItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_FULL_HEAL] = { - .name = _("FULL HEAL$"), - .itemId = ITEM_FULL_HEAL, - .price = 600, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gFullHealItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_REVIVE] = { - .name = _("REVIVE$"), - .itemId = ITEM_REVIVE, - .price = 1500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gReviveItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - [ITEM_MAX_REVIVE] = { - .name = _("MAX REVIVE$"), - .itemId = ITEM_MAX_REVIVE, - .price = 4000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMaxReviveItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - [ITEM_FRESH_WATER] = { - .name = _("FRESH WATER$"), - .itemId = ITEM_FRESH_WATER, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 50, - .description = gFreshWaterItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_SODA_POP] = { - .name = _("SODA POP$"), - .itemId = ITEM_SODA_POP, - .price = 300, - .holdEffect = 0, - .holdEffectParam = 60, - .description = gSodaPopItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_LEMONADE] = { - .name = _("LEMONADE$"), - .itemId = ITEM_LEMONADE, - .price = 350, - .holdEffect = 0, - .holdEffectParam = 80, - .description = gLemonadeItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_MOOMOO_MILK] = { - .name = _("MOOMOO MILK$"), - .itemId = ITEM_MOOMOO_MILK, - .price = 500, - .holdEffect = 0, - .holdEffectParam = 100, - .description = gMoomooMilkItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_ENERGY_POWDER] = { - .name = _("ENERGYPOWDER$"), - .itemId = ITEM_ENERGY_POWDER, - .price = 500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gEnergyPowderItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_ENERGY_ROOT] = { - .name = _("ENERGY ROOT$"), - .itemId = ITEM_ENERGY_ROOT, - .price = 800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gEnergyRootItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_HEAL_POWDER] = { - .name = _("HEAL POWDER$"), - .itemId = ITEM_HEAL_POWDER, - .price = 450, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHealPowderItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_REVIVAL_HERB] = { - .name = _("REVIVAL HERB$"), - .itemId = ITEM_REVIVAL_HERB, - .price = 2800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRevivalHerbItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_ETHER] = { - .name = _("ETHER$"), - .itemId = ITEM_ETHER, - .price = 1200, - .holdEffect = 0, - .holdEffectParam = 10, - .description = gEtherItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_PPRecovery, - .secondaryId = 0, - }, - - [ITEM_MAX_ETHER] = { - .name = _("MAX ETHER$"), - .itemId = ITEM_MAX_ETHER, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 255, - .description = gMaxEtherItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_PPRecovery, - .secondaryId = 0, - }, - - [ITEM_ELIXIR] = { - .name = _("ELIXIR$"), - .itemId = ITEM_ELIXIR, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 10, - .description = gElixirItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_PPRecovery, - .secondaryId = 0, - }, - - [ITEM_MAX_ELIXIR] = { - .name = _("MAX ELIXIR$"), - .itemId = ITEM_MAX_ELIXIR, - .price = 4500, - .holdEffect = 0, - .holdEffectParam = 255, - .description = gMaxElixirItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_PPRecovery, - .secondaryId = 0, - }, - - [ITEM_LAVA_COOKIE] = { - .name = _("LAVA COOKIE$"), - .itemId = ITEM_LAVA_COOKIE, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gLavaCookieItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_BLUE_FLUTE] = { - .name = _("BLUE FLUTE$"), - .itemId = ITEM_BLUE_FLUTE, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBlueFluteItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_YELLOW_FLUTE] = { - .name = _("YELLOW FLUTE$"), - .itemId = ITEM_YELLOW_FLUTE, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gYellowFluteItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_RED_FLUTE] = { - .name = _("RED FLUTE$"), - .itemId = ITEM_RED_FLUTE, - .price = 300, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRedFluteItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - //Not medicine - - [ITEM_BLACK_FLUTE] = { - .name = _("BLACK FLUTE$"), - .itemId = ITEM_BLACK_FLUTE, - .price = 400, - .holdEffect = 0, - .holdEffectParam = 50, - .description = gBlackFluteItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_BlackWhiteFlute, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WHITE_FLUTE] = { - .name = _("WHITE FLUTE$"), - .itemId = ITEM_WHITE_FLUTE, - .price = 500, - .holdEffect = 0, - .holdEffectParam = 150, - .description = gWhiteFluteItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_BlackWhiteFlute, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - //Medicine again - - [ITEM_BERRY_JUICE] = { - .name = _("BERRY JUICE$"), - .itemId = ITEM_BERRY_JUICE, - .price = 100, - .holdEffect = 1, - .holdEffectParam = 20, - .description = gBerryJuiceItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_SACRED_ASH] = { - .name = _("SACRED ASH$"), - .itemId = ITEM_SACRED_ASH, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSacredAshItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_SacredAsh, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - //Collectibles - - [ITEM_SHOAL_SALT] = { - .name = _("SHOAL SALT$"), - .itemId = ITEM_SHOAL_SALT, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gShoalSaltItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SHOAL_SHELL] = { - .name = _("SHOAL SHELL$"), - .itemId = ITEM_SHOAL_SHELL, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gShoalShellItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_RED_SHARD] = { - .name = _("RED SHARD$"), - .itemId = ITEM_RED_SHARD, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRedShardItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BLUE_SHARD] = { - .name = _("BLUE SHARD$"), - .itemId = ITEM_BLUE_SHARD, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBlueShardItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_YELLOW_SHARD] = { - .name = _("YELLOW SHARD$"), - .itemId = ITEM_YELLOW_SHARD, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gYellowShardItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GREEN_SHARD] = { - .name = _("GREEN SHARD$"), - .itemId = ITEM_GREEN_SHARD, - .price = 200, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGreenShardItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - //Empty Items - - [ITEM_034] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_035] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_036] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_037] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - [ITEM_038] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - [ITEM_039] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - [ITEM_03A] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_03B] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_03C] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_03D] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_03E] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - //Vitamins - - [ITEM_HP_UP] = { - .name = _("HP UP$"), - .itemId = ITEM_HP_UP, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHPUpItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PROTEIN] = { - .name = _("PROTEIN$"), - .itemId = ITEM_PROTEIN, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gProteinItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_IRON] = { - .name = _("IRON$"), - .itemId = ITEM_IRON, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gIronItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CARBOS] = { - .name = _("CARBOS$"), - .itemId = ITEM_CARBOS, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gCarbosItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CALCIUM] = { - .name = _("CALCIUM$"), - .itemId = ITEM_CALCIUM, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gCalciumItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_RARE_CANDY] = { - .name = _("RARE CANDY$"), - .itemId = ITEM_RARE_CANDY, - .price = 4800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRareCandyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_RareCandy, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PP_UP] = { - .name = _("PP UP$"), - .itemId = ITEM_PP_UP, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPPUpItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPUp, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ZINC] = { - .name = _("ZINC$"), - .itemId = ITEM_ZINC, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gZincItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PP_MAX] = { - .name = _("PP MAX$"), - .itemId = ITEM_PP_MAX, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPPMaxItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPUp, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_048] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - //battle items - - [ITEM_GUARD_SPEC] = { - .name = _("GUARD SPEC.$"), - .itemId = ITEM_GUARD_SPEC, - .price = 700, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGuardSpecItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_DIRE_HIT] = { - .name = _("DIRE HIT$"), - .itemId = ITEM_DIRE_HIT, - .price = 650, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDireHitItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_X_ATTACK] = { - .name = _("X ATTACK$"), - .itemId = ITEM_X_ATTACK, - .price = 500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gXAttackItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_X_DEFEND] = { - .name = _("X DEFEND$"), - .itemId = ITEM_X_DEFEND, - .price = 550, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gXDefendItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_X_SPEED] = { - .name = _("X SPEED$"), - .itemId = ITEM_X_SPEED, - .price = 350, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gXSpeedItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_X_ACCURACY] = { - .name = _("X ACCURACY$"), - .itemId = ITEM_X_ACCURACY, - .price = 950, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gXAccuracyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_X_SPECIAL] = { - .name = _("X SPECIAL$"), - .itemId = ITEM_X_SPECIAL, - .price = 350, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gXSpecialItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_StatIncrease, - .secondaryId = 0, - }, - - [ITEM_POKE_DOLL] = { - .name = _("POKĂ© DOLL$"), - .itemId = ITEM_POKE_DOLL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPokeDollItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Escape, - .secondaryId = 0, - }, - - [ITEM_FLUFFY_TAIL] = { - .name = _("FLUFFY TAIL$"), - .itemId = ITEM_FLUFFY_TAIL, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gFluffyTailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 2, - .battleUseFunc = ItemUseInBattle_Escape, - .secondaryId = 0, - }, - - [ITEM_052] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//field items - - [ITEM_SUPER_REPEL] = { - .name = _("SUPER REPEL$"), - .itemId = ITEM_SUPER_REPEL, - .price = 500, - .holdEffect = 0, - .holdEffectParam = 200, - .description = gSuperRepelItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_Repel, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MAX_REPEL] = { - .name = _("MAX REPEL$"), - .itemId = ITEM_MAX_REPEL, - .price = 700, - .holdEffect = 0, - .holdEffectParam = 250, - .description = gMaxRepelItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_Repel, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ESCAPE_ROPE] = { - .name = _("ESCAPE ROPE$"), - .itemId = ITEM_ESCAPE_ROPE, - .price = 550, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gEscapeRopeItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_EscapeRope, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_REPEL] = { - .name = _("REPEL$"), - .itemId = ITEM_REPEL, - .price = 350, - .holdEffect = 0, - .holdEffectParam = 100, - .description = gRepelItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_Repel, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Empty items #2 - - [ITEM_057] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_058] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_059] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_05A] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_05B] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_05C] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Evolution Stones - - [ITEM_SUN_STONE] = { - .name = _("SUN STONE$"), - .itemId = ITEM_SUN_STONE, - .price = 2100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSunStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MOON_STONE] = { - .name = _("MOON STONE$"), - .itemId = ITEM_MOON_STONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMoonStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_FIRE_STONE] = { - .name = _("FIRE STONE$"), - .itemId = ITEM_FIRE_STONE, - .price = 2100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gFireStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_THUNDER_STONE] = { - .name = _("THUNDERSTONE$"), - .itemId = ITEM_THUNDER_STONE, - .price = 2100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gThunderStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WATER_STONE] = { - .name = _("WATER STONE$"), - .itemId = ITEM_WATER_STONE, - .price = 2100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gWaterStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LEAF_STONE] = { - .name = _("LEAF STONE$"), - .itemId = ITEM_LEAF_STONE, - .price = 2100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gLeafStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_EvolutionStone, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Empty items #3 - - [ITEM_063] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_064] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_065] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_066] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Valuable items - [ITEM_TINY_MUSHROOM] = { - .name = _("TINYMUSHROOM$"), - .itemId = ITEM_TINY_MUSHROOM, - .price = 500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTinyMushroomItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BIG_MUSHROOM] = { - .name = _("BIG MUSHROOM$"), - .itemId = ITEM_BIG_MUSHROOM, - .price = 5000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBigMushroomItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_069] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PEARL] = { - .name = _("PEARL$"), - .itemId = ITEM_PEARL, - .price = 1400, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPearlItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BIG_PEARL] = { - .name = _("BIG PEARL$"), - .itemId = ITEM_BIG_PEARL, - .price = 7500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBigPearlItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_STARDUST] = { - .name = _("STARDUST$"), - .itemId = ITEM_STARDUST, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gStardustItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_STAR_PIECE] = { - .name = _("STAR PIECE$"), - .itemId = ITEM_STAR_PIECE, - .price = 9800, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gStarPieceItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_NUGGET] = { - .name = _("NUGGET$"), - .itemId = ITEM_NUGGET, - .price = 10000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gNuggetItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HEART_SCALE] = { - .name = _("HEART SCALE$"), - .itemId = ITEM_HEART_SCALE, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHeartScaleItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//empty items - - [ITEM_070] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_071] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_072] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_073] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_074] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_075] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_076] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_077] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_078] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//mail - - [ITEM_ORANGE_MAIL] = { - .name = _("ORANGE MAIL$"), - .itemId = ITEM_ORANGE_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gOrangeMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HARBOR_MAIL] = { - .name = _("HARBOR MAIL$"), - .itemId = ITEM_HARBOR_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHarborMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 1, - }, - - [ITEM_GLITTER_MAIL] = { - .name = _("GLITTER MAIL$"), - .itemId = ITEM_GLITTER_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGlitterMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 2, - }, - - [ITEM_MECH_MAIL] = { - .name = _("MECH MAIL$"), - .itemId = ITEM_MECH_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMechMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 3, - }, - - [ITEM_WOOD_MAIL] = { - .name = _("WOOD MAIL$"), - .itemId = ITEM_WOOD_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gWoodMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 4, - }, - - [ITEM_WAVE_MAIL] = { - .name = _("WAVE MAIL$"), - .itemId = ITEM_WAVE_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gWaveMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 5, - }, - - [ITEM_BEAD_MAIL] = { - .name = _("BEAD MAIL$"), - .itemId = ITEM_BEAD_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBeadMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 6, - }, - - [ITEM_SHADOW_MAIL] = { - .name = _("SHADOW MAIL$"), - .itemId = ITEM_SHADOW_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gShadowMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 7, - }, - - [ITEM_TROPIC_MAIL] = { - .name = _("TROPIC MAIL$"), - .itemId = ITEM_TROPIC_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTropicMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 8, - }, - - [ITEM_DREAM_MAIL] = { - .name = _("DREAM MAIL$"), - .itemId = ITEM_DREAM_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDreamMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 9, - }, - - [ITEM_FAB_MAIL] = { - .name = _("FAB MAIL$"), - .itemId = ITEM_FAB_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gFabMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 10, - }, - - [ITEM_RETRO_MAIL] = { - .name = _("RETRO MAIL$"), - .itemId = ITEM_RETRO_MAIL, - .price = 50, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRetroMailItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 0, - .fieldUseFunc = ItemUseOutOfBattle_Mail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 11, - }, - -//berries - - [ITEM_CHERI_BERRY] = { - .name = _("CHERI BERRY$"), - .itemId = ITEM_CHERI_BERRY, - .price = 20, - .holdEffect = 2, - .holdEffectParam = 0, - .description = gCheriBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_CHESTO_BERRY] = { - .name = _("CHESTO BERRY$"), - .itemId = ITEM_CHESTO_BERRY, - .price = 20, - .holdEffect = 3, - .holdEffectParam = 0, - .description = gChestoBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_PECHA_BERRY] = { - .name = _("PECHA BERRY$"), - .itemId = ITEM_PECHA_BERRY, - .price = 20, - .holdEffect = 4, - .holdEffectParam = 0, - .description = gPechaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_RAWST_BERRY] = { - .name = _("RAWST BERRY$"), - .itemId = ITEM_RAWST_BERRY, - .price = 20, - .holdEffect = 5, - .holdEffectParam = 0, - .description = gRawstBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_ASPEAR_BERRY] = { - .name = _("ASPEAR BERRY$"), - .itemId = ITEM_ASPEAR_BERRY, - .price = 20, - .holdEffect = 6, - .holdEffectParam = 0, - .description = gAspearBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_LEPPA_BERRY] = { - .name = _("LEPPA BERRY$"), - .itemId = ITEM_LEPPA_BERRY, - .price = 20, - .holdEffect = 7, - .holdEffectParam = 10, - .description = gLeppaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_PPRecovery, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_PPRecovery, - .secondaryId = 0, - }, - - [ITEM_ORAN_BERRY] = { - .name = _("ORAN BERRY$"), - .itemId = ITEM_ORAN_BERRY, - .price = 20, - .holdEffect = 1, - .holdEffectParam = 10, - .description = gOranBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_PERSIM_BERRY] = { - .name = _("PERSIM BERRY$"), - .itemId = ITEM_PERSIM_BERRY, - .price = 20, - .holdEffect = 8, - .holdEffectParam = 0, - .description = gPersimBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_LUM_BERRY] = { - .name = _("LUM BERRY$"), - .itemId = ITEM_LUM_BERRY, - .price = 20, - .holdEffect = 9, - .holdEffectParam = 0, - .description = gLumBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_SITRUS_BERRY] = { - .name = _("SITRUS BERRY$"), - .itemId = ITEM_SITRUS_BERRY, - .price = 20, - .holdEffect = 1, - .holdEffectParam = 30, - .description = gSitrusBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_Medicine, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_Medicine, - .secondaryId = 0, - }, - - [ITEM_FIGY_BERRY] = { - .name = _("FIGY BERRY$"), - .itemId = ITEM_FIGY_BERRY, - .price = 20, - .holdEffect = 10, - .holdEffectParam = 8, - .description = gFigyBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WIKI_BERRY] = { - .name = _("WIKI BERRY$"), - .itemId = ITEM_WIKI_BERRY, - .price = 20, - .holdEffect = 11, - .holdEffectParam = 8, - .description = gWikiBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MAGO_BERRY] = { - .name = _("MAGO BERRY$"), - .itemId = ITEM_MAGO_BERRY, - .price = 20, - .holdEffect = 12, - .holdEffectParam = 8, - .description = gMagoBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_AGUAV_BERRY] = { - .name = _("AGUAV BERRY$"), - .itemId = ITEM_AGUAV_BERRY, - .price = 20, - .holdEffect = 13, - .holdEffectParam = 8, - .description = gAguavBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_IAPAPA_BERRY] = { - .name = _("IAPAPA BERRY$"), - .itemId = ITEM_IAPAPA_BERRY, - .price = 20, - .holdEffect = 14, - .holdEffectParam = 8, - .description = gIapapaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_RAZZ_BERRY] = { - .name = _("RAZZ BERRY$"), - .itemId = ITEM_RAZZ_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRazzBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BLUK_BERRY] = { - .name = _("BLUK BERRY$"), - .itemId = ITEM_BLUK_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBlukBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_NANAB_BERRY] = { - .name = _("NANAB BERRY$"), - .itemId = ITEM_NANAB_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gNanabBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WEPEAR_BERRY] = { - .name = _("WEPEAR BERRY$"), - .itemId = ITEM_WEPEAR_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gWepearBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PINAP_BERRY] = { - .name = _("PINAP BERRY$"), - .itemId = ITEM_PINAP_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPinapBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_POMEG_BERRY] = { - .name = _("POMEG BERRY$"), - .itemId = ITEM_POMEG_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPomegBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_KELPSY_BERRY] = { - .name = _("KELPSY BERRY$"), - .itemId = ITEM_KELPSY_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gKelpsyBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_QUALOT_BERRY] = { - .name = _("QUALOT BERRY$"), - .itemId = ITEM_QUALOT_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gQualotBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HONDEW_BERRY] = { - .name = _("HONDEW BERRY$"), - .itemId = ITEM_HONDEW_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHondewBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GREPA_BERRY] = { - .name = _("GREPA BERRY$"), - .itemId = ITEM_GREPA_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGrepaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TAMATO_BERRY] = { - .name = _("TAMATO BERRY$"), - .itemId = ITEM_TAMATO_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTamatoBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_ReduceEV, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CORNN_BERRY] = { - .name = _("CORNN BERRY$"), - .itemId = ITEM_CORNN_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gCornnBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MAGOST_BERRY] = { - .name = _("MAGOST BERRY$"), - .itemId = ITEM_MAGOST_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMagostBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_RABUTA_BERRY] = { - .name = _("RABUTA BERRY$"), - .itemId = ITEM_RABUTA_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRabutaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_NOMEL_BERRY] = { - .name = _("NOMEL BERRY$"), - .itemId = ITEM_NOMEL_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gNomelBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SPELON_BERRY] = { - .name = _("SPELON BERRY$"), - .itemId = ITEM_SPELON_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSpelonBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PAMTRE_BERRY] = { - .name = _("PAMTRE BERRY$"), - .itemId = ITEM_PAMTRE_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPamtreBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WATMEL_BERRY] = { - .name = _("WATMEL BERRY$"), - .itemId = ITEM_WATMEL_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gWatmelBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DURIN_BERRY] = { - .name = _("DURIN BERRY$"), - .itemId = ITEM_DURIN_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDurinBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BELUE_BERRY] = { - .name = _("BELUE BERRY$"), - .itemId = ITEM_BELUE_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBelueBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LIECHI_BERRY] = { - .name = _("LIECHI BERRY$"), - .itemId = ITEM_LIECHI_BERRY, - .price = 20, - .holdEffect = 15, - .holdEffectParam = 4, - .description = gLiechiBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GANLON_BERRY] = { - .name = _("GANLON BERRY$"), - .itemId = ITEM_GANLON_BERRY, - .price = 20, - .holdEffect = 16, - .holdEffectParam = 4, - .description = gGanlonBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SALAC_BERRY] = { - .name = _("SALAC BERRY$"), - .itemId = ITEM_SALAC_BERRY, - .price = 20, - .holdEffect = 17, - .holdEffectParam = 4, - .description = gSalacBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PETAYA_BERRY] = { - .name = _("PETAYA BERRY$"), - .itemId = ITEM_PETAYA_BERRY, - .price = 20, - .holdEffect = 18, - .holdEffectParam = 4, - .description = gPetayaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_APICOT_BERRY] = { - .name = _("APICOT BERRY$"), - .itemId = ITEM_APICOT_BERRY, - .price = 20, - .holdEffect = 19, - .holdEffectParam = 4, - .description = gApicotBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LANSAT_BERRY] = { - .name = _("LANSAT BERRY$"), - .itemId = ITEM_LANSAT_BERRY, - .price = 20, - .holdEffect = 20, - .holdEffectParam = 4, - .description = gLansatBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_STARF_BERRY] = { - .name = _("STARF BERRY$"), - .itemId = ITEM_STARF_BERRY, - .price = 20, - .holdEffect = 21, - .holdEffectParam = 4, - .description = gStarfBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ENIGMA_BERRY] = { - .name = _("ENIGMA BERRY$"), - .itemId = ITEM_ENIGMA_BERRY, - .price = 20, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gEnigmaBerryItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_BERRIES, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_EnigmaBerry, - .battleUsage = 1, - .battleUseFunc = ItemUseInBattle_EnigmaBerry, - .secondaryId = 0, - }, - -//empty items - - [ITEM_0B0] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0B1] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0B2] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//hold items - - [ITEM_BRIGHT_POWDER] = { - .name = _("BRIGHTPOWDER$"), - .itemId = ITEM_BRIGHT_POWDER, - .price = 10, - .holdEffect = 22, - .holdEffectParam = 10, - .description = gBrightPowderItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WHITE_HERB] = { - .name = _("WHITE HERB$"), - .itemId = ITEM_WHITE_HERB, - .price = 100, - .holdEffect = 23, - .holdEffectParam = 0, - .description = gWhiteHerbItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MACHO_BRACE] = { - .name = _("MACHO BRACE$"), - .itemId = ITEM_MACHO_BRACE, - .price = 3000, - .holdEffect = 24, - .holdEffectParam = 0, - .description = gMachoBraceItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_EXP_SHARE] = { - .name = _("EXP. SHARE$"), - .itemId = ITEM_EXP_SHARE, - .price = 3000, - .holdEffect = 25, - .holdEffectParam = 0, - .description = gExpShareItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_QUICK_CLAW] = { - .name = _("QUICK CLAW$"), - .itemId = ITEM_QUICK_CLAW, - .price = 100, - .holdEffect = 26, - .holdEffectParam = 20, - .description = gQuickClawItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SOOTHE_BELL] = { - .name = _("SOOTHE BELL$"), - .itemId = ITEM_SOOTHE_BELL, - .price = 100, - .holdEffect = 27, - .holdEffectParam = 0, - .description = gSootheBellItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MENTAL_HERB] = { - .name = _("MENTAL HERB$"), - .itemId = ITEM_MENTAL_HERB, - .price = 100, - .holdEffect = 28, - .holdEffectParam = 0, - .description = gMentalHerbItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CHOICE_BAND] = { - .name = _("CHOICE BAND$"), - .itemId = ITEM_CHOICE_BAND, - .price = 100, - .holdEffect = 29, - .holdEffectParam = 0, - .description = gChoiceBandItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_KINGS_ROCK] = { - .name = _("KING’S ROCK$"), - .itemId = ITEM_KINGS_ROCK, - .price = 100, - .holdEffect = 30, - .holdEffectParam = 10, - .description = gKingsRockItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SILVER_POWDER] = { - .name = _("SILVERPOWDER$"), - .itemId = ITEM_SILVER_POWDER, - .price = 100, - .holdEffect = 31, - .holdEffectParam = 10, - .description = gSilverPowderItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_AMULET_COIN] = { - .name = _("AMULET COIN$"), - .itemId = ITEM_AMULET_COIN, - .price = 100, - .holdEffect = 32, - .holdEffectParam = 10, - .description = gAmuletCoinItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CLEANSE_TAG] = { - .name = _("CLEANSE TAG$"), - .itemId = ITEM_CLEANSE_TAG, - .price = 200, - .holdEffect = 33, - .holdEffectParam = 0, - .description = gCleanseTagItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SOUL_DEW] = { - .name = _("SOUL DEW$"), - .itemId = ITEM_SOUL_DEW, - .price = 200, - .holdEffect = 34, - .holdEffectParam = 0, - .description = gSoulDewItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DEEP_SEA_TOOTH] = { - .name = _("DEEPSEATOOTH$"), - .itemId = ITEM_DEEP_SEA_TOOTH, - .price = 200, - .holdEffect = 35, - .holdEffectParam = 0, - .description = gDeepSeaToothItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DEEP_SEA_SCALE] = { - .name = _("DEEPSEASCALE$"), - .itemId = ITEM_DEEP_SEA_SCALE, - .price = 200, - .holdEffect = 36, - .holdEffectParam = 0, - .description = gDeepSeaScaleItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SMOKE_BALL] = { - .name = _("SMOKE BALL$"), - .itemId = ITEM_SMOKE_BALL, - .price = 200, - .holdEffect = 37, - .holdEffectParam = 0, - .description = gSmokeBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_EVERSTONE] = { - .name = _("EVERSTONE$"), - .itemId = ITEM_EVERSTONE, - .price = 200, - .holdEffect = 38, - .holdEffectParam = 0, - .description = gEverstoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_FOCUS_BAND] = { - .name = _("FOCUS BAND$"), - .itemId = ITEM_FOCUS_BAND, - .price = 200, - .holdEffect = 39, - .holdEffectParam = 10, - .description = gFocusBandItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LUCKY_EGG] = { - .name = _("LUCKY EGG$"), - .itemId = ITEM_LUCKY_EGG, - .price = 200, - .holdEffect = 40, - .holdEffectParam = 0, - .description = gLuckyEggItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SCOPE_LENS] = { - .name = _("SCOPE LENS$"), - .itemId = ITEM_SCOPE_LENS, - .price = 200, - .holdEffect = 41, - .holdEffectParam = 0, - .description = gScopeLensItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_METAL_COAT] = { - .name = _("METAL COAT$"), - .itemId = ITEM_METAL_COAT, - .price = 100, - .holdEffect = 42, - .holdEffectParam = 10, - .description = gMetalCoatItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LEFTOVERS] = { - .name = _("LEFTOVERS$"), - .itemId = ITEM_LEFTOVERS, - .price = 200, - .holdEffect = 43, - .holdEffectParam = 10, - .description = gLeftoversItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DRAGON_SCALE] = { - .name = _("DRAGON SCALE$"), - .itemId = ITEM_DRAGON_SCALE, - .price = 2100, - .holdEffect = 44, - .holdEffectParam = 10, - .description = gDragonScaleItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LIGHT_BALL] = { - .name = _("LIGHT BALL$"), - .itemId = ITEM_LIGHT_BALL, - .price = 100, - .holdEffect = 45, - .holdEffectParam = 0, - .description = gLightBallItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SOFT_SAND] = { - .name = _("SOFT SAND$"), - .itemId = ITEM_SOFT_SAND, - .price = 100, - .holdEffect = 46, - .holdEffectParam = 10, - .description = gSoftSandItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HARD_STONE] = { - .name = _("HARD STONE$"), - .itemId = ITEM_HARD_STONE, - .price = 100, - .holdEffect = 47, - .holdEffectParam = 10, - .description = gHardStoneItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MIRACLE_SEED] = { - .name = _("MIRACLE SEED$"), - .itemId = ITEM_MIRACLE_SEED, - .price = 100, - .holdEffect = 48, - .holdEffectParam = 10, - .description = gMiracleSeedItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BLACK_GLASSES] = { - .name = _("BLACKGLASSES$"), - .itemId = ITEM_BLACK_GLASSES, - .price = 100, - .holdEffect = 49, - .holdEffectParam = 10, - .description = gBlackGlassesItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BLACK_BELT] = { - .name = _("BLACK BELT$"), - .itemId = ITEM_BLACK_BELT, - .price = 100, - .holdEffect = 50, - .holdEffectParam = 10, - .description = gBlackBeltItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MAGNET] = { - .name = _("MAGNET$"), - .itemId = ITEM_MAGNET, - .price = 100, - .holdEffect = 51, - .holdEffectParam = 10, - .description = gMagnetItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MYSTIC_WATER] = { - .name = _("MYSTIC WATER$"), - .itemId = ITEM_MYSTIC_WATER, - .price = 100, - .holdEffect = 52, - .holdEffectParam = 10, - .description = gMysticWaterItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SHARP_BEAK] = { - .name = _("SHARP BEAK$"), - .itemId = ITEM_SHARP_BEAK, - .price = 100, - .holdEffect = 53, - .holdEffectParam = 10, - .description = gSharpBeakItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_POISON_BARB] = { - .name = _("POISON BARB$"), - .itemId = ITEM_POISON_BARB, - .price = 100, - .holdEffect = 54, - .holdEffectParam = 10, - .description = gPoisonBarbItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_NEVER_MELT_ICE] = { - .name = _("NEVERMELTICE$"), - .itemId = ITEM_NEVER_MELT_ICE, - .price = 100, - .holdEffect = 55, - .holdEffectParam = 10, - .description = gNeverMeltIceItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SPELL_TAG] = { - .name = _("SPELL TAG$"), - .itemId = ITEM_SPELL_TAG, - .price = 100, - .holdEffect = 56, - .holdEffectParam = 10, - .description = gSpellTagItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TWISTED_SPOON] = { - .name = _("TWISTEDSPOON$"), - .itemId = ITEM_TWISTED_SPOON, - .price = 100, - .holdEffect = 57, - .holdEffectParam = 10, - .description = gTwistedSpoonItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CHARCOAL] = { - .name = _("CHARCOAL$"), - .itemId = ITEM_CHARCOAL, - .price = 9800, - .holdEffect = 58, - .holdEffectParam = 10, - .description = gCharcoalItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DRAGON_FANG] = { - .name = _("DRAGON FANG$"), - .itemId = ITEM_DRAGON_FANG, - .price = 100, - .holdEffect = 59, - .holdEffectParam = 10, - .description = gDragonFangItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SILK_SCARF] = { - .name = _("SILK SCARF$"), - .itemId = ITEM_SILK_SCARF, - .price = 100, - .holdEffect = 60, - .holdEffectParam = 10, - .description = gSilkScarfItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_UP_GRADE] = { - .name = _("UP-GRADE$"), - .itemId = ITEM_UP_GRADE, - .price = 2100, - .holdEffect = 61, - .holdEffectParam = 0, - .description = gUpGradeItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SHELL_BELL] = { - .name = _("SHELL BELL$"), - .itemId = ITEM_SHELL_BELL, - .price = 200, - .holdEffect = 62, - .holdEffectParam = 8, - .description = gShellBellItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SEA_INCENSE] = { - .name = _("SEA INCENSE$"), - .itemId = ITEM_SEA_INCENSE, - .price = 9600, - .holdEffect = 52, - .holdEffectParam = 5, - .description = gSeaIncenseItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LAX_INCENSE] = { - .name = _("LAX INCENSE$"), - .itemId = ITEM_LAX_INCENSE, - .price = 9600, - .holdEffect = 22, - .holdEffectParam = 5, - .description = gLaxIncenseItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LUCKY_PUNCH] = { - .name = _("LUCKY PUNCH$"), - .itemId = ITEM_LUCKY_PUNCH, - .price = 10, - .holdEffect = 63, - .holdEffectParam = 0, - .description = gLuckyPunchItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_METAL_POWDER] = { - .name = _("METAL POWDER$"), - .itemId = ITEM_METAL_POWDER, - .price = 10, - .holdEffect = 64, - .holdEffectParam = 0, - .description = gMetalPowderItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_THICK_CLUB] = { - .name = _("THICK CLUB$"), - .itemId = ITEM_THICK_CLUB, - .price = 500, - .holdEffect = 65, - .holdEffectParam = 0, - .description = gThickClubItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_STICK] = { - .name = _("STICK$"), - .itemId = ITEM_STICK, - .price = 200, - .holdEffect = 66, - .holdEffectParam = 0, - .description = gStickItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//empty items - - [ITEM_0E2] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E3] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E4] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E5] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E6] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E7] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E8] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0E9] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0EA] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0EB] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0EC] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0ED] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0EE] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0EF] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F0] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F1] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F2] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F3] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F4] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F5] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F6] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F7] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F8] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0F9] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0FA] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0FB] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0FC] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_0FD] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//hold items continued - - [ITEM_RED_SCARF] = { - .name = _("RED SCARF$"), - .itemId = ITEM_RED_SCARF, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRedScarfItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BLUE_SCARF] = { - .name = _("BLUE SCARF$"), - .itemId = ITEM_BLUE_SCARF, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBlueScarfItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_PINK_SCARF] = { - .name = _("PINK SCARF$"), - .itemId = ITEM_PINK_SCARF, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPinkScarfItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GREEN_SCARF] = { - .name = _("GREEN SCARF$"), - .itemId = ITEM_GREEN_SCARF, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGreenScarfItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_YELLOW_SCARF] = { - .name = _("YELLOW SCARF$"), - .itemId = ITEM_YELLOW_SCARF, - .price = 100, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gYellowScarfItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Key items - - [ITEM_MACH_BIKE] = { - .name = _("MACH BIKE$"), - .itemId = ITEM_MACH_BIKE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMachBikeItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_Bike, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_COIN_CASE] = { - .name = _("COIN CASE$"), - .itemId = ITEM_COIN_CASE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gCoinCaseItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CoinCase, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ITEMFINDER] = { - .name = _("ITEMFINDER$"), - .itemId = ITEM_ITEMFINDER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gItemfinderItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_Itemfinder, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_OLD_ROD] = { - .name = _("OLD ROD$"), - .itemId = ITEM_OLD_ROD, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gOldRodItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_Rod, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GOOD_ROD] = { - .name = _("GOOD ROD$"), - .itemId = ITEM_GOOD_ROD, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGoodRodItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_Rod, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 1, - }, - - [ITEM_SUPER_ROD] = { - .name = _("SUPER ROD$"), - .itemId = ITEM_SUPER_ROD, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSuperRodItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_Rod, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 2, - }, - - [ITEM_SS_TICKET] = { - .name = _("S.S. TICKET$"), - .itemId = ITEM_SS_TICKET, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSSTicketItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CONTEST_PASS] = { - .name = _("CONTEST PASS$"), - .itemId = ITEM_CONTEST_PASS, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gContestPassItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_10B] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_WAILMER_PAIL] = { - .name = _("WAILMER PAIL$"), - .itemId = ITEM_WAILMER_PAIL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gWailmerPailItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_WailmerPail, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DEVON_GOODS] = { - .name = _("DEVON GOODS$"), - .itemId = ITEM_DEVON_GOODS, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDevonGoodsItemDescription, - .importance = 2, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SOOT_SACK] = { - .name = _("SOOT SACK$"), - .itemId = ITEM_SOOT_SACK, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSootSackItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BASEMENT_KEY] = { - .name = _("BASEMENT KEY$"), - .itemId = ITEM_BASEMENT_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBasementKeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ACRO_BIKE] = { - .name = _("ACRO BIKE$"), - .itemId = ITEM_ACRO_BIKE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gAcroBikeItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_Bike, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 1, - }, - - [ITEM_POKEBLOCK_CASE] = { - .name = _("{POKEBLOCK} CASE$"), - .itemId = ITEM_POKEBLOCK_CASE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPokeblockCaseItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 3, - .fieldUseFunc = ItemUseOutOfBattle_PokeblockCase, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LETTER] = { - .name = _("LETTER$"), - .itemId = ITEM_LETTER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gLetterItemDescription, - .importance = 2, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_EON_TICKET] = { - .name = _("EON TICKET$"), - .itemId = ITEM_EON_TICKET, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gEonTicketItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 1, - }, - - [ITEM_RED_ORB] = { - .name = _("RED ORB$"), - .itemId = ITEM_RED_ORB, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRedOrbItemDescription, - .importance = 2, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BLUE_ORB] = { - .name = _("BLUE ORB$"), - .itemId = ITEM_BLUE_ORB, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBlueOrbItemDescription, - .importance = 2, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SCANNER] = { - .name = _("SCANNER$"), - .itemId = ITEM_SCANNER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gScannerItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GO_GOGGLES] = { - .name = _("GO-GOGGLES$"), - .itemId = ITEM_GO_GOGGLES, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGoGogglesItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_METEORITE] = { - .name = _("METEORITE$"), - .itemId = ITEM_METEORITE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMeteoriteItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ROOM_1_KEY] = { - .name = _("RM. 1 KEY$"), - .itemId = ITEM_ROOM_1_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRoom1KeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ROOM_2_KEY] = { - .name = _("RM. 2 KEY$"), - .itemId = ITEM_ROOM_2_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRoom2KeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ROOM_4_KEY] = { - .name = _("RM. 4 KEY$"), - .itemId = ITEM_ROOM_4_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRoom4KeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ROOM_6_KEY] = { - .name = _("RM. 6 KEY$"), - .itemId = ITEM_ROOM_6_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRoom6KeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_STORAGE_KEY] = { - .name = _("STORAGE KEY$"), - .itemId = ITEM_STORAGE_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gStorageKeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_ROOT_FOSSIL] = { - .name = _("ROOT FOSSIL$"), - .itemId = ITEM_ROOT_FOSSIL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRootFossilItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CLAW_FOSSIL] = { - .name = _("CLAW FOSSIL$"), - .itemId = ITEM_CLAW_FOSSIL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gClawFossilItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DEVON_SCOPE] = { - .name = _("DEVON SCOPE$"), - .itemId = ITEM_DEVON_SCOPE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDevonScopeItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//TMs/HMs - - [ITEM_TM01] = { - .name = _("TM$01"), - .itemId = ITEM_TM01, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM01ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM02] = { - .name = _("TM02$"), - .itemId = ITEM_TM02, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM02ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM03] = { - .name = _("TM03$"), - .itemId = ITEM_TM03, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM03ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM04] = { - .name = _("TM04$"), - .itemId = ITEM_TM04, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM04ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM05] = { - .name = _("TM05$"), - .itemId = ITEM_TM05, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM05ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM06] = { - .name = _("TM06$"), - .itemId = ITEM_TM06, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM06ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM07] = { - .name = _("TM07$"), - .itemId = ITEM_TM07, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM07ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM08] = { - .name = _("TM08$"), - .itemId = ITEM_TM08, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM08ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM09] = { - .name = _("TM09$"), - .itemId = ITEM_TM09, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM09ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM10] = { - .name = _("TM10$"), - .itemId = ITEM_TM10, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM10ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM11] = { - .name = _("TM11$"), - .itemId = ITEM_TM11, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM11ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM12] = { - .name = _("TM12$"), - .itemId = ITEM_TM12, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM12ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM13] = { - .name = _("TM13$"), - .itemId = ITEM_TM13, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM13ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM14] = { - .name = _("TM14$"), - .itemId = ITEM_TM14, - .price = 5500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM14ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM15] = { - .name = _("TM15$"), - .itemId = ITEM_TM15, - .price = 7500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM15ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM16] = { - .name = _("TM16$"), - .itemId = ITEM_TM16, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM16ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM17] = { - .name = _("TM17$"), - .itemId = ITEM_TM17, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM17ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM18] = { - .name = _("TM18$"), - .itemId = ITEM_TM18, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM18ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM19] = { - .name = _("TM19$"), - .itemId = ITEM_TM19, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM19ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM20] = { - .name = _("TM20$"), - .itemId = ITEM_TM20, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM20ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM21] = { - .name = _("TM21$"), - .itemId = ITEM_TM21, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM21ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM22] = { - .name = _("TM22$"), - .itemId = ITEM_TM22, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM22ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM23] = { - .name = _("TM23$"), - .itemId = ITEM_TM23, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM23ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM24] = { - .name = _("TM24$"), - .itemId = ITEM_TM24, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM24ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM25] = { - .name = _("TM25$"), - .itemId = ITEM_TM25, - .price = 5500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM25ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM26] = { - .name = _("TM26$"), - .itemId = ITEM_TM26, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM26ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM27] = { - .name = _("TM27$"), - .itemId = ITEM_TM27, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM27ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM28] = { - .name = _("TM28$"), - .itemId = ITEM_TM28, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM28ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM29] = { - .name = _("TM29$"), - .itemId = ITEM_TM29, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM29ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM30] = { - .name = _("TM30$"), - .itemId = ITEM_TM30, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM30ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM31] = { - .name = _("TM31$"), - .itemId = ITEM_TM31, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM31ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM32] = { - .name = _("TM32$"), - .itemId = ITEM_TM32, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM32ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM33] = { - .name = _("TM33$"), - .itemId = ITEM_TM33, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM33ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM34] = { - .name = _("TM34$"), - .itemId = ITEM_TM34, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM34ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM35] = { - .name = _("TM35$"), - .itemId = ITEM_TM35, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM35ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM36] = { - .name = _("TM36$"), - .itemId = ITEM_TM36, - .price = 1000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM36ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM37] = { - .name = _("TM37$"), - .itemId = ITEM_TM37, - .price = 2000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM37ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM38] = { - .name = _("TM38$"), - .itemId = ITEM_TM38, - .price = 5500, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM38ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM39] = { - .name = _("TM39$"), - .itemId = ITEM_TM39, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM39ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM40] = { - .name = _("TM40$"), - .itemId = ITEM_TM40, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM40ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM41] = { - .name = _("TM41$"), - .itemId = ITEM_TM41, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM41ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM42] = { - .name = _("TM42$"), - .itemId = ITEM_TM42, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM42ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM43] = { - .name = _("TM43$"), - .itemId = ITEM_TM43, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM43ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM44] = { - .name = _("TM44$"), - .itemId = ITEM_TM44, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM44ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM45] = { - .name = _("TM45$"), - .itemId = ITEM_TM45, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM45ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM46] = { - .name = _("TM46$"), - .itemId = ITEM_TM46, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM46ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM47] = { - .name = _("TM47$"), - .itemId = ITEM_TM47, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM47ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM48] = { - .name = _("TM48$"), - .itemId = ITEM_TM48, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM48ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM49] = { - .name = _("TM49$"), - .itemId = ITEM_TM49, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM49ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM50] = { - .name = _("TM50$"), - .itemId = ITEM_TM50, - .price = 3000, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTM50ItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM01] = { - .name = _("HM01$"), - .itemId = ITEM_HM01, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM01ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM02] = { - .name = _("HM02$"), - .itemId = ITEM_HM02, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM02ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM03] = { - .name = _("HM03$"), - .itemId = ITEM_HM03, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM03ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM04] = { - .name = _("HM04$"), - .itemId = ITEM_HM04, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM04ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM05] = { - .name = _("HM05$"), - .itemId = ITEM_HM05, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM05ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM06] = { - .name = _("HM06$"), - .itemId = ITEM_HM06, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM06ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM07] = { - .name = _("HM07$"), - .itemId = ITEM_HM07, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM07ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HM08] = { - .name = _("HM08$"), - .itemId = ITEM_HM08, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHM08ItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_TM_HM, - .type = 1, - .fieldUseFunc = ItemUseOutOfBattle_TMHM, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Empty items - - [ITEM_15B] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_15C] = { - .name = _("????????$"), - .itemId = ITEM_NONE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDummyItemDescription, - .importance = 0, - .unk19 = 0, - .pocket = POCKET_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//FireRed/LeafGreen key items - - [ITEM_OAKS_PARCEL] = { - .name = _("OAK’S PARCEL$"), - .itemId = ITEM_OAKS_PARCEL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gOaksParcelItemDescription, - .importance = 2, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_POKE_FLUTE] = { - .name = _("POKĂ© FLUTE$"), - .itemId = ITEM_POKE_FLUTE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPokeFluteItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SECRET_KEY] = { - .name = _("SECRET KEY$"), - .itemId = ITEM_SECRET_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSecretKeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BIKE_VOUCHER] = { - .name = _("BIKE VOUCHER$"), - .itemId = ITEM_BIKE_VOUCHER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBikeVoucherItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_GOLD_TEETH] = { - .name = _("GOLD TEETH$"), - .itemId = ITEM_GOLD_TEETH, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gGoldTeethItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_OLD_AMBER] = { - .name = _("OLD AMBER$"), - .itemId = ITEM_OLD_AMBER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gOldAmberItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_CARD_KEY] = { - .name = _("CARD KEY$"), - .itemId = ITEM_CARD_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gCardKeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_LIFT_KEY] = { - .name = _("LIFT KEY$"), - .itemId = ITEM_LIFT_KEY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gLiftKeyItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_HELIX_FOSSIL] = { - .name = _("HELIX FOSSIL$"), - .itemId = ITEM_HELIX_FOSSIL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gHelixFossilItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_DOME_FOSSIL] = { - .name = _("DOME FOSSIL$"), - .itemId = ITEM_DOME_FOSSIL, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gDomeFossilItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SILPH_SCOPE] = { - .name = _("SILPH SCOPE$"), - .itemId = ITEM_SILPH_SCOPE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSilphScopeItemDescription, - .importance = 1, - .unk19 = 0, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BICYCLE] = { - .name = _("BICYCLE$"), - .itemId = ITEM_BICYCLE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBicycleItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TOWN_MAP] = { - .name = _("TOWN MAP$"), - .itemId = ITEM_TOWN_MAP, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTownMapItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_VS_SEEKER] = { - .name = _("VS SEEKER$"), - .itemId = ITEM_VS_SEEKER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gVSSeekerItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_FAME_CHECKER] = { - .name = _("FAME CHECKER$"), - .itemId = ITEM_FAME_CHECKER, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gFameCheckerItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TM_CASE] = { - .name = _("TM CASE$"), - .itemId = ITEM_TM_CASE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTMCaseItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_BERRY_POUCH] = { - .name = _("BERRY POUCH$"), - .itemId = ITEM_BERRY_POUCH, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gBerryPouchItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TEACHY_TV] = { - .name = _("TEACHY TV$"), - .itemId = ITEM_TEACHY_TV, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTeachyTVItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 2, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TRI_PASS] = { - .name = _("TRI-PASS$"), - .itemId = ITEM_TRI_PASS, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTriPassItemDescription, - .importance = 1, - .unk19 = 4, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_RAINBOW_PASS] = { - .name = _("RAINBOW PASS$"), - .itemId = ITEM_RAINBOW_PASS, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRainbowPassItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_TEA] = { - .name = _("TEA$"), - .itemId = ITEM_TEA, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gTeaItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_MYSTIC_TICKET] = { - .name = _("MYSTICTICKET$"), - .itemId = ITEM_MYSTIC_TICKET, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMysticTicketItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_AURORA_TICKET] = { - .name = _("AURORATICKET$"), - .itemId = ITEM_AURORA_TICKET, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gAuroraTicketItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_POWDER_JAR] = { - .name = _("POWDER JAR$"), - .itemId = ITEM_POWDER_JAR, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gPowderJarItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_PowderJar, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_RUBY] = { - .name = _("RUBY$"), - .itemId = ITEM_RUBY, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gRubyItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_SAPPHIRE] = { - .name = _("SAPPHIRE$"), - .itemId = ITEM_SAPPHIRE, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gSapphireItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -//Emerald-specific key items - - [ITEM_MAGMA_EMBLEM] = { - .name = _("MAGMA EMBLEM$"), - .itemId = ITEM_MAGMA_EMBLEM, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gMagmaEmblemItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - - [ITEM_OLD_SEA_MAP] = { - .name = _("OLD SEA MAP$"), - .itemId = ITEM_OLD_SEA_MAP, - .price = 0, - .holdEffect = 0, - .holdEffectParam = 0, - .description = gOldSeaMapItemDescription, - .importance = 1, - .unk19 = 1, - .pocket = POCKET_KEY_ITEMS, - .type = 4, - .fieldUseFunc = ItemUseOutOfBattle_CannotUse, - .battleUsage = 0, - .battleUseFunc = NULL, - .secondaryId = 0, - }, - -}; -- cgit v1.2.3 From a49f80d552a9adff15a097171898e113cfa412b9 Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Wed, 25 Apr 2018 01:41:04 +0100 Subject: Convert item_descriptions.inc to .h OK --- src/item.c | 11 ----------- src/item_menu_icons.c | 6 ++++++ 2 files changed, 6 insertions(+), 11 deletions(-) (limited to 'src') diff --git a/src/item.c b/src/item.c index 9e521db77..a17599db9 100644 --- a/src/item.c +++ b/src/item.c @@ -25,17 +25,6 @@ enum KEYITEMS_POCKET }; -enum -{ - POCKET_ITEMS = 1, - POCKET_POKE_BALLS, - POCKET_TM_HM, - POCKET_BERRIES, - POCKET_KEY_ITEMS, -}; -#include "item_use.h" -#include "data/text/item_descriptions.h" -#include "data/items.h" u16 GetBagItemQuantity(u16* quantity) { return gSaveBlock2Ptr->encryptionKey ^ *quantity; diff --git a/src/item_menu_icons.c b/src/item_menu_icons.c index 1d9dbb106..828722192 100644 --- a/src/item_menu_icons.c +++ b/src/item_menu_icons.c @@ -9,6 +9,9 @@ #include "berry.h" #include "graphics.h" #include "constants/items.h" +#include "item.h" +#include "item_use.h" +#include "constants/hold_effects.h" struct CompressedTilesPal { @@ -466,6 +469,9 @@ const struct SpriteTemplate gUnknown_0857FE88 = .callback = sub_80D5B48, }; +#include "data/text/item_descriptions.h" +//#include "data/items.h" + // code void RemoveBagSprite(u8 id) { -- cgit v1.2.3 From 39fd42faeadeb73bf57018f69a6d69463635847a Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Wed, 25 Apr 2018 02:33:55 +0100 Subject: convert data/items.inc to include/data/items.h OK --- src/item_menu_icons.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/item_menu_icons.c b/src/item_menu_icons.c index 828722192..f12bb454e 100644 --- a/src/item_menu_icons.c +++ b/src/item_menu_icons.c @@ -470,7 +470,7 @@ const struct SpriteTemplate gUnknown_0857FE88 = }; #include "data/text/item_descriptions.h" -//#include "data/items.h" +#include "data/items.h" // code void RemoveBagSprite(u8 id) -- cgit v1.2.3 From 25c669e36b8d23a24da567007bda1210ad9ce97e Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 29 Apr 2018 13:36:26 +0200 Subject: decompile item --- src/item.c | 1023 +++++++++++++++++++++++++++++++++++++++--- src/item_menu.c | 40 +- src/lilycove_lady.c | 4 +- src/player_pc.c | 12 +- src/pokeblock.c | 2 +- src/pokemon_summary_screen.c | 4 +- src/tv.c | 24 +- 7 files changed, 1000 insertions(+), 109 deletions(-) (limited to 'src') diff --git a/src/item.c b/src/item.c index a17599db9..a6e89a8e5 100644 --- a/src/item.c +++ b/src/item.c @@ -5,50 +5,63 @@ #include "string_util.h" #include "text.h" #include "event_data.h" +#include "malloc.h" +#include "secret_base.h" +#include "item_menu.h" -extern void ApplyNewEncryptionKeyToHword(u16* hword, u32 newKey); +// These constants are used in gItems +enum +{ + POCKET_NONE, + POCKET_ITEMS, + POCKET_POKE_BALLS, + POCKET_TM_HM, + POCKET_BERRIES, + POCKET_KEY_ITEMS, +}; + +extern void ApplyNewEncryptionKeyToHword(u16 *hword, u32 newKey); extern bool8 InBattlePyramid(void); extern const u8 gText_PokeBalls[]; extern const u8 gText_Berries[]; extern const u8 gText_Berry[]; -bool8 CheckPyramidBagHasItem(u16 itemId, u16 count); -bool8 CheckPyramidBagHasSpace(u16 itemId, u16 count); +extern const struct Item gItems[]; -enum -{ - ITEMS_POCKET, - BALLS_POCKET, - TMHM_POCKET, - BERRIES_POCKET, - KEYITEMS_POCKET -}; +// this file's functions + +static bool8 CheckPyramidBagHasItem(u16 itemId, u16 count); +static bool8 CheckPyramidBagHasSpace(u16 itemId, u16 count); +static bool8 AddPyramidBagItem(u16 itemId, u16 count); +static bool8 RemovePyramidBagItem(u16 itemId, u16 count); + +// code -u16 GetBagItemQuantity(u16* quantity) +u16 GetBagItemQuantity(u16 *quantity) { return gSaveBlock2Ptr->encryptionKey ^ *quantity; } -void SetBagItemQuantity(u16* quantity, u16 newValue) +void SetBagItemQuantity(u16 *quantity, u16 newValue) { *quantity = newValue ^ gSaveBlock2Ptr->encryptionKey; } -u16 GetBagItemId(u16* slot) +u16 GetPCItemQuantity(u16 *quantity) { - return *slot; + return *quantity; } -void SetBagItemId(u16* slot, u16 newItemId) +void SetPCItemQuantity(u16 *quantity, u16 newValue) { - *slot = newItemId; + *quantity = newValue; } void ApplyNewEncryptionKeyToBagItems(u32 newKey) { u32 pocket, item; - for (pocket = 0; pocket < 5; pocket++) + for (pocket = 0; pocket < POCKETS_COUNT; pocket++) { for (item = 0; item < gBagPockets[pocket].capacity; item++) ApplyNewEncryptionKeyToHword(&(gBagPockets[pocket].itemSlots[item].quantity), newKey); @@ -60,29 +73,27 @@ void ApplyNewEncryptionKeyToBagItems_(u32 newKey) // really GF? ApplyNewEncryptionKeyToBagItems(newKey); } -// TODO: move those max values to defines - void SetBagItemsPointers(void) { gBagPockets[ITEMS_POCKET].itemSlots = gSaveBlock1Ptr->bagPocket_Items; - gBagPockets[ITEMS_POCKET].capacity = 30; + gBagPockets[ITEMS_POCKET].capacity = BAG_ITEMS_COUNT; gBagPockets[KEYITEMS_POCKET].itemSlots = gSaveBlock1Ptr->bagPocket_KeyItems; - gBagPockets[KEYITEMS_POCKET].capacity = 30; + gBagPockets[KEYITEMS_POCKET].capacity = BAG_KEYITEMS_COUNT; gBagPockets[BALLS_POCKET].itemSlots = gSaveBlock1Ptr->bagPocket_PokeBalls; - gBagPockets[BALLS_POCKET].capacity = 16; + gBagPockets[BALLS_POCKET].capacity = BAG_POKEBALLS_COUNT; gBagPockets[TMHM_POCKET].itemSlots = gSaveBlock1Ptr->bagPocket_TMHM; - gBagPockets[TMHM_POCKET].capacity = 64; + gBagPockets[TMHM_POCKET].capacity = BAG_TMHM_COUNT; gBagPockets[BERRIES_POCKET].itemSlots = gSaveBlock1Ptr->bagPocket_Berries; - gBagPockets[BERRIES_POCKET].capacity = 46; + gBagPockets[BERRIES_POCKET].capacity = BAG_BERRIES_COUNT; } void CopyItemName(u16 itemId, u8 *string) { - StringCopy(string, ItemId_GetItem(itemId)->name); + StringCopy(string, ItemId_GetName(itemId)); } void CopyItemNameHandlePlural(u16 itemId, u8 *string, u32 quantity) @@ -90,7 +101,7 @@ void CopyItemNameHandlePlural(u16 itemId, u8 *string, u32 quantity) if (itemId == ITEM_POKE_BALL) { if (quantity < 2) - StringCopy(string, ItemId_GetItem(ITEM_POKE_BALL)->name); + StringCopy(string, ItemId_GetName(ITEM_POKE_BALL)); else StringCopy(string, gText_PokeBalls); } @@ -99,19 +110,20 @@ void CopyItemNameHandlePlural(u16 itemId, u8 *string, u32 quantity) if (itemId >= ITEM_CHERI_BERRY && itemId <= ITEM_ENIGMA_BERRY) GetBerryCountString(string, gBerries[itemId - ITEM_CHERI_BERRY].name, quantity); else - StringCopy(string, ItemId_GetItem(itemId)->name); + StringCopy(string, ItemId_GetName(itemId)); } } -void GetBerryCountString(u8* dst, const u8* berryName, u32 quantity) +void GetBerryCountString(u8 *dst, const u8 *berryName, u32 quantity) { - const u8* berryString; - u8* txtPtr; + const u8 *berryString; + u8 *txtPtr; if (quantity < 2) berryString = gText_Berry; else berryString = gText_Berries; + txtPtr = StringCopy(dst, berryName); *txtPtr = CHAR_SPACE; StringCopy(txtPtr + 1, berryString); @@ -136,10 +148,10 @@ bool8 CheckBagHasItem(u16 itemId, u16 count) if (ItemId_GetPocket(itemId) == 0) return FALSE; - if (InBattlePyramid() || FlagGet(0x4004) == TRUE) + if (InBattlePyramid() || FlagGet(FLAG_SPECIAL_FLAG_0x4004) == TRUE) return CheckPyramidBagHasItem(itemId, count); pocket = ItemId_GetPocket(itemId) - 1; - //Check for item slots that contain the item + // Check for item slots that contain the item for (i = 0; i < gBagPockets[pocket].capacity; i++) { if (gBagPockets[pocket].itemSlots[i].itemId == itemId) @@ -161,69 +173,948 @@ bool8 CheckBagHasItem(u16 itemId, u16 count) bool8 HasAtLeastOneBerry(void) { u16 i; - for (i = 0x85; i < 0xB3; i++) + + for (i = FIRST_BERRY_INDEX; i < ITEM_BRIGHT_POWDER; i++) { if (CheckBagHasItem(i, 1) == TRUE) { - gSpecialVar_Result = 1; + gSpecialVar_Result = TRUE; return TRUE; } } - gSpecialVar_Result = 0; + gSpecialVar_Result = FALSE; return FALSE; } -/* Refuses to match. +#ifdef NONMATCHING +// Refuses to match. bool8 CheckBagHasSpace(u16 itemId, u16 count) { u8 i; - u8 pocket; - u16 slotCapacity; - u16 quantity; - if (ItemId_GetPocket(itemId) == 0) + if (ItemId_GetPocket(itemId) == POCKET_NONE) return FALSE; - if (InBattlePyramid() || FlagGet(0x4004) == TRUE) + + if (InBattlePyramid() || FlagGet(FLAG_SPECIAL_FLAG_0x4004) == TRUE) + { return CheckPyramidBagHasSpace(itemId, count); - pocket = ItemId_GetPocket(itemId) - 1; - if (pocket != BERRIES_POCKET) - slotCapacity = 99; + } else - slotCapacity = 999; + { + u8 pocket; + u16 slotCapacity; + u16 ownedCount; - //Check space in any existing item slots that already contain this item - for (i = 0; i < gBagPockets[pocket].capacity; i++) + pocket = ItemId_GetPocket(itemId) - 1; + if (pocket != BERRIES_POCKET) + slotCapacity = 99; + else + slotCapacity = 999; + + // Check space in any existing item slots that already contain this item + for (i = 0; i < gBagPockets[pocket].capacity; i++) + { + if (gBagPockets[pocket].itemSlots[i].itemId == itemId) + { + ownedCount = GetBagItemQuantity(&gBagPockets[pocket].itemSlots[i].quantity); + if (ownedCount + count <= slotCapacity) + return TRUE; + if (pocket == TMHM_POCKET || pocket == BERRIES_POCKET) + return FALSE; + count -= slotCapacity - ownedCount; + if (count == 0) + return TRUE; + } + } + + // Check space in empty item slots + if (count > 0) + { + for (i = 0; i < gBagPockets[pocket].capacity; i++) + { + if (gBagPockets[pocket].itemSlots[i].itemId == 0) + { + if (count <= slotCapacity) + return TRUE; + if (pocket == TMHM_POCKET || pocket == BERRIES_POCKET) + return FALSE; + count -= slotCapacity; + } + } + if (count > 0) + return FALSE; // No more item slots. The bag is full + } + + return TRUE; + } +} +#else +ASM_DIRECT +bool8 CheckBagHasSpace(u16 itemId, u16 count) +{ + asm_unified("push {r4-r7,lr}\n\ + mov r7, r10\n\ + mov r6, r9\n\ + mov r5, r8\n\ + push {r5-r7}\n\ + sub sp, 0x4\n\ + lsls r0, 16\n\ + lsrs r0, 16\n\ + mov r8, r0\n\ + lsls r1, 16\n\ + lsrs r5, r1, 16\n\ + bl ItemId_GetPocket\n\ + lsls r0, 24\n\ + cmp r0, 0\n\ + beq _080D6906\n\ + bl InBattlePyramid\n\ + lsls r0, 24\n\ + cmp r0, 0\n\ + bne _080D6838\n\ + ldr r0, =0x00004004\n\ + bl FlagGet\n\ + lsls r0, 24\n\ + lsrs r0, 24\n\ + cmp r0, 0x1\n\ + bne _080D684C\n\ +_080D6838:\n\ + mov r0, r8\n\ + adds r1, r5, 0\n\ + bl CheckPyramidBagHasSpace\n\ + lsls r0, 24\n\ + lsrs r0, 24\n\ + b _080D6916\n\ + .pool\n\ +_080D684C:\n\ + mov r0, r8\n\ + bl ItemId_GetPocket\n\ + subs r0, 0x1\n\ + lsls r0, 24\n\ + lsrs r2, r0, 24\n\ + ldr r7, =0x000003e7\n\ + cmp r2, 0x3\n\ + beq _080D6860\n\ + movs r7, 0x63\n\ +_080D6860:\n\ + movs r6, 0\n\ + ldr r1, =gBagPockets\n\ + lsls r4, r2, 3\n\ + adds r0, r4, r1\n\ + mov r9, r4\n\ + ldrb r0, [r0, 0x4]\n\ + cmp r6, r0\n\ + bcs _080D68BC\n\ + subs r0, r2, 0x2\n\ + lsls r0, 24\n\ + lsrs r0, 24\n\ + mov r10, r0\n\ +_080D6878:\n\ + adds r0, r4, r1\n\ + ldr r1, [r0]\n\ + lsls r0, r6, 2\n\ + adds r1, r0, r1\n\ + ldrh r0, [r1]\n\ + cmp r0, r8\n\ + bne _080D68AC\n\ + adds r0, r1, 0x2\n\ + str r2, [sp]\n\ + bl GetBagItemQuantity\n\ + lsls r0, 16\n\ + lsrs r1, r0, 16\n\ + adds r0, r1, r5\n\ + ldr r2, [sp]\n\ + cmp r0, r7\n\ + ble _080D6914\n\ + mov r0, r10\n\ + cmp r0, 0x1\n\ + bls _080D6906\n\ + subs r0, r7, r1\n\ + subs r0, r5, r0\n\ + lsls r0, 16\n\ + lsrs r5, r0, 16\n\ + cmp r5, 0\n\ + beq _080D6914\n\ +_080D68AC:\n\ + adds r0, r6, 0x1\n\ + lsls r0, 24\n\ + lsrs r6, r0, 24\n\ + ldr r1, =gBagPockets\n\ + adds r0, r4, r1\n\ + ldrb r0, [r0, 0x4]\n\ + cmp r6, r0\n\ + bcc _080D6878\n\ +_080D68BC:\n\ + cmp r5, 0\n\ + beq _080D6914\n\ + movs r6, 0\n\ + ldr r3, =gBagPockets\n\ + mov r1, r9\n\ + adds r0, r1, r3\n\ + ldrb r0, [r0, 0x4]\n\ + cmp r6, r0\n\ + bcs _080D6902\n\ + adds r4, r3, 0\n\ + subs r0, r2, 0x2\n\ + lsls r0, 24\n\ + lsrs r2, r0, 24\n\ +_080D68D6:\n\ + adds r0, r1, r4\n\ + ldr r1, [r0]\n\ + lsls r0, r6, 2\n\ + adds r0, r1\n\ + ldrh r0, [r0]\n\ + cmp r0, 0\n\ + bne _080D68F2\n\ + cmp r5, r7\n\ + bls _080D6914\n\ + cmp r2, 0x1\n\ + bls _080D6906\n\ + subs r0, r5, r7\n\ + lsls r0, 16\n\ + lsrs r5, r0, 16\n\ +_080D68F2:\n\ + adds r0, r6, 0x1\n\ + lsls r0, 24\n\ + lsrs r6, r0, 24\n\ + mov r1, r9\n\ + adds r0, r1, r3\n\ + ldrb r0, [r0, 0x4]\n\ + cmp r6, r0\n\ + bcc _080D68D6\n\ +_080D6902:\n\ + cmp r5, 0\n\ + beq _080D6914\n\ +_080D6906:\n\ + movs r0, 0\n\ + b _080D6916\n\ + .pool\n\ +_080D6914:\n\ + movs r0, 0x1\n\ +_080D6916:\n\ + add sp, 0x4\n\ + pop {r3-r5}\n\ + mov r8, r3\n\ + mov r9, r4\n\ + mov r10, r5\n\ + pop {r4-r7}\n\ + pop {r1}\n\ + bx r1"); +} +#endif // NONMATCHING + +bool8 AddBagItem(u16 itemId, u16 count) +{ + u8 i; + + if (ItemId_GetPocket(itemId) == POCKET_NONE) + return FALSE; + + // check Battle Pyramid Bag + if (InBattlePyramid() || FlagGet(FLAG_SPECIAL_FLAG_0x4004) == TRUE) { - if (gBagPockets[pocket].itemSlots[i].itemId == itemId) + return AddPyramidBagItem(itemId, count); + } + else + { + struct BagPocket *itemPocket; + struct ItemSlot *newItems; + u16 slotCapacity; + u16 ownedCount; + u8 pocket = ItemId_GetPocket(itemId) - 1; + + itemPocket = &gBagPockets[pocket]; + newItems = AllocZeroed(itemPocket->capacity * sizeof(struct ItemSlot)); + memcpy(newItems, itemPocket->itemSlots, itemPocket->capacity * sizeof(struct ItemSlot)); + + if (pocket != BERRIES_POCKET) + slotCapacity = 99; + else + slotCapacity = 999; + + for (i = 0; i < itemPocket->capacity; i++) { - quantity = GetBagItemQuantity(&gBagPockets[pocket].itemSlots[i].quantity); - if (quantity + count <= slotCapacity) - return TRUE; - if (pocket == TMHM_POCKET || pocket == BERRIES_POCKET) + if (newItems[i].itemId == itemId) + { + ownedCount = GetBagItemQuantity(&newItems[i].quantity); + // check if won't exceed max slot capacity + if (ownedCount + count <= slotCapacity) + { + // successfully added to already existing item's count + SetBagItemQuantity(&newItems[i].quantity, ownedCount + count); + + // goto SUCCESS_ADD_ITEM; + // is equivalent but won't match + + memcpy(itemPocket->itemSlots, newItems, itemPocket->capacity * sizeof(struct ItemSlot)); + Free(newItems); + return TRUE; + } + else + { + // try creating another instance of the item if possible + if (pocket == TMHM_POCKET || pocket == BERRIES_POCKET) + { + Free(newItems); + return FALSE; + } + else + { + count -= slotCapacity - ownedCount; + SetBagItemQuantity(&newItems[i].quantity, slotCapacity); + // don't create another instance of the item if it's at max slot capacity and count is equal to 0 + if (count == 0) + { + goto SUCCESS_ADD_ITEM; + } + } + } + } + } + + // we're done if quantity is equal to 0 + if (count > 0) + { + // either no existing item was found or we have to create another instance, because the capacity was exceeded + for (i = 0; i < itemPocket->capacity; i++) + { + if (newItems[i].itemId == ITEM_NONE) + { + newItems[i].itemId = itemId; + if (count > slotCapacity) + { + // try creating a new slot with max capacity if duplicates are possible + if (pocket == TMHM_POCKET || pocket == BERRIES_POCKET) + { + Free(newItems); + return FALSE; + } + count -= slotCapacity; + SetBagItemQuantity(&newItems[i].quantity, slotCapacity); + } + else + { + // created a new slot and added quantity + SetBagItemQuantity(&newItems[i].quantity, count); + goto SUCCESS_ADD_ITEM; + } + } + } + + if (count > 0) + { + Free(newItems); return FALSE; - count -= slotCapacity - quantity; + } + } + + SUCCESS_ADD_ITEM: + memcpy(itemPocket->itemSlots, newItems, itemPocket->capacity * sizeof(struct ItemSlot)); + Free(newItems); + return TRUE; + } +} + +bool8 RemoveBagItem(u16 itemId, u16 count) +{ + u8 i; + u16 totalQuantity = 0; + + if (ItemId_GetPocket(itemId) == POCKET_NONE || itemId == ITEM_NONE) + return FALSE; + + // check Battle Pyramid Bag + if (InBattlePyramid() || FlagGet(FLAG_SPECIAL_FLAG_0x4004) == TRUE) + { + return RemovePyramidBagItem(itemId, count); + } + else + { + u8 pocket; + u8 var; + u16 ownedCount; + struct BagPocket *itemPocket; + + pocket = ItemId_GetPocket(itemId) - 1; + itemPocket = &gBagPockets[pocket]; + + for (i = 0; i < itemPocket->capacity; i++) + { + if (itemPocket->itemSlots[i].itemId == itemId) + totalQuantity += GetBagItemQuantity(&itemPocket->itemSlots[i].quantity); + } + + if (totalQuantity < count) + return FALSE; // We don't have enough of the item + + if (CurrentMapIsSecretBase() == TRUE) + { + VarSet(VAR_0x40EE, VarGet(VAR_0x40EE) | 0x200); + VarSet(VAR_0x40ED, itemId); + } + + var = sub_81ABB2C(pocket); + if (itemPocket->capacity > var + && itemPocket->itemSlots[var].itemId == itemId) + { + ownedCount = GetBagItemQuantity(&itemPocket->itemSlots[var].quantity); + if (ownedCount >= count) + { + SetBagItemQuantity(&itemPocket->itemSlots[var].quantity, ownedCount - count); + count = 0; + } + else + { + count -= ownedCount; + SetBagItemQuantity(&itemPocket->itemSlots[var].quantity, 0); + } + + if (GetBagItemQuantity(&itemPocket->itemSlots[var].quantity) == 0) + itemPocket->itemSlots[var].itemId = ITEM_NONE; + if (count == 0) return TRUE; } + + for (i = 0; i < itemPocket->capacity; i++) + { + if (itemPocket->itemSlots[i].itemId == itemId) + { + ownedCount = GetBagItemQuantity(&itemPocket->itemSlots[i].quantity); + if (ownedCount >= count) + { + SetBagItemQuantity(&itemPocket->itemSlots[i].quantity, ownedCount - count); + count = 0; + } + else + { + count -= ownedCount; + SetBagItemQuantity(&itemPocket->itemSlots[i].quantity, 0); + } + + if (GetBagItemQuantity(&itemPocket->itemSlots[i].quantity) == 0) + itemPocket->itemSlots[i].itemId = ITEM_NONE; + + if (count == 0) + return TRUE; + } + } + return TRUE; } +} - //Check space in empty item slots - if (count > 0) +u8 GetPocketByItemId(u16 itemId) +{ + return ItemId_GetPocket(itemId); +} + +void ClearItemSlots(struct ItemSlot *itemSlots, u8 itemCount) +{ + u16 i; + + for (i = 0; i < itemCount; i++) { - for (i = 0; i < gBagPockets[pocket].capacity; i++) + itemSlots[i].itemId = ITEM_NONE; + SetBagItemQuantity(&itemSlots[i].quantity, 0); + } +} + +static s32 FindFreePCItemSlot(void) +{ + s8 i; + + for (i = 0; i < PC_ITEMS_COUNT; i++) + { + if (gSaveBlock1Ptr->pcItems[i].itemId == ITEM_NONE) + return i; + } + return -1; +} + +u8 CountUsedPCItemSlots(void) +{ + u8 usedSlots = 0; + u8 i; + + for (i = 0; i < PC_ITEMS_COUNT; i++) + { + if (gSaveBlock1Ptr->pcItems[i].itemId != ITEM_NONE) + usedSlots++; + } + return usedSlots; +} + +bool8 CheckPCHasItem(u16 itemId, u16 count) +{ + u8 i; + + for (i = 0; i < PC_ITEMS_COUNT; i++) + { + if (gSaveBlock1Ptr->pcItems[i].itemId == itemId && GetPCItemQuantity(&gSaveBlock1Ptr->pcItems[i].quantity) >= count) + return TRUE; + } + return FALSE; +} + +bool8 AddPCItem(u16 itemId, u16 count) +{ + u8 i; + s8 freeSlot; + u16 ownedCount; + struct ItemSlot *newItems; + + // Copy PC items + newItems = AllocZeroed(sizeof(gSaveBlock1Ptr->pcItems)); + memcpy(newItems, gSaveBlock1Ptr->pcItems, sizeof(gSaveBlock1Ptr->pcItems)); + + // Use any item slots that already contain this item + for (i = 0; i < PC_ITEMS_COUNT; i++) + { + if (newItems[i].itemId == itemId) { - if (gBagPockets[pocket].itemSlots[i].itemId == 0) + ownedCount = GetPCItemQuantity(&newItems[i].quantity); + if (ownedCount + count <= 999) { - if (count <= slotCapacity) - return TRUE; - if (pocket == TMHM_POCKET || pocket == BERRIES_POCKET) - return FALSE; - count -= slotCapacity; + SetPCItemQuantity(&newItems[i].quantity, ownedCount + count); + memcpy(gSaveBlock1Ptr->pcItems, newItems, sizeof(gSaveBlock1Ptr->pcItems)); + Free(newItems); + return TRUE; + } + count += ownedCount - 999; + SetPCItemQuantity(&newItems[i].quantity, 999); + if (count == 0) + { + memcpy(gSaveBlock1Ptr->pcItems, newItems, sizeof(gSaveBlock1Ptr->pcItems)); + Free(newItems); + return TRUE; } } - if (count > 0) - return FALSE; //No more item slots. The bag is full } + // Put any remaining items into a new item slot. + if (count > 0) + { + freeSlot = FindFreePCItemSlot(); + if (freeSlot == -1) + { + Free(newItems); + return FALSE; + } + else + { + newItems[freeSlot].itemId = itemId; + SetPCItemQuantity(&newItems[freeSlot].quantity, count); + } + } + + // Copy items back to the PC + memcpy(gSaveBlock1Ptr->pcItems, newItems, sizeof(gSaveBlock1Ptr->pcItems)); + Free(newItems); return TRUE; -}*/ +} + +void RemovePCItem(u8 index, u16 count) +{ + // UB: should use GetPCItemQuantity and SetPCItemQuantity functions + gSaveBlock1Ptr->pcItems[index].quantity -= count; + if (gSaveBlock1Ptr->pcItems[index].quantity == 0) + { + gSaveBlock1Ptr->pcItems[index].itemId = ITEM_NONE; + CompactPCItems(); + } +} + +void CompactPCItems(void) +{ + u16 i; + u16 j; + + for (i = 0; i < PC_ITEMS_COUNT - 1; i++) + { + for (j = i + 1; j < PC_ITEMS_COUNT; j++) + { + if (gSaveBlock1Ptr->pcItems[i].itemId == 0) + { + struct ItemSlot temp = gSaveBlock1Ptr->pcItems[i]; + gSaveBlock1Ptr->pcItems[i] = gSaveBlock1Ptr->pcItems[j]; + gSaveBlock1Ptr->pcItems[j] = temp; + } + } + } +} + +void SwapRegisteredBike(void) +{ + switch (gSaveBlock1Ptr->registeredItem) + { + case ITEM_MACH_BIKE: + gSaveBlock1Ptr->registeredItem = ITEM_ACRO_BIKE; + break; + case ITEM_ACRO_BIKE: + gSaveBlock1Ptr->registeredItem = ITEM_MACH_BIKE; + break; + } +} + +u16 BagGetItemIdByPocketPosition(u8 pocketId, u16 pocketPos) +{ + return gBagPockets[pocketId - 1].itemSlots[pocketPos].itemId; +} + +u16 BagGetQuantityByPocketPosition(u8 pocketId, u16 pocketPos) +{ + return GetBagItemQuantity(&gBagPockets[pocketId - 1].itemSlots[pocketPos].quantity); +} + +static void SwapItemSlots(struct ItemSlot *a, struct ItemSlot *b) +{ + struct ItemSlot temp = *a; + *a = *b; + *b = temp; +} + +void CompactItemsInBagPocket(struct BagPocket *bagPocket) +{ + u16 i, j; + + for (i = 0; i < bagPocket->capacity - 1; i++) + { + for (j = i + 1; j < bagPocket->capacity; j++) + { + if (GetBagItemQuantity(&bagPocket->itemSlots[i].quantity) == 0) + SwapItemSlots(&bagPocket->itemSlots[i], &bagPocket->itemSlots[j]); + } + } +} + +void SortBerriesOrTMHMs(struct BagPocket *bagPocket) +{ + u16 i, j; + + for (i = 0; i < bagPocket->capacity - 1; i++) + { + for (j = i + 1; j < bagPocket->capacity; j++) + { + if (GetBagItemQuantity(&bagPocket->itemSlots[i].quantity) != 0) + { + if (GetBagItemQuantity(&bagPocket->itemSlots[j].quantity) == 0) + continue; + if (bagPocket->itemSlots[i].itemId <= bagPocket->itemSlots[j].itemId) + continue; + } + SwapItemSlots(&bagPocket->itemSlots[i], &bagPocket->itemSlots[j]); + } + } +} + +void MoveItemSlotInList(struct ItemSlot* itemSlots_, u32 from, u32 to_) +{ + // dumb assignments needed to match + struct ItemSlot *itemSlots = itemSlots_; + u32 to = to_; + + if (from != to) + { + s16 i, count; + struct ItemSlot firstSlot = itemSlots[from]; + + if (to > from) + { + to--; + for (i = from, count = to; i < count; i++) + itemSlots[i] = itemSlots[i + 1]; + } + else + { + for (i = from, count = to; i > count; i--) + itemSlots[i] = itemSlots[i - 1]; + } + itemSlots[to] = firstSlot; + } +} + +void ClearBag(void) +{ + u16 i; + + for (i = 0; i < POCKETS_COUNT; i++) + { + ClearItemSlots(gBagPockets[i].itemSlots, gBagPockets[i].capacity); + } +} + +u16 CountTotalItemQuantityInBag(u16 itemId) +{ + u16 i; + u16 ownedCount = 0; + struct BagPocket *bagPocket = &gBagPockets[ItemId_GetPocket(itemId) - 1]; + + for (i = 0; i < bagPocket->capacity; i++) + { + if (bagPocket->itemSlots[i].itemId == itemId) + ownedCount += GetBagItemQuantity(&bagPocket->itemSlots[i].quantity); + } + + return ownedCount; +} + +static bool8 CheckPyramidBagHasItem(u16 itemId, u16 count) +{ + u8 i; + u16 *items = gSaveBlock2Ptr->pyramidBag.itemId[gSaveBlock2Ptr->frontierChosenLvl]; + u8 *quantities = gSaveBlock2Ptr->pyramidBag.quantity[gSaveBlock2Ptr->frontierChosenLvl]; + + for (i = 0; i < PYRAMID_BAG_ITEMS_COUNT; i++) + { + if (items[i] == itemId) + { + if (quantities[i] >= count) + return TRUE; + + count -= quantities[i]; + if (count == 0) + return TRUE; + } + } + + return FALSE; +} + +static bool8 CheckPyramidBagHasSpace(u16 itemId, u16 count) +{ + u8 i; + u16 *items = gSaveBlock2Ptr->pyramidBag.itemId[gSaveBlock2Ptr->frontierChosenLvl]; + u8 *quantities = gSaveBlock2Ptr->pyramidBag.quantity[gSaveBlock2Ptr->frontierChosenLvl]; + + for (i = 0; i < PYRAMID_BAG_ITEMS_COUNT; i++) + { + if (items[i] == itemId || items[i] == ITEM_NONE) + { + if (quantities[i] + count <= 99) + return TRUE; + + count = (quantities[i] + count) - 99; + if (count == 0) + return TRUE; + } + } + + return FALSE; +} + +static bool8 AddPyramidBagItem(u16 itemId, u16 count) +{ + u16 i; + + u16 *items = gSaveBlock2Ptr->pyramidBag.itemId[gSaveBlock2Ptr->frontierChosenLvl]; + u8 *quantities = gSaveBlock2Ptr->pyramidBag.quantity[gSaveBlock2Ptr->frontierChosenLvl]; + + u16 *newItems = Alloc(PYRAMID_BAG_ITEMS_COUNT * sizeof(u16)); + u8 *newQuantities = Alloc(PYRAMID_BAG_ITEMS_COUNT * sizeof(u8)); + + memcpy(newItems, items, PYRAMID_BAG_ITEMS_COUNT * sizeof(u16)); + memcpy(newQuantities, quantities, PYRAMID_BAG_ITEMS_COUNT * sizeof(u8)); + + for (i = 0; i < PYRAMID_BAG_ITEMS_COUNT; i++) + { + if (newItems[i] == itemId && newQuantities[i] < 99) + { + newQuantities[i] += count; + if (newQuantities[i] > 99) + { + count = newQuantities[i] - 99; + newQuantities[i] = 99; + } + else + { + count = 0; + } + + if (count == 0) + break; + } + } + + if (count > 0) + { + for (i = 0; i < PYRAMID_BAG_ITEMS_COUNT; i++) + { + if (newItems[i] == ITEM_NONE) + { + newItems[i] = itemId; + newQuantities[i] = count; + if (newQuantities[i] > 99) + { + count = newQuantities[i] - 99; + newQuantities[i] = 99; + } + else + { + count = 0; + } + + if (count == 0) + break; + } + } + } + + if (count == 0) + { + memcpy(items, newItems, PYRAMID_BAG_ITEMS_COUNT * sizeof(u16)); + memcpy(quantities, newQuantities, PYRAMID_BAG_ITEMS_COUNT * sizeof(u8)); + Free(newItems); + Free(newQuantities); + return TRUE; + } + else + { + Free(newItems); + Free(newQuantities); + return FALSE; + } +} + +extern u16 gUnknown_0203CF30[]; + +static bool8 RemovePyramidBagItem(u16 itemId, u16 count) +{ + u16 i; + + u16 *items = gSaveBlock2Ptr->pyramidBag.itemId[gSaveBlock2Ptr->frontierChosenLvl]; + u8 *quantities = gSaveBlock2Ptr->pyramidBag.quantity[gSaveBlock2Ptr->frontierChosenLvl]; + + i = gUnknown_0203CF30[3] + gUnknown_0203CF30[4]; + if (items[i] == itemId && quantities[i] >= count) + { + quantities[i] -= count; + if (quantities[i] == 0) + items[i] = ITEM_NONE; + return TRUE; + } + else + { + u16 *newItems = Alloc(PYRAMID_BAG_ITEMS_COUNT * sizeof(u16)); + u8 *newQuantities = Alloc(PYRAMID_BAG_ITEMS_COUNT * sizeof(u8)); + + memcpy(newItems, items, PYRAMID_BAG_ITEMS_COUNT * sizeof(u16)); + memcpy(newQuantities, quantities, PYRAMID_BAG_ITEMS_COUNT * sizeof(u8)); + + for (i = 0; i < PYRAMID_BAG_ITEMS_COUNT; i++) + { + if (newItems[i] == itemId) + { + if (newQuantities[i] >= count) + { + newQuantities[i] -= count; + count = 0; + if (newQuantities[i] == 0) + newItems[i] = ITEM_NONE; + } + else + { + count -= newQuantities[i]; + newQuantities[i] = 0; + newItems[i] = ITEM_NONE; + } + + if (count == 0) + break; + } + } + + if (count == 0) + { + memcpy(items, newItems, PYRAMID_BAG_ITEMS_COUNT * sizeof(u16)); + memcpy(quantities, newQuantities, PYRAMID_BAG_ITEMS_COUNT * sizeof(u8)); + Free(newItems); + Free(newQuantities); + return TRUE; + } + else + { + Free(newItems); + Free(newQuantities); + return FALSE; + } + } +} + +static u16 SanitizeItemId(u16 itemId) +{ + if (itemId >= ITEM_LAST_ID + 1) + return ITEM_NONE; + else + return itemId; +} + +const u8 *ItemId_GetName(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].name; +} + +u16 ItemId_GetId(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].itemId; +} + +u16 ItemId_GetPrice(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].price; +} + +u8 ItemId_GetHoldEffect(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].holdEffect; +} + +u8 ItemId_GetHoldEffectParam(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].holdEffectParam; +} + +const u8 *ItemId_GetDescription(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].description; +} + + +u8 ItemId_GetImportance(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].importance; +} + +// unused +u8 ItemId_GetUnknownValue(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].unk19; +} + +u8 ItemId_GetPocket(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].pocket; +} + +u8 ItemId_GetType(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].type; +} + +ItemUseFunc ItemId_GetFieldFunc(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].fieldUseFunc; +} + +u8 ItemId_GetBattleUsage(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].battleUsage; +} + +ItemUseFunc ItemId_GetBattleFunc(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].battleUseFunc; +} + +u8 ItemId_GetSecondaryId(u16 itemId) +{ + return gItems[SanitizeItemId(itemId)].secondaryId; +} diff --git a/src/item_menu.c b/src/item_menu.c index 8c05f0828..d7edea301 100755 --- a/src/item_menu.c +++ b/src/item_menu.c @@ -72,7 +72,7 @@ void AddBagItemIconSprite(u16, u8); void bag_menu_print_description_box_text(int); void bag_menu_print_cursor(u8, u8); void bag_menu_print(u8, u8, const u8*, u8, u8, u8, u8, u8, u8); -bool8 itemid_is_unique(u16); +bool8 ItemId_GetImportance(u16); u16 BagGetQuantityByPocketPosition(u8, u16); void sub_81AB89C(void); void task_close_bag_menu_2(u8); @@ -687,7 +687,7 @@ void sub_81AB520(u8 rboxId, int item_index_in_pocket, u8 a) offset = GetStringRightAlignXOffset(7, gStringVar4, 0x77); bag_menu_print(rboxId, 7, gStringVar4, offset, a, 0, 0, -1, 0); } - else if (gUnknown_0203CE58.pocket != 4 && (unique = itemid_is_unique(itemId)) == FALSE) + else if (gUnknown_0203CE58.pocket != 4 && (unique = ItemId_GetImportance(itemId)) == FALSE) { ConvertIntToDecimalStringN(gStringVar1, itemQuantity, 1, 2); StringExpandPlaceholders(gStringVar4, gText_xVar1); @@ -804,10 +804,10 @@ void sub_81AB9A8(u8 pocketId) { case 2: case 3: - sub_80D6FB4(pocket); + SortBerriesOrTMHMs(pocket); break; default: - sub_80D6F64(pocket); + CompactItemsInBagPocket(pocket); break; } gUnknown_0203CE54->unk829[pocketId] = 0; @@ -847,9 +847,9 @@ void sub_81ABAE0(void) sub_8122298(&gUnknown_0203CE58.scrollPosition[i], &gUnknown_0203CE58.cursorPosition[i], gUnknown_0203CE54->unk82E[i], gUnknown_0203CE54->unk829[i], 8); } -u8 sub_81ABB2C(u8 a) +u8 sub_81ABB2C(u8 pocketId) { - return gUnknown_0203CE58.scrollPosition[a] + gUnknown_0203CE58.cursorPosition[a]; + return gUnknown_0203CE58.scrollPosition[pocketId] + gUnknown_0203CE58.cursorPosition[pocketId]; } void DisplayItemMessage(u8 taskId, u8 fontId, const u8 *str, void ( *callback)(u8 taskId)) @@ -1179,7 +1179,7 @@ void sub_81AC498(u8 taskId) sub_81AC590(taskId); else { - sub_80D702C(gBagPockets[gUnknown_0203CE58.pocket].itemSlots, data[1], realPos); + MoveItemSlotInList(gBagPockets[gUnknown_0203CE58.pocket].itemSlots, data[1], realPos); gUnknown_0203CE54->unk81A = -1; DestroyListMenuTask(data[0], scrollPos, cursorPos); if (data[1] < realPos) @@ -1231,7 +1231,7 @@ void sub_81AC644(u8 unused) gUnknown_0203CE54->unk828 = 4; break; case 8: - if (!itemid_is_unique(gSpecialVar_ItemId) && gSpecialVar_ItemId != ITEM_ENIGMA_BERRY) + if (!ItemId_GetImportance(gSpecialVar_ItemId) && gSpecialVar_ItemId != ITEM_ENIGMA_BERRY) { gUnknown_0203CE54->unk820 = gUnknown_0861404B; gUnknown_0203CE54->unk828 = 2; @@ -1243,7 +1243,7 @@ void sub_81AC644(u8 unused) } break; case 6: - if (!itemid_is_unique(gSpecialVar_ItemId) && gSpecialVar_ItemId != ITEM_ENIGMA_BERRY) + if (!ItemId_GetImportance(gSpecialVar_ItemId) && gSpecialVar_ItemId != ITEM_ENIGMA_BERRY) { gUnknown_0203CE54->unk820 = gUnknown_0861404D; gUnknown_0203CE54->unk828 = 2; @@ -1255,7 +1255,7 @@ void sub_81AC644(u8 unused) } break; case 7: - if (!itemid_is_unique(gSpecialVar_ItemId) && gSpecialVar_ItemId != ITEM_ENIGMA_BERRY) + if (!ItemId_GetImportance(gSpecialVar_ItemId) && gSpecialVar_ItemId != ITEM_ENIGMA_BERRY) { gUnknown_0203CE54->unk820 = gUnknown_0861404F; gUnknown_0203CE54->unk828 = 2; @@ -1605,7 +1605,7 @@ void ItemMenu_Give(u8 taskId) { DisplayItemMessage(taskId, 1, gText_CantWriteMail, sub_81AD350); } - else if (!itemid_is_unique(gSpecialVar_ItemId)) + else if (!ItemId_GetImportance(gSpecialVar_ItemId)) { if (CalculatePlayerPartyCount() == 0) bag_menu_print_there_is_no_pokemon(taskId); @@ -1686,7 +1686,7 @@ void item_menu_type_2(u8 taskId) StringExpandPlaceholders(gStringVar4, gText_Var1CantBeHeldHere); DisplayItemMessage(taskId, 1, gStringVar4, sub_81AD350); } - else if (gUnknown_0203CE58.pocket != 4 && !itemid_is_unique(gSpecialVar_ItemId)) + else if (gUnknown_0203CE58.pocket != 4 && !ItemId_GetImportance(gSpecialVar_ItemId)) { unknown_ItemMenu_Confirm(taskId); } @@ -1700,7 +1700,7 @@ void item_menu_type_b(u8 taskId) { if (ItemIsMail(gSpecialVar_ItemId) == TRUE) DisplayItemMessage(taskId, 1, gText_CantWriteMail, sub_81AD350); - else if (gUnknown_0203CE58.pocket != 4 && !itemid_is_unique(gSpecialVar_ItemId)) + else if (gUnknown_0203CE58.pocket != 4 && !ItemId_GetImportance(gSpecialVar_ItemId)) gTasks[taskId].func = unknown_ItemMenu_Confirm; else bag_menu_print_cant_be_held_msg(taskId); @@ -1738,7 +1738,7 @@ void display_sell_item_ask_str(u8 taskId) { s16* data = gTasks[taskId].data; - if (itemid_get_market_price(gSpecialVar_ItemId) == 0) + if (ItemId_GetPrice(gSpecialVar_ItemId) == 0) { CopyItemName(gSpecialVar_ItemId, gStringVar2); StringExpandPlaceholders(gStringVar4, gText_CantBuyKeyItem); @@ -1765,7 +1765,7 @@ void sub_81AD680(u8 taskId) { s16* data = gTasks[taskId].data; - ConvertIntToDecimalStringN(gStringVar1, (itemid_get_market_price(gSpecialVar_ItemId) / 2) * data[8], 0, 6); + ConvertIntToDecimalStringN(gStringVar1, (ItemId_GetPrice(gSpecialVar_ItemId) / 2) * data[8], 0, 6); StringExpandPlaceholders(gStringVar4, gText_ICanPayVar1); DisplayItemMessage(taskId, 1, gStringVar4, sub_81AD6E4); } @@ -1790,7 +1790,7 @@ void sub_81AD730(u8 taskId) s16* data = gTasks[taskId].data; u8 windowId = bag_menu_add_window(8); - sub_81ABCC0(windowId, 1, (itemid_get_market_price(gSpecialVar_ItemId) / 2) * data[8]); + sub_81ABCC0(windowId, 1, (ItemId_GetPrice(gSpecialVar_ItemId) / 2) * data[8]); bag_menu_AddMoney_window(); gTasks[taskId].func = sub_81AD794; } @@ -1801,7 +1801,7 @@ void sub_81AD794(u8 taskId) if (AdjustQuantityAccordingToDPadInput(&data[8], data[2]) == TRUE) { - sub_81ABCC0(gUnknown_0203CE54->unk818, data[8], (itemid_get_market_price(gSpecialVar_ItemId) / 2) * data[8]); + sub_81ABCC0(gUnknown_0203CE54->unk818, data[8], (ItemId_GetPrice(gSpecialVar_ItemId) / 2) * data[8]); } else if (gMain.newKeys & A_BUTTON) { @@ -1825,7 +1825,7 @@ void sub_81AD84C(u8 taskId) s16* data = gTasks[taskId].data; CopyItemName(gSpecialVar_ItemId, gStringVar2); - ConvertIntToDecimalStringN(gStringVar1, (itemid_get_market_price(gSpecialVar_ItemId) / 2) * data[8], 0, 6); + ConvertIntToDecimalStringN(gStringVar1, (ItemId_GetPrice(gSpecialVar_ItemId) / 2) * data[8], 0, 6); StringExpandPlaceholders(gStringVar4, gText_TurnedOverVar1ForVar2); DisplayItemMessage(taskId, 1, gStringVar4, sub_81AD8C8); } @@ -1838,7 +1838,7 @@ void sub_81AD8C8(u8 taskId) PlaySE(SE_REGI); RemoveBagItem(gSpecialVar_ItemId, data[8]); - AddMoney(&gSaveBlock1Ptr->money, (itemid_get_market_price(gSpecialVar_ItemId) / 2) * data[8]); + AddMoney(&gSaveBlock1Ptr->money, (ItemId_GetPrice(gSpecialVar_ItemId) / 2) * data[8]); DestroyListMenuTask(data[0], scrollPos, cursorPos); sub_81AB9A8(gUnknown_0203CE58.pocket); sub_81ABA88(gUnknown_0203CE58.pocket); @@ -1908,7 +1908,7 @@ void sub_81ADB14(u8 taskId) s16* data = gTasks[taskId].data; FillWindowPixelBuffer(1, 0); - if (itemid_is_unique(gSpecialVar_ItemId)) + if (ItemId_GetImportance(gSpecialVar_ItemId)) { bag_menu_print(1, 1, gText_CantStoreImportantItems, 3, 1, 0, 0, 0, 0); gTasks[taskId].func = sub_81ADC0C; diff --git a/src/lilycove_lady.c b/src/lilycove_lady.c index 812f1f975..ea244b6a0 100644 --- a/src/lilycove_lady.c +++ b/src/lilycove_lady.c @@ -392,7 +392,7 @@ bool8 sub_818DC60(void) static void sub_818DCAC(u8 *dest, u16 itemId) { - StringCopy(dest, ItemId_GetItem(itemId)->name); + StringCopy(dest, ItemId_GetName(itemId)); } void sub_818DCC8(void) @@ -671,7 +671,7 @@ static u8 sub_818E258(const u8 *str) void sub_818E274(void) { - StringCopy(gStringVar1, ItemId_GetItem(gUnknown_0203CD68->itemId)->name); + StringCopy(gStringVar1, ItemId_GetName(gUnknown_0203CD68->itemId)); } bool8 sub_818E298(void) diff --git a/src/player_pc.c b/src/player_pc.c index f56ecb128..6f39fa449 100644 --- a/src/player_pc.c +++ b/src/player_pc.c @@ -444,7 +444,7 @@ static void ItemStorage_Withdraw(u8 taskId) { s16 *data = gTasks[taskId].data; - NUM_ITEMS = sub_80D6CE4(); + NUM_ITEMS = CountUsedPCItemSlots(); if (NUM_ITEMS != 0) ItemStorage_WithdrawToss_Helper(taskId, FALSE); else @@ -459,7 +459,7 @@ static void ItemStorage_Toss(u8 taskId) { s16 *data = gTasks[taskId].data; - NUM_ITEMS = sub_80D6CE4(); + NUM_ITEMS = CountUsedPCItemSlots(); if (NUM_ITEMS != 0) ItemStorage_WithdrawToss_Helper(taskId, TRUE); else @@ -967,7 +967,7 @@ static void sub_816C0C8(void) static void sub_816C110(void) { - sub_80D6E84(); + CompactPCItems(); sub_812220C(gSaveBlock1Ptr->pcItems, 50, &(playerPCItemPageInfo.pageItems), &(playerPCItemPageInfo.count), 0x8); } @@ -1180,7 +1180,7 @@ static void ItemStorage_DoItemSwap(u8 taskId, bool8 a) { if(c != b - 1) { - sub_80D702C(gSaveBlock1Ptr->pcItems, c, b); + MoveItemSlotInList(gSaveBlock1Ptr->pcItems, c, b); ItemStorage_RefreshListMenu(); } } @@ -1301,7 +1301,7 @@ static void ItemStorage_DoItemToss(u8 taskId) data = gTasks[taskId].data; b = (playerPCItemPageInfo.cursorPos + playerPCItemPageInfo.itemsAbove); - if(!itemid_is_unique(gSaveBlock1Ptr->pcItems[b].itemId)) + if(!ItemId_GetImportance(gSaveBlock1Ptr->pcItems[b].itemId)) { CopyItemName(gSaveBlock1Ptr->pcItems[b].itemId, gStringVar1); ConvertIntToDecimalStringN(gStringVar2, data[2], STR_CONV_MODE_LEFT_ALIGN, 3); @@ -1335,7 +1335,7 @@ static void ItemStorage_HandleRemoveItem(u8 taskId) data = gTasks[taskId].data; if(gMain.newKeys & (A_BUTTON | B_BUTTON)) { - sub_80D6E48((playerPCItemPageInfo.cursorPos + playerPCItemPageInfo.itemsAbove), data[2]); + RemovePCItem((playerPCItemPageInfo.cursorPos + playerPCItemPageInfo.itemsAbove), data[2]); DestroyListMenuTask(data[5], &(playerPCItemPageInfo.itemsAbove), &(playerPCItemPageInfo.cursorPos)); sub_816C110(); sub_816C140(); diff --git a/src/pokeblock.c b/src/pokeblock.c index e829452b2..60087b5bf 100644 --- a/src/pokeblock.c +++ b/src/pokeblock.c @@ -589,7 +589,7 @@ static void PutPokeblockInfoText(void) { u8 i; - const u8 *itemName = ItemId_GetItem(ITEM_POKEBLOCK_CASE)->name; + const u8 *itemName = ItemId_GetName(ITEM_POKEBLOCK_CASE); PrintOnPokeblockWindow(0, itemName, GetStringCenterAlignXOffset(1, itemName, 0x48)); PrintOnPokeblockWindow(2, gText_Spicy, 0); diff --git a/src/pokemon_summary_screen.c b/src/pokemon_summary_screen.c index e7fcce629..f77b7c38c 100644 --- a/src/pokemon_summary_screen.c +++ b/src/pokemon_summary_screen.c @@ -3173,11 +3173,11 @@ void sub_81C3554(u8 taskId) void sub_81C35E4() { - u8 *text; + const u8 *text; int offset; if (gUnknown_0203CF1C->summary.item == ITEM_ENIGMA_BERRY && sub_81B1250() == 1 && (gUnknown_0203CF1C->unk40BE == 1 || gUnknown_0203CF1C->unk40BE == 4 || gUnknown_0203CF1C->unk40BE == 5)) { - text = (u8*)ItemId_GetItem(ITEM_ENIGMA_BERRY); + text = ItemId_GetName(ITEM_ENIGMA_BERRY); } else if (gUnknown_0203CF1C->summary.item == ITEM_NONE) text = gText_None; diff --git a/src/tv.c b/src/tv.c index b7c2812fe..21b81347c 100644 --- a/src/tv.c +++ b/src/tv.c @@ -2945,7 +2945,7 @@ static void sub_80EF40C(u8 varIdx, TVShow *show) { if (show->smartshopperShow.itemIds[i] != ITEM_NONE) { - price += itemid_get_market_price(show->smartshopperShow.itemIds[i]) * show->smartshopperShow.itemAmounts[i]; + price += ItemId_GetPrice(show->smartshopperShow.itemIds[i]) * show->smartshopperShow.itemAmounts[i]; } } if (show->smartshopperShow.priceReduced == TRUE) @@ -5120,7 +5120,7 @@ static void DoTVShowTodaysSmartShopper(void) break; case 1: TVShowConvertInternationalString(gStringVar1, show->smartshopperShow.playerName, show->smartshopperShow.language); - StringCopy(gStringVar2, ItemId_GetItem(show->smartshopperShow.itemIds[0])->name); + StringCopy(gStringVar2, ItemId_GetName(show->smartshopperShow.itemIds[0])); TV_PrintIntToStringVar(2, show->smartshopperShow.itemAmounts[0]); sTVShowState += 1 + (Random() % 4); break; @@ -5148,7 +5148,7 @@ static void DoTVShowTodaysSmartShopper(void) } break; case 6: - StringCopy(gStringVar2, ItemId_GetItem(show->smartshopperShow.itemIds[1])->name); + StringCopy(gStringVar2, ItemId_GetName(show->smartshopperShow.itemIds[1])); TV_PrintIntToStringVar(2, show->smartshopperShow.itemAmounts[1]); if (show->smartshopperShow.itemIds[2] != ITEM_NONE) { @@ -5164,7 +5164,7 @@ static void DoTVShowTodaysSmartShopper(void) } break; case 7: - StringCopy(gStringVar2, ItemId_GetItem(show->smartshopperShow.itemIds[2])->name); + StringCopy(gStringVar2, ItemId_GetName(show->smartshopperShow.itemIds[2])); TV_PrintIntToStringVar(2, show->smartshopperShow.itemAmounts[2]); if (show->smartshopperShow.priceReduced == TRUE) { @@ -5201,7 +5201,7 @@ static void DoTVShowTodaysSmartShopper(void) break; case 11: TVShowConvertInternationalString(gStringVar1, show->smartshopperShow.playerName, show->smartshopperShow.language); - StringCopy(gStringVar2, ItemId_GetItem(show->smartshopperShow.itemIds[0])->name); + StringCopy(gStringVar2, ItemId_GetName(show->smartshopperShow.itemIds[0])); if (show->smartshopperShow.priceReduced == TRUE) { sTVShowState = 8; @@ -5344,7 +5344,7 @@ static void DoTVShowPokemonTodaySuccessfulCapture(void) sTVShowState = 2; break; case 2: - StringCopy(gStringVar2, ItemId_GetItem(show->pokemonToday.ball)->name); + StringCopy(gStringVar2, ItemId_GetName(show->pokemonToday.ball)); TV_PrintIntToStringVar(2, show->pokemonToday.nBallsUsed); if (show->pokemonToday.nBallsUsed < 4) { @@ -6457,7 +6457,7 @@ static void DoTVShowHoennTreasureInvestigators(void) switch (state) { case 0: - StringCopy(gStringVar1, ItemId_GetItem(show->treasureInvestigators.item)->name); + StringCopy(gStringVar1, ItemId_GetName(show->treasureInvestigators.item)); if (show->treasureInvestigators.location == MAPSEC_DYNAMIC) { switch (show->treasureInvestigators.mapDataId) @@ -6476,13 +6476,13 @@ static void DoTVShowHoennTreasureInvestigators(void) } break; case 1: - StringCopy(gStringVar1, ItemId_GetItem(show->treasureInvestigators.item)->name); + StringCopy(gStringVar1, ItemId_GetName(show->treasureInvestigators.item)); TVShowConvertInternationalString(gStringVar2, show->treasureInvestigators.playerName, show->treasureInvestigators.language); GetMapName(gStringVar3, show->treasureInvestigators.location, 0); TVShowDone(); break; case 2: - StringCopy(gStringVar1, ItemId_GetItem(show->treasureInvestigators.item)->name); + StringCopy(gStringVar1, ItemId_GetName(show->treasureInvestigators.item)); TVShowConvertInternationalString(gStringVar2, show->treasureInvestigators.playerName, show->treasureInvestigators.language); TVShowDone(); break; @@ -6598,7 +6598,7 @@ static void DoTVShowBreakingNewsTV(void) break; case 3: TV_PrintIntToStringVar(0, show->breakingNews.balls); - StringCopy(gStringVar2, ItemId_GetItem(show->breakingNews.caughtMonBall)->name); + StringCopy(gStringVar2, ItemId_GetName(show->breakingNews.caughtMonBall)); sTVShowState = 4; break; case 4: @@ -6788,7 +6788,7 @@ static void DoTVShowPokemonLotteryWinnerFlashReport(void) { StringCopy(gStringVar2, gText_Third); } - StringCopy(gStringVar3, ItemId_GetItem(show->lottoWinner.item)->name); + StringCopy(gStringVar3, ItemId_GetName(show->lottoWinner.item)); TVShowDone(); ShowFieldMessage(sTVPokemonLotteryWinnerFlashReportTextGroup[state]); } @@ -7530,7 +7530,7 @@ static void DoTVShowSecretBaseSecrets(void) sTVShowState = show->secretBaseSecrets.savedState; break; case 19: - StringCopy(gStringVar2, ItemId_GetItem(show->secretBaseSecrets.item)->name); + StringCopy(gStringVar2, ItemId_GetName(show->secretBaseSecrets.item)); sTVShowState = show->secretBaseSecrets.savedState; break; case 20: -- cgit v1.2.3 From fd40e93cb5fe4eb43551ae1a8f584e86bcc7ecf1 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 29 Apr 2018 14:21:59 +0200 Subject: clear item, save and load save files --- src/item.c | 49 +++++++++++++++------------------- src/load_save.c | 83 +++++++++++++++++++++++++++++---------------------------- src/random.c | 4 +++ src/save.c | 31 +++++++-------------- 4 files changed, 77 insertions(+), 90 deletions(-) (limited to 'src') diff --git a/src/item.c b/src/item.c index a6e89a8e5..01166f5d6 100644 --- a/src/item.c +++ b/src/item.c @@ -8,6 +8,8 @@ #include "malloc.h" #include "secret_base.h" #include "item_menu.h" +#include "strings.h" +#include "load_save.h" // These constants are used in gItems enum @@ -20,40 +22,34 @@ enum POCKET_KEY_ITEMS, }; -extern void ApplyNewEncryptionKeyToHword(u16 *hword, u32 newKey); extern bool8 InBattlePyramid(void); - -extern const u8 gText_PokeBalls[]; -extern const u8 gText_Berries[]; -extern const u8 gText_Berry[]; - +extern u16 gUnknown_0203CF30[]; extern const struct Item gItems[]; // this file's functions - static bool8 CheckPyramidBagHasItem(u16 itemId, u16 count); static bool8 CheckPyramidBagHasSpace(u16 itemId, u16 count); -static bool8 AddPyramidBagItem(u16 itemId, u16 count); -static bool8 RemovePyramidBagItem(u16 itemId, u16 count); -// code +// EWRAM variables +EWRAM_DATA struct BagPocket gBagPockets[POCKETS_COUNT] = {0}; -u16 GetBagItemQuantity(u16 *quantity) +// code +static u16 GetBagItemQuantity(u16 *quantity) { return gSaveBlock2Ptr->encryptionKey ^ *quantity; } -void SetBagItemQuantity(u16 *quantity, u16 newValue) +static void SetBagItemQuantity(u16 *quantity, u16 newValue) { *quantity = newValue ^ gSaveBlock2Ptr->encryptionKey; } -u16 GetPCItemQuantity(u16 *quantity) +static u16 GetPCItemQuantity(u16 *quantity) { return *quantity; } -void SetPCItemQuantity(u16 *quantity, u16 newValue) +static void SetPCItemQuantity(u16 *quantity, u16 newValue) { *quantity = newValue; } @@ -91,26 +87,26 @@ void SetBagItemsPointers(void) gBagPockets[BERRIES_POCKET].capacity = BAG_BERRIES_COUNT; } -void CopyItemName(u16 itemId, u8 *string) +void CopyItemName(u16 itemId, u8 *dst) { - StringCopy(string, ItemId_GetName(itemId)); + StringCopy(dst, ItemId_GetName(itemId)); } -void CopyItemNameHandlePlural(u16 itemId, u8 *string, u32 quantity) +void CopyItemNameHandlePlural(u16 itemId, u8 *dst, u32 quantity) { if (itemId == ITEM_POKE_BALL) { if (quantity < 2) - StringCopy(string, ItemId_GetName(ITEM_POKE_BALL)); + StringCopy(dst, ItemId_GetName(ITEM_POKE_BALL)); else - StringCopy(string, gText_PokeBalls); + StringCopy(dst, gText_PokeBalls); } else { if (itemId >= ITEM_CHERI_BERRY && itemId <= ITEM_ENIGMA_BERRY) - GetBerryCountString(string, gBerries[itemId - ITEM_CHERI_BERRY].name, quantity); + GetBerryCountString(dst, gBerries[itemId - ITEM_CHERI_BERRY].name, quantity); else - StringCopy(string, ItemId_GetName(itemId)); + StringCopy(dst, ItemId_GetName(itemId)); } } @@ -157,12 +153,12 @@ bool8 CheckBagHasItem(u16 itemId, u16 count) if (gBagPockets[pocket].itemSlots[i].itemId == itemId) { u16 quantity; - //Does this item slot contain enough of the item? + // Does this item slot contain enough of the item? quantity = GetBagItemQuantity(&gBagPockets[pocket].itemSlots[i].quantity); if (quantity >= count) return TRUE; count -= quantity; - //Does this item slot and all previous slots contain enough of the item? + // Does this item slot and all previous slots contain enough of the item? if (count == 0) return TRUE; } @@ -901,7 +897,7 @@ static bool8 CheckPyramidBagHasSpace(u16 itemId, u16 count) return FALSE; } -static bool8 AddPyramidBagItem(u16 itemId, u16 count) +bool8 AddPyramidBagItem(u16 itemId, u16 count) { u16 i; @@ -974,9 +970,7 @@ static bool8 AddPyramidBagItem(u16 itemId, u16 count) } } -extern u16 gUnknown_0203CF30[]; - -static bool8 RemovePyramidBagItem(u16 itemId, u16 count) +bool8 RemovePyramidBagItem(u16 itemId, u16 count) { u16 i; @@ -1077,7 +1071,6 @@ const u8 *ItemId_GetDescription(u16 itemId) return gItems[SanitizeItemId(itemId)].description; } - u8 ItemId_GetImportance(u16 itemId) { return gItems[SanitizeItemId(itemId)].importance; diff --git a/src/load_save.c b/src/load_save.c index e3de66bb8..917c1dfe1 100644 --- a/src/load_save.c +++ b/src/load_save.c @@ -4,33 +4,30 @@ #include "main.h" #include "pokemon.h" #include "random.h" +#include "malloc.h" +#include "item.h" extern void* gUnknown_0203CF5C; extern bool16 IdentifyFlash(void); -extern void SetBagItemsPointers(void); extern void SetDecorationInventoriesPointers(void); extern void ApplyNewEncryptionKeyToGameStats(u32 key); -extern void ApplyNewEncryptionKeyToBagItems(u32 newKey); -extern void ApplyNewEncryptionKeyToBagItems_(u32 key); extern void ApplyNewEncryptionKeyToBerryPowder(u32 key); extern void sub_8084FAC(int unused); -// this is probably wrong or misleading due to it being used in ResetHeap... -extern void InitHeap(void *pointer, u32 size); - #define SAVEBLOCK_MOVE_RANGE 128 struct LoadedSaveData { - /*0x0000*/ struct ItemSlot items[30]; - /*0x0078*/ struct ItemSlot keyItems[30]; - /*0x00F0*/ struct ItemSlot pokeBalls[16]; - /*0x0130*/ struct ItemSlot TMsHMs[64]; - /*0x0230*/ struct ItemSlot berries[46]; + /*0x0000*/ struct ItemSlot items[BAG_ITEMS_COUNT]; + /*0x0078*/ struct ItemSlot keyItems[BAG_KEYITEMS_COUNT]; + /*0x00F0*/ struct ItemSlot pokeBalls[BAG_POKEBALLS_COUNT]; + /*0x0130*/ struct ItemSlot TMsHMs[BAG_TMHM_COUNT]; + /*0x0230*/ struct ItemSlot berries[BAG_BERRIES_COUNT]; /*0x02E8*/ struct MailStruct mail[MAIL_COUNT]; }; +// EWRAM DATA EWRAM_DATA struct SaveBlock2 gSaveblock2 = {0}; EWRAM_DATA u8 gSaveblock2_DMA[SAVEBLOCK_MOVE_RANGE] = {0}; @@ -43,8 +40,13 @@ EWRAM_DATA u8 gSaveblock3_DMA[SAVEBLOCK_MOVE_RANGE] = {0}; EWRAM_DATA struct LoadedSaveData gLoadedSaveData = {0}; EWRAM_DATA u32 gLastEncryptionKey = {0}; -void ApplyNewEncryptionKeyToAllEncryptedData(u32 encryptionKey); +// IWRAM common +IWRAM_DATA bool32 gFlashMemoryPresent; +IWRAM_DATA struct SaveBlock1 *gSaveBlock1Ptr; +IWRAM_DATA struct SaveBlock2 *gSaveBlock2Ptr; +IWRAM_DATA struct PokemonStorage *gPokemonStoragePtr; +// code void CheckForFlashMemory(void) { if (!IdentifyFlash()) @@ -53,7 +55,9 @@ void CheckForFlashMemory(void) InitFlashTimer(); } else + { gFlashMemoryPresent = FALSE; + } } void ClearSav2(void) @@ -80,8 +84,6 @@ void SetSaveBlocksPointers(u16 offset) SetDecorationInventoriesPointers(); } -extern u8 gHeap[]; - void MoveSaveBlocks_ResetHeap(void) { void *vblankCB, *hblankCB; @@ -132,7 +134,6 @@ void MoveSaveBlocks_ResetHeap(void) gSaveBlock2Ptr->encryptionKey = encryptionKey; } - u32 GetSecretBase2Field_9(void) { return gSaveBlock2Ptr->specialSaveWarp & 1; @@ -159,112 +160,112 @@ void sav2_gender2_inplace_and_xFE(void) gSaveBlock2Ptr->specialSaveWarp &= ~1; } -void copy_player_party_to_sav1(void) // SavePlayerParty +void SavePlayerParty(void) { int i; gSaveBlock1Ptr->playerPartyCount = gPlayerPartyCount; - for (i = 0; i < 6; i++) + for (i = 0; i < PARTY_SIZE; i++) gSaveBlock1Ptr->playerParty[i] = gPlayerParty[i]; } -void copy_player_party_from_sav1(void) // LoadPlayerParty +void LoadPlayerParty(void) { int i; gPlayerPartyCount = gSaveBlock1Ptr->playerPartyCount; - for (i = 0; i < 6; i++) + for (i = 0; i < PARTY_SIZE; i++) gPlayerParty[i] = gSaveBlock1Ptr->playerParty[i]; } -void save_serialize_npcs(void) // SaveMapObjects +void SaveMapObjects(void) { int i; - for (i = 0; i < 16; i++) + for (i = 0; i < MAP_OBJECTS_COUNT; i++) gSaveBlock1Ptr->mapObjects[i] = gMapObjects[i]; } -void save_deserialize_npcs(void) // LoadMapObjects +void LoadMapObjects(void) { int i; - for (i = 0; i < 16; i++) + for (i = 0; i < MAP_OBJECTS_COUNT; i++) gMapObjects[i] = gSaveBlock1Ptr->mapObjects[i]; } void SaveSerializedGame(void) { - copy_player_party_to_sav1(); - save_serialize_npcs(); + SavePlayerParty(); + SaveMapObjects(); } void LoadSerializedGame(void) { - copy_player_party_from_sav1(); - save_deserialize_npcs(); + LoadPlayerParty(); + LoadMapObjects(); } -void copy_bags_and_unk_data_from_save_blocks(void) +void LoadPlayerBag(void) { int i; // load player items. - for (i = 0; i < 30; i++) + for (i = 0; i < BAG_ITEMS_COUNT; i++) gLoadedSaveData.items[i] = gSaveBlock1Ptr->bagPocket_Items[i]; // load player key items. - for (i = 0; i < 30; i++) + for (i = 0; i < BAG_KEYITEMS_COUNT; i++) gLoadedSaveData.keyItems[i] = gSaveBlock1Ptr->bagPocket_KeyItems[i]; // load player pokeballs. - for (i = 0; i < 16; i++) + for (i = 0; i < BAG_POKEBALLS_COUNT; i++) gLoadedSaveData.pokeBalls[i] = gSaveBlock1Ptr->bagPocket_PokeBalls[i]; // load player TMs and HMs. - for (i = 0; i < 64; i++) + for (i = 0; i < BAG_TMHM_COUNT; i++) gLoadedSaveData.TMsHMs[i] = gSaveBlock1Ptr->bagPocket_TMHM[i]; // load player berries. - for (i = 0; i < 46; i++) + for (i = 0; i < BAG_BERRIES_COUNT; i++) gLoadedSaveData.berries[i] = gSaveBlock1Ptr->bagPocket_Berries[i]; // load mail. - for (i = 0; i < 16; i++) + for (i = 0; i < MAIL_COUNT; i++) gLoadedSaveData.mail[i] = gSaveBlock1Ptr->mail[i]; gLastEncryptionKey = gSaveBlock2Ptr->encryptionKey; } -void copy_bags_and_unk_data_to_save_blocks(void) +void SavePlayerBag(void) { int i; u32 encryptionKeyBackup; // save player items. - for (i = 0; i < 30; i++) + for (i = 0; i < BAG_ITEMS_COUNT; i++) gSaveBlock1Ptr->bagPocket_Items[i] = gLoadedSaveData.items[i]; // save player key items. - for (i = 0; i < 30; i++) + for (i = 0; i < BAG_KEYITEMS_COUNT; i++) gSaveBlock1Ptr->bagPocket_KeyItems[i] = gLoadedSaveData.keyItems[i]; // save player pokeballs. - for (i = 0; i < 16; i++) + for (i = 0; i < BAG_POKEBALLS_COUNT; i++) gSaveBlock1Ptr->bagPocket_PokeBalls[i] = gLoadedSaveData.pokeBalls[i]; // save player TMs and HMs. - for (i = 0; i < 64; i++) + for (i = 0; i < BAG_TMHM_COUNT; i++) gSaveBlock1Ptr->bagPocket_TMHM[i] = gLoadedSaveData.TMsHMs[i]; // save player berries. - for (i = 0; i < 46; i++) + for (i = 0; i < BAG_BERRIES_COUNT; i++) gSaveBlock1Ptr->bagPocket_Berries[i] = gLoadedSaveData.berries[i]; // save mail. - for (i = 0; i < 16; i++) + for (i = 0; i < MAIL_COUNT; i++) gSaveBlock1Ptr->mail[i] = gLoadedSaveData.mail[i]; encryptionKeyBackup = gSaveBlock2Ptr->encryptionKey; diff --git a/src/random.c b/src/random.c index f2f0ede58..f0b2d9e5f 100644 --- a/src/random.c +++ b/src/random.c @@ -7,6 +7,10 @@ EWRAM_DATA static u8 sUnknown = 0; EWRAM_DATA static u32 sRandCount = 0; +// IWRAM common +IWRAM_DATA u32 gRngValue; +IWRAM_DATA u32 gRng2Value; + u16 Random(void) { gRngValue = 1103515245 * gRngValue + 24691; diff --git a/src/save.c b/src/save.c index 8025d6586..81731692e 100644 --- a/src/save.c +++ b/src/save.c @@ -4,17 +4,15 @@ #include "constants/game_stat.h" #include "task.h" #include "decompress.h" +#include "load_save.h" +#include "overworld.h" // for the chunk declarations -extern struct SaveBlock2 gSaveblock2; -extern struct SaveBlock1 gSaveblock1; -extern struct PokemonStorage gPokemonStorage; extern struct SaveSectionLocation gRamSaveSectionLocations[0xE]; -extern u8 gDecompressionBuffer[]; -extern u32 gFlashMemoryPresent; extern u16 gUnknown_03006294; extern bool8 gSoftResetDisabled; +extern u32 gUnknown_0203CF5C; // Divide save blocks into individual chunks to be written to flash sectors @@ -24,13 +22,13 @@ extern bool8 gSoftResetDisabled; /* * Sector Layout: - * + * * Sectors 0 - 13: Save Slot 1 * Sectors 14 - 27: Save Slot 2 * Sectors 28 - 29: Hall of Fame * Sector 30: e-Reader/Mystery Gift Stuff (note: e-Reader is deprecated in Emerald US) * Sector 31: Recorded Battle - * + * * There are two save slots for saving the player's game data. We alternate between * them each time the game is saved, so that if the current save slot is corrupt, * we can load the previous one. We also rotate the sectors in each save slot @@ -41,7 +39,7 @@ extern bool8 gSoftResetDisabled; // (u8 *)structure was removed from the first statement of the macro in Emerald. // This is because malloc is used to allocate addresses so storing the raw -// addresses should not be done in the offsets information. +// addresses should not be done in the offsets information. #define SAVEBLOCK_CHUNK(structure, chunkNum) \ { \ chunkNum * SECTOR_DATA_SIZE, \ @@ -69,8 +67,10 @@ const struct SaveSectionOffsets gSaveSectionOffsets[] = }; extern void DoSaveFailedScreen(u8); // save_failed_screen -extern void LoadSerializedGame(void); // load_save extern bool32 ProgramFlashSectorAndVerify(u8 sector, u8 *data); +extern void save_serialize_map(void); +extern void sub_800ADF8(void); +extern bool8 sub_800A520(void); // iwram common u16 gLastWrittenSector; @@ -656,11 +656,6 @@ void UpdateSaveAddresses(void) } } -extern u32 GetGameStat(u8 index); // rom4 -extern void IncrementGameStat(u8 index); // rom4 -extern void SaveSerializedGame(void); // load_save -extern u32 gUnknown_0203CF5C; - u8 HandleSavingData(u8 saveType) { u8 i; @@ -836,7 +831,7 @@ u16 sub_815355C(void) struct SaveSection* savSection; savSection = gFastSaveSection = &gSaveDataBuffer; - if (gFlashMemoryPresent != 1) + if (gFlashMemoryPresent != TRUE) return 0; UpdateSaveAddresses(); GetSaveValidStatus(gRamSaveSectionLocations); @@ -897,12 +892,6 @@ u32 sub_8153634(u8 sector, u8* src) return 1; } -extern void save_serialize_map(void); -extern void sub_8076D5C(void); -extern void sav2_gender2_inplace_and_xFE(void); -extern void sub_800ADF8(void); -extern bool8 sub_800A520(void); - void sub_8153688(u8 taskId) { s16* taskData = gTasks[taskId].data; -- cgit v1.2.3 From 9f9764672470599c7bd9428a0a121ed8b334d061 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Sun, 29 Apr 2018 15:34:14 +0200 Subject: make item compile --- src/berry.c | 2 +- src/berry_blender.c | 2 +- src/berry_tag_screen.c | 6 +++--- src/item.c | 11 ----------- 4 files changed, 5 insertions(+), 16 deletions(-) (limited to 'src') diff --git a/src/berry.c b/src/berry.c index 74b7090c0..e128eb0ec 100644 --- a/src/berry.c +++ b/src/berry.c @@ -1218,7 +1218,7 @@ void FieldObjectInteractionRemoveBerryTree(void) u8 PlayerHasBerries(void) { - return IsBagPocketNonEmpty(BAG_BERRIES); + return IsBagPocketNonEmpty(POCKET_BERRIES); } void ResetBerryTreeSparkleFlags(void) diff --git a/src/berry_blender.c b/src/berry_blender.c index 9e6a0fef7..e050ce11e 100644 --- a/src/berry_blender.c +++ b/src/berry_blender.c @@ -2472,7 +2472,7 @@ static void CB2_HandleBlenderEndGame(void) sub_8081F94(&gSendCmd[0]); if (sBerryBlenderData->yesNoAnswer == 0) { - if (IsBagPocketNonEmpty(BAG_BERRIES) == FALSE) // no berries + if (IsBagPocketNonEmpty(POCKET_BERRIES) == FALSE) // no berries { sBerryBlenderData->playAgainState = CANT_PLAY_NO_BERRIES; gSendCmd[1] = 0x9999; diff --git a/src/berry_tag_screen.c b/src/berry_tag_screen.c index 1a0d1bce0..9a6e78c81 100644 --- a/src/berry_tag_screen.c +++ b/src/berry_tag_screen.c @@ -517,7 +517,7 @@ static void TryChangeDisplayedBerry(u8 taskId, s8 toMove) s16 *data = gTasks[taskId].data; s16 currPocketPosition = gUnknown_0203CE58.scrollPosition[3] + gUnknown_0203CE58.cursorPosition[3]; u32 newPocketPosition = currPocketPosition + toMove; - if (newPocketPosition < 46 && BagGetItemIdByPocketPosition(BAG_BERRIES, newPocketPosition) != 0) + if (newPocketPosition < 46 && BagGetItemIdByPocketPosition(POCKET_BERRIES, newPocketPosition) != 0) { if (toMove < 0) data[1] = 2; @@ -537,7 +537,7 @@ static void HandleBagCursorPositionChange(s8 toMove) u16 *cursorPos = &gUnknown_0203CE58.cursorPosition[3]; if (toMove > 0) { - if (*cursorPos < 4 || BagGetItemIdByPocketPosition(BAG_BERRIES, *scrollPos + 8) == 0) + if (*cursorPos < 4 || BagGetItemIdByPocketPosition(POCKET_BERRIES, *scrollPos + 8) == 0) *cursorPos += toMove; else *scrollPos += toMove; @@ -550,7 +550,7 @@ static void HandleBagCursorPositionChange(s8 toMove) *scrollPos += toMove; } - sBerryTag->berryId = ItemIdToBerryType(BagGetItemIdByPocketPosition(BAG_BERRIES, *scrollPos + *cursorPos)); + sBerryTag->berryId = ItemIdToBerryType(BagGetItemIdByPocketPosition(POCKET_BERRIES, *scrollPos + *cursorPos)); } static void Task_DisplayAnotherBerry(u8 taskId) diff --git a/src/item.c b/src/item.c index 01166f5d6..975fef3ae 100644 --- a/src/item.c +++ b/src/item.c @@ -11,17 +11,6 @@ #include "strings.h" #include "load_save.h" -// These constants are used in gItems -enum -{ - POCKET_NONE, - POCKET_ITEMS, - POCKET_POKE_BALLS, - POCKET_TM_HM, - POCKET_BERRIES, - POCKET_KEY_ITEMS, -}; - extern bool8 InBattlePyramid(void); extern u16 gUnknown_0203CF30[]; extern const struct Item gItems[]; -- cgit v1.2.3 From f9a2f6c4a2bd8ce60d2c7a720eddf5cdde7446a9 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 1 May 2018 12:38:55 +0200 Subject: start decompiling battle records --- src/battle_records.c | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 src/battle_records.c (limited to 'src') diff --git a/src/battle_records.c b/src/battle_records.c new file mode 100644 index 000000000..b21b07341 --- /dev/null +++ b/src/battle_records.c @@ -0,0 +1,48 @@ +#include "global.h" +#include "battle_records.h" +#include "bg.h" +#include "window.h" +#include "link.h" +#include "battle.h" +#include "overworld.h" +#include "constants/game_stat.h" + +// const rom data +const u32 gUnknown_085B3484[] = INCBIN_U32("graphics/unknown/unknown_5B3484.4bpp"); +const u16 gUnknown_085B3544[] = INCBIN_U16("graphics/unknown/unknown_5B3484.gbapal"); +const u32 gUnknown_085B3564[] = INCBIN_U32("graphics/unknown/unknown_5B3564.bin"); + +const struct BgTemplate gUnknown_085B3D64[] = +{ + { + .bg = 0, + .charBaseIndex = 0, + .mapBaseIndex = 31, + .screenSize = 0, + .paletteMode = 0, + .priority = 0, + .baseTile = 0 + }, + { + .bg = 3, + .charBaseIndex = 1, + .mapBaseIndex = 30, + .screenSize = 0, + .paletteMode = 0, + .priority = 3, + .baseTile = 0 + } +}; + +const struct WindowTemplate gUnknown_085B3D6C[] = +{ + {0x0, 0x2, 0x1, 0x1A, 0x12, 0xF, 0x14}, + DUMMY_WIN_TEMPLATE +}; + +const struct WindowTemplate gUnknown_085B3D7C = {0x0, 0x2, 0x1, 0x1A, 0x11, 0xF, 0x1}; + +const u8 gUnknown_085B3D84[] = _("-------"); +const u8 gUnknown_085B3D8C[] = _("----"); + +// code -- cgit v1.2.3 From 95cf853762e4202dbfece323c5cf454984ca37c5 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 1 May 2018 14:01:54 +0200 Subject: battle records more decomp and subtle name changes --- src/battle_records.c | 257 +++++++++++++++++++++++++++++++++++++++++++++++++++ src/new_game.c | 4 +- 2 files changed, 259 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/battle_records.c b/src/battle_records.c index b21b07341..0a0e0bd42 100644 --- a/src/battle_records.c +++ b/src/battle_records.c @@ -5,8 +5,17 @@ #include "link.h" #include "battle.h" #include "overworld.h" +#include "text.h" +#include "strings.h" +#include "string_util.h" +#include "trainer_card.h" +#include "menu.h" +#include "menu_helpers.h" +#include "international_string_util.h" #include "constants/game_stat.h" +extern u8 gResultsWindowId; + // const rom data const u32 gUnknown_085B3484[] = INCBIN_U32("graphics/unknown/unknown_5B3484.4bpp"); const u16 gUnknown_085B3544[] = INCBIN_U16("graphics/unknown/unknown_5B3484.gbapal"); @@ -46,3 +55,251 @@ const u8 gUnknown_085B3D84[] = _("-------"); const u8 gUnknown_085B3D8C[] = _("----"); // code +static void ClearLinkBattleRecord(struct LinkBattleRecord *record) +{ + CpuFill16(0, record, sizeof(struct LinkBattleRecord)); + record->name[0] = EOS; + record->trainerId = 0; + record->wins = 0; + record->losses = 0; + record->draws = 0; +} + +static void ClearLinkBattleRecords(struct LinkBattleRecord *records) +{ + s32 i; + for (i = 0; i < LINK_B_RECORDS_COUNT; i++) + { + ClearLinkBattleRecord(records + i); + } + SetGameStat(GAME_STAT_LINK_BATTLE_WINS, 0); + SetGameStat(GAME_STAT_LINK_BATTLE_LOSSES, 0); + SetGameStat(GAME_STAT_LINK_BATTLE_DRAWS, 0); +} + +static s32 GetLinkBattleRecordTotalBattles(struct LinkBattleRecord *record) +{ + return record->wins + record->losses + record->draws; +} + +static s32 FindLinkBattleRecord(struct LinkBattleRecord *records, const u8 *name, u16 trainerId) +{ + s32 i; + + for (i = 0; i < LINK_B_RECORDS_COUNT; i++) + { + if (!StringCompareN(records[i].name, name, OT_NAME_LENGTH) && records[i].trainerId == trainerId) + return i; + } + + return LINK_B_RECORDS_COUNT; +} + +static void SortLinkBattleRecords(struct LinkBattleRecords *records) +{ + s32 i, j; + + for (i = LINK_B_RECORDS_COUNT - 1; i > 0; i--) + { + for (j = i - 1; j >= 0; j--) + { + s32 totalBattlesI = GetLinkBattleRecordTotalBattles(&records->entries[i]); + s32 totalBattlesJ = GetLinkBattleRecordTotalBattles(&records->entries[j]); + + if (totalBattlesI > totalBattlesJ) + { + struct LinkBattleRecord temp1; + u8 temp2; + + temp1 = records->entries[i]; + records->entries[i] = records->entries[j]; + records->entries[j] = temp1; + + temp2 = records->languages[i]; + records->languages[i] = records->languages[j]; + records->languages[j] = temp2; + } + } + } +} + +static void UpdateLinkBattleRecord(struct LinkBattleRecord *record, s32 battleOutcome) +{ + switch (battleOutcome) + { + case B_OUTCOME_WON: + record->wins++; + if (record->wins > 9999) + record->wins = 9999; + break; + case B_OUTCOME_LOST: + record->losses++; + if (record->losses > 9999) + record->losses = 9999; + break; + case B_OUTCOME_DREW: + record->draws++; + if (record->draws > 9999) + record->draws = 9999; + break; + } +} + +static void UpdateLinkBattleGameStats(s32 battleOutcome) +{ + u8 stat; + + switch (battleOutcome) + { + case B_OUTCOME_WON: + stat = GAME_STAT_LINK_BATTLE_WINS; + break; + case B_OUTCOME_LOST: + stat = GAME_STAT_LINK_BATTLE_LOSSES; + break; + case B_OUTCOME_DREW: + stat = GAME_STAT_LINK_BATTLE_DRAWS; + break; + default: + return; + } + + if (GetGameStat(stat) < 9999) + IncrementGameStat(stat); +} + +static void UpdateLinkBattleRecords(struct LinkBattleRecords *records, const u8 *name, u16 trainerId, s32 battleOutcome, u8 battlerId) +{ + s32 index; + + UpdateLinkBattleGameStats(battleOutcome); + SortLinkBattleRecords(records); + index = FindLinkBattleRecord(records->entries, name, trainerId); + if (index == LINK_B_RECORDS_COUNT) + { + index = LINK_B_RECORDS_COUNT - 1; + ClearLinkBattleRecord(&records->entries[index]); + StringCopyN(records->entries[index].name, name, OT_NAME_LENGTH); + records->entries[index].trainerId = trainerId; + records->languages[index] = gLinkPlayers[battlerId].language; + } + UpdateLinkBattleRecord(&records->entries[index], battleOutcome); + SortLinkBattleRecords(records); +} + +void ClearPlayerLinkBattleRecords(void) +{ + ClearLinkBattleRecords(gSaveBlock1Ptr->linkBattleRecords.entries); +} + +static void IncTrainerCardWins(int battlerId) +{ + u16 *wins = &gTrainerCards[battlerId].linkBattleWins; + (*wins)++; + if (*wins > 9999) + *wins = 9999; +} + +static void IncTrainerCardLosses(int battlerId) +{ + u16 *losses = &gTrainerCards[battlerId].linkBattleLosses; + (*losses)++; + if (*losses > 9999) + *losses = 9999; +} + +static void UpdateTrainerCardWinsLosses(int battlerId) +{ + switch (gBattleOutcome) + { + case B_OUTCOME_WON: + IncTrainerCardWins(BATTLE_OPPOSITE(battlerId)); + IncTrainerCardLosses(battlerId); + break; + case B_OUTCOME_LOST: + IncTrainerCardLosses(BATTLE_OPPOSITE(battlerId)); + IncTrainerCardWins(battlerId); + break; + } +} + +void UpdatePlayerLinkBattleRecords(int battlerId) +{ + if (InUnionRoom() != TRUE) + { + UpdateTrainerCardWinsLosses(battlerId); + UpdateLinkBattleRecords( + &gSaveBlock1Ptr->linkBattleRecords, + gTrainerCards[battlerId].playerName, + gTrainerCards[battlerId].trainerId, + gBattleOutcome, + battlerId); + } +} + +static void PrintLinkBattleWinsLossesDraws(struct LinkBattleRecord *records) +{ + s32 x; + + ConvertIntToDecimalStringN(gStringVar1, GetGameStat(GAME_STAT_LINK_BATTLE_WINS), STR_CONV_MODE_LEFT_ALIGN, 4); + ConvertIntToDecimalStringN(gStringVar2, GetGameStat(GAME_STAT_LINK_BATTLE_LOSSES), STR_CONV_MODE_LEFT_ALIGN, 4); + ConvertIntToDecimalStringN(gStringVar3, GetGameStat(GAME_STAT_LINK_BATTLE_DRAWS), STR_CONV_MODE_LEFT_ALIGN, 4); + StringExpandPlaceholders(gStringVar4, gText_TotalRecordWLD); + + x = GetStringCenterAlignXOffset(1, gStringVar4, 0xD0); + PrintTextOnWindow(gResultsWindowId, 1, gStringVar4, x, 0x11, 0, NULL); +} + +static void PrintLinkBattleRecord(struct LinkBattleRecord *record, u8 y, s32 language) +{ + if (record->wins == 0 && record->losses == 0 && record->draws == 0) + { + // empty slot + PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D84, 8, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D8C, 80, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D8C, 128, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D8C, 176, (y * 8) + 1, 0, NULL); + } + else + { + StringFillWithTerminator(gStringVar1, 8); + StringCopyN(gStringVar1, record->name, 7); + ConvertInternationalString(gStringVar1, language); + + PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 8, (y * 8) + 1, 0, NULL); + + ConvertIntToDecimalStringN(gStringVar1, record->wins, STR_CONV_MODE_RIGHT_ALIGN, 4); + PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 80, (y * 8) + 1, 0, NULL); + + ConvertIntToDecimalStringN(gStringVar1, record->losses, STR_CONV_MODE_RIGHT_ALIGN, 4); + PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 128, (y * 8) + 1, 0, NULL); + + ConvertIntToDecimalStringN(gStringVar1, record->draws, STR_CONV_MODE_RIGHT_ALIGN, 4); + PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 176, (y * 8) + 1, 0, NULL); + } +} + +void ShowLinkBattleRecords(void) +{ + s32 i, x; + + gResultsWindowId = AddWindow(&gUnknown_085B3D7C); + NewMenuHelpers_DrawStdWindowFrame(gResultsWindowId, FALSE); + FillWindowPixelBuffer(gResultsWindowId, 0x11); + StringExpandPlaceholders(gStringVar4, gText_PlayersBattleResults); + + x = GetStringCenterAlignXOffset(1, gStringVar4, 208); + PrintTextOnWindow(gResultsWindowId, 1, gStringVar4, x, 1, 0, NULL); + PrintLinkBattleWinsLossesDraws(gSaveBlock1Ptr->linkBattleRecords.entries); + + StringExpandPlaceholders(gStringVar4, gText_WinLoseDraw); + PrintTextOnWindow(gResultsWindowId, 1, gStringVar4, 0, 41, 0, NULL); + + for (i = 0; i < LINK_B_RECORDS_COUNT; i++) + { + PrintLinkBattleRecord(&gSaveBlock1Ptr->linkBattleRecords.entries[i], 7 + (i * 2), gSaveBlock1Ptr->linkBattleRecords.languages[i]); + } + + PutWindowTilemap(gResultsWindowId); + CopyWindowToVram(gResultsWindowId, 3); +} diff --git a/src/new_game.c b/src/new_game.c index 89771e92b..92ca916d6 100644 --- a/src/new_game.c +++ b/src/new_game.c @@ -41,7 +41,7 @@ extern void ResetSecretBases(void); extern void ResetLinkContestBoolean(void); extern void ResetGameStats(void); extern void sub_8052DA8(void); -extern void InitLinkBattleRecords(void); +extern void ClearPlayerLinkBattleRecords(void); extern void ResetPokemonStorageSystem(void); extern void ClearBag(void); extern void NewGameInitPCItems(void); @@ -178,7 +178,7 @@ void NewGameInitData(void) ResetLinkContestBoolean(); ResetGameStats(); ClearAllContestWinnerPics(); - InitLinkBattleRecords(); + ClearPlayerLinkBattleRecords(); InitSeedotSizeRecord(); InitLotadSizeRecord(); gPlayerPartyCount = 0; -- cgit v1.2.3 From ae7878672379cf8bc1e071c3cc392696785ac3e6 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 1 May 2018 15:33:13 +0200 Subject: identify and name battle records things --- src/battle_records.c | 247 ++++++++++++++++++++++++++++++++++++++++++++++----- src/berry_blender.c | 18 ++-- src/bg.c | 4 +- 3 files changed, 237 insertions(+), 32 deletions(-) (limited to 'src') diff --git a/src/battle_records.c b/src/battle_records.c index 0a0e0bd42..efc9173a7 100644 --- a/src/battle_records.c +++ b/src/battle_records.c @@ -6,15 +6,34 @@ #include "battle.h" #include "overworld.h" #include "text.h" +#include "text_window.h" #include "strings.h" #include "string_util.h" #include "trainer_card.h" #include "menu.h" #include "menu_helpers.h" +#include "palette.h" +#include "main.h" +#include "scanline_effect.h" #include "international_string_util.h" +#include "sound.h" +#include "constants/songs.h" +#include "malloc.h" +#include "gpu_regs.h" #include "constants/game_stat.h" -extern u8 gResultsWindowId; +extern void PrintOnTrainerHillRecordsWindow(void); // pokenav.s + +// this file's functions +static void sub_813C5EC(u8 taskId); +static void sub_813C62C(u8 taskId); +static void sub_813C664(u8 taskId); +static void sub_813C6A8(u8 windowId); +static void sub_813C91C(void); + +// EWRAM variables +EWRAM_DATA u8 gRecordsWindowId = 0; +EWRAM_DATA static u8 *sUnknown_0203AB78 = NULL; // const rom data const u32 gUnknown_085B3484[] = INCBIN_U32("graphics/unknown/unknown_5B3484.4bpp"); @@ -192,7 +211,7 @@ void ClearPlayerLinkBattleRecords(void) ClearLinkBattleRecords(gSaveBlock1Ptr->linkBattleRecords.entries); } -static void IncTrainerCardWins(int battlerId) +static void IncTrainerCardWins(s32 battlerId) { u16 *wins = &gTrainerCards[battlerId].linkBattleWins; (*wins)++; @@ -200,7 +219,7 @@ static void IncTrainerCardWins(int battlerId) *wins = 9999; } -static void IncTrainerCardLosses(int battlerId) +static void IncTrainerCardLosses(s32 battlerId) { u16 *losses = &gTrainerCards[battlerId].linkBattleLosses; (*losses)++; @@ -208,7 +227,7 @@ static void IncTrainerCardLosses(int battlerId) *losses = 9999; } -static void UpdateTrainerCardWinsLosses(int battlerId) +static void UpdateTrainerCardWinsLosses(s32 battlerId) { switch (gBattleOutcome) { @@ -223,7 +242,7 @@ static void UpdateTrainerCardWinsLosses(int battlerId) } } -void UpdatePlayerLinkBattleRecords(int battlerId) +void UpdatePlayerLinkBattleRecords(s32 battlerId) { if (InUnionRoom() != TRUE) { @@ -247,7 +266,7 @@ static void PrintLinkBattleWinsLossesDraws(struct LinkBattleRecord *records) StringExpandPlaceholders(gStringVar4, gText_TotalRecordWLD); x = GetStringCenterAlignXOffset(1, gStringVar4, 0xD0); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar4, x, 0x11, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar4, x, 0x11, 0, NULL); } static void PrintLinkBattleRecord(struct LinkBattleRecord *record, u8 y, s32 language) @@ -255,10 +274,10 @@ static void PrintLinkBattleRecord(struct LinkBattleRecord *record, u8 y, s32 lan if (record->wins == 0 && record->losses == 0 && record->draws == 0) { // empty slot - PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D84, 8, (y * 8) + 1, 0, NULL); - PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D8C, 80, (y * 8) + 1, 0, NULL); - PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D8C, 128, (y * 8) + 1, 0, NULL); - PrintTextOnWindow(gResultsWindowId, 1, gUnknown_085B3D8C, 176, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D84, 8, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D8C, 80, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D8C, 128, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D8C, 176, (y * 8) + 1, 0, NULL); } else { @@ -266,16 +285,16 @@ static void PrintLinkBattleRecord(struct LinkBattleRecord *record, u8 y, s32 lan StringCopyN(gStringVar1, record->name, 7); ConvertInternationalString(gStringVar1, language); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 8, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar1, 8, (y * 8) + 1, 0, NULL); ConvertIntToDecimalStringN(gStringVar1, record->wins, STR_CONV_MODE_RIGHT_ALIGN, 4); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 80, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar1, 80, (y * 8) + 1, 0, NULL); ConvertIntToDecimalStringN(gStringVar1, record->losses, STR_CONV_MODE_RIGHT_ALIGN, 4); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 128, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar1, 128, (y * 8) + 1, 0, NULL); ConvertIntToDecimalStringN(gStringVar1, record->draws, STR_CONV_MODE_RIGHT_ALIGN, 4); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar1, 176, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar1, 176, (y * 8) + 1, 0, NULL); } } @@ -283,23 +302,209 @@ void ShowLinkBattleRecords(void) { s32 i, x; - gResultsWindowId = AddWindow(&gUnknown_085B3D7C); - NewMenuHelpers_DrawStdWindowFrame(gResultsWindowId, FALSE); - FillWindowPixelBuffer(gResultsWindowId, 0x11); + gRecordsWindowId = AddWindow(&gUnknown_085B3D7C); + NewMenuHelpers_DrawStdWindowFrame(gRecordsWindowId, FALSE); + FillWindowPixelBuffer(gRecordsWindowId, 0x11); StringExpandPlaceholders(gStringVar4, gText_PlayersBattleResults); x = GetStringCenterAlignXOffset(1, gStringVar4, 208); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar4, x, 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar4, x, 1, 0, NULL); PrintLinkBattleWinsLossesDraws(gSaveBlock1Ptr->linkBattleRecords.entries); StringExpandPlaceholders(gStringVar4, gText_WinLoseDraw); - PrintTextOnWindow(gResultsWindowId, 1, gStringVar4, 0, 41, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gStringVar4, 0, 41, 0, NULL); for (i = 0; i < LINK_B_RECORDS_COUNT; i++) { PrintLinkBattleRecord(&gSaveBlock1Ptr->linkBattleRecords.entries[i], 7 + (i * 2), gSaveBlock1Ptr->linkBattleRecords.languages[i]); } - PutWindowTilemap(gResultsWindowId); - CopyWindowToVram(gResultsWindowId, 3); + PutWindowTilemap(gRecordsWindowId); + CopyWindowToVram(gRecordsWindowId, 3); +} + +void RemoveRecordsWindow(void) +{ + sub_819746C(gRecordsWindowId, FALSE); + RemoveWindow(gRecordsWindowId); +} + +static void sub_813C5BC(u8 taskId) +{ + if (!gPaletteFade.active) + gTasks[taskId].func = sub_813C5EC; +} + +static void sub_813C5EC(u8 taskId) +{ + struct Task *task = &gTasks[taskId]; + + if (gMain.newKeys & A_BUTTON || gMain.newKeys & B_BUTTON) + { + PlaySE(SE_SELECT); + task->func = sub_813C62C; + } +} + +static void sub_813C62C(u8 taskId) +{ + BeginNormalPaletteFade(-1, 0, 0, 0x10, 0); + gTasks[taskId].func = sub_813C664; +} + +static void sub_813C664(u8 taskId) +{ + if (!gPaletteFade.active) + { + SetMainCallback2(CB2_ReturnToFieldContinueScript); + Free(sUnknown_0203AB78); + sub_813C6A8(0); + FreeAllWindowBuffers(); + DestroyTask(taskId); + } +} + +static void sub_813C6A8(u8 windowId) +{ + FillWindowPixelBuffer(windowId, 0); + ClearWindowTilemap(windowId); + CopyWindowToVram(windowId, 2); + RemoveWindow(windowId); +} + +static void sub_813C6D4(void) +{ + DmaClearLarge16(3, (void*)(VRAM), VRAM_SIZE, 0x1000); + DmaClear32(3, OAM, OAM_SIZE); + DmaClear16(3, PLTT, PLTT_SIZE); + + SetGpuReg(REG_OFFSET_DISPCNT, 0); + SetGpuReg(REG_OFFSET_BG0CNT, 0); + SetGpuReg(REG_OFFSET_BG0HOFS, 0); + SetGpuReg(REG_OFFSET_BG0VOFS, 0); + SetGpuReg(REG_OFFSET_BG1CNT, 0); + SetGpuReg(REG_OFFSET_BG1HOFS, 0); + SetGpuReg(REG_OFFSET_BG1VOFS, 0); + SetGpuReg(REG_OFFSET_BG2CNT, 0); + SetGpuReg(REG_OFFSET_BG2HOFS, 0); + SetGpuReg(REG_OFFSET_BG2VOFS, 0); + SetGpuReg(REG_OFFSET_BG3CNT, 0); + SetGpuReg(REG_OFFSET_BG3HOFS, 0); + SetGpuReg(REG_OFFSET_BG3VOFS, 0); + SetGpuReg(REG_OFFSET_WIN0H, 0); + SetGpuReg(REG_OFFSET_WIN0V, 0); + SetGpuReg(REG_OFFSET_WININ, 0); + SetGpuReg(REG_OFFSET_WINOUT, 0); + SetGpuReg(REG_OFFSET_BLDCNT, 0); + SetGpuReg(REG_OFFSET_BLDALPHA, 0); + SetGpuReg(REG_OFFSET_BLDY, 0); +} + +static void sub_813C80C(void) +{ + ScanlineEffect_Stop(); + ResetTasks(); + ResetSpriteData(); + ResetPaletteFade(); + FreeAllSpritePalettes(); +} + +static void ResetBgCoordinates(void) +{ + ChangeBgX(0, 0, 0); + ChangeBgY(0, 0, 0); + ChangeBgX(1, 0, 0); + ChangeBgY(1, 0, 0); + ChangeBgX(2, 0, 0); + ChangeBgY(2, 0, 0); + ChangeBgX(3, 0, 0); + ChangeBgY(3, 0, 0); +} + +static void sub_813C880(void) +{ + SetGpuReg(REG_OFFSET_DISPCNT, DISPCNT_BG0_ON | DISPCNT_BG3_ON | DISPCNT_OBJ_1D_MAP); +} + +static void sub_813C890(u8 bgId) +{ + LoadBgTiles(bgId, gUnknown_085B3484, sizeof(gUnknown_085B3484), 0); + CopyToBgTilemapBufferRect(bgId, gUnknown_085B3564, 0, 0, 0x20, 0x20); + LoadPalette(gUnknown_085B3544, 0, 0x20); +} + +static void sub_813C8D8(void) +{ + LoadOam(); + ProcessSpriteCopyRequests(); + TransferPlttBuffer(); +} + +static void sub_813C8EC(void) +{ + RunTasks(); + AnimateSprites(); + BuildOamBuffer(); + UpdatePaletteFade(); +} + +void ShowTrainerHillRecords(void) +{ + SetVBlankCallback(NULL); + SetMainCallback2(sub_813C91C); +} + +static void sub_813C91C(void) +{ + switch (gMain.state) + { + case 0: + SetVBlankCallback(NULL); + sub_813C6D4(); + gMain.state++; + break; + case 1: + sub_813C80C(); + gMain.state++; + break; + case 2: + sUnknown_0203AB78 = AllocZeroed(0x800); + ResetBgsAndClearDma3BusyFlags(0); + InitBgsFromTemplates(0, gUnknown_085B3D64, ARRAY_COUNT(gUnknown_085B3D64)); + SetBgTilemapBuffer(3, sUnknown_0203AB78); + ResetBgCoordinates(); + gMain.state++; + break; + case 3: + sub_813C890(3); + LoadPalette(stdpal_get(0), 0xF0, 0x20); + gMain.state++; + break; + case 4: + if (IsDma3ManagerBusyWithBgCopy() != TRUE) + { + ShowBg(0); + ShowBg(3); + CopyBgTilemapBufferToVram(3); + gMain.state++; + } + break; + case 5: + InitWindows(gUnknown_085B3D6C); + DeactivateAllTextPrinters(); + gMain.state++; + break; + case 6: + BeginNormalPaletteFade(-1, 0, 0x10, 0, 0); + gMain.state++; + break; + case 7: + sub_813C880(); + SetVBlankCallback(sub_813C8D8); + PrintOnTrainerHillRecordsWindow(); + CreateTask(sub_813C5BC, 8); + SetMainCallback2(sub_813C8EC); + gMain.state = 0; + break; + } } diff --git a/src/berry_blender.c b/src/berry_blender.c index 9e6a0fef7..cbe7748b6 100644 --- a/src/berry_blender.c +++ b/src/berry_blender.c @@ -30,6 +30,7 @@ #include "trig.h" #include "tv.h" #include "item_menu.h" +#include "battle_records.h" #define BLENDER_SCORE_BEST 0 #define BLENDER_SCORE_GOOD 1 @@ -131,7 +132,6 @@ extern struct MusicPlayerInfo gMPlayInfo_SE2; extern struct MusicPlayerInfo gMPlayInfo_BGM; extern u8 gInGameOpponentsNo; extern u8 gUnknown_020322D5; -extern u8 gResultsWindowId; // graphics extern const u8 gBerryBlenderArrowTiles[]; @@ -3485,13 +3485,13 @@ void ShowBerryBlenderRecordWindow(void) u8 text[32]; winTemplate = sBlenderRecordWindowTemplate; - gResultsWindowId = AddWindow(&winTemplate); - NewMenuHelpers_DrawStdWindowFrame(gResultsWindowId, 0); - FillWindowPixelBuffer(gResultsWindowId, 0x11); + gRecordsWindowId = AddWindow(&winTemplate); + NewMenuHelpers_DrawStdWindowFrame(gRecordsWindowId, 0); + FillWindowPixelBuffer(gRecordsWindowId, 0x11); xPos = GetStringCenterAlignXOffset(1, gText_BlenderMaxSpeedRecord, 0x90); - PrintTextOnWindow(gResultsWindowId, 1, gText_BlenderMaxSpeedRecord, xPos, 1, 0, NULL); - PrintTextOnWindow(gResultsWindowId, 1, gText_234Players, 4, 0x29, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gText_BlenderMaxSpeedRecord, xPos, 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, gText_234Players, 4, 0x29, 0, NULL); for (i = 0, yPos = 0x29; i < BLENDER_SCORES_NO; i++) { @@ -3506,11 +3506,11 @@ void ShowBerryBlenderRecordWindow(void) txtPtr = StringAppend(txtPtr, sText_RPM); xPos = GetStringRightAlignXOffset(1, text, 0x8C); - PrintTextOnWindow(gResultsWindowId, 1, text, xPos, yPos + (i * 16), 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, text, xPos, yPos + (i * 16), 0, NULL); } - PutWindowTilemap(gResultsWindowId); - CopyWindowToVram(gResultsWindowId, 3); + PutWindowTilemap(gRecordsWindowId); + CopyWindowToVram(gRecordsWindowId, 3); } static void sub_8083F3C(u8 taskId) diff --git a/src/bg.c b/src/bg.c index 22861b64d..975c72a94 100644 --- a/src/bg.c +++ b/src/bg.c @@ -965,9 +965,9 @@ void CopyBgTilemapBufferToVram(u8 bg) } } -void CopyToBgTilemapBufferRect(u8 bg, void* src, u8 destX, u8 destY, u8 width, u8 height) +void CopyToBgTilemapBufferRect(u8 bg, const void* src, u8 destX, u8 destY, u8 width, u8 height) { - void* srcCopy; + const void* srcCopy; u16 destX16; u16 destY16; u16 mode; -- cgit v1.2.3 From cc578fce18c9bfed064fc5a4cb39165722db9c33 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 1 May 2018 15:54:31 +0200 Subject: battle records decompiled and documented --- src/battle_records.c | 102 +++++++++++++++++++++++++-------------------------- src/new_game.c | 10 ++--- 2 files changed, 55 insertions(+), 57 deletions(-) (limited to 'src') diff --git a/src/battle_records.c b/src/battle_records.c index efc9173a7..a148f998f 100644 --- a/src/battle_records.c +++ b/src/battle_records.c @@ -25,22 +25,22 @@ extern void PrintOnTrainerHillRecordsWindow(void); // pokenav.s // this file's functions -static void sub_813C5EC(u8 taskId); -static void sub_813C62C(u8 taskId); -static void sub_813C664(u8 taskId); -static void sub_813C6A8(u8 windowId); -static void sub_813C91C(void); +static void Task_CloseTrainerHillRecordsOnButton(u8 taskId); +static void Task_BeginPaletteFade(u8 taskId); +static void Task_ExitTrainerHillRecords(u8 taskId); +static void RemoveTrainerHillRecordsWindow(u8 windowId); +static void CB2_ShowTrainerHillRecords(void); // EWRAM variables EWRAM_DATA u8 gRecordsWindowId = 0; -EWRAM_DATA static u8 *sUnknown_0203AB78 = NULL; +EWRAM_DATA static u8 *sTilemapBuffer = NULL; // const rom data -const u32 gUnknown_085B3484[] = INCBIN_U32("graphics/unknown/unknown_5B3484.4bpp"); -const u16 gUnknown_085B3544[] = INCBIN_U16("graphics/unknown/unknown_5B3484.gbapal"); -const u32 gUnknown_085B3564[] = INCBIN_U32("graphics/unknown/unknown_5B3564.bin"); +static const u32 sTrainerHillWindowTileset[] = INCBIN_U32("graphics/unknown/unknown_5B3484.4bpp"); +static const u16 sTrainerHillWindowPalette[] = INCBIN_U16("graphics/unknown/unknown_5B3484.gbapal"); +static const u32 sTrainerHillWindowTilemap[] = INCBIN_U32("graphics/unknown/unknown_5B3564.bin"); -const struct BgTemplate gUnknown_085B3D64[] = +static const struct BgTemplate sTrainerHillRecordsBgTemplates[] = { { .bg = 0, @@ -62,16 +62,16 @@ const struct BgTemplate gUnknown_085B3D64[] = } }; -const struct WindowTemplate gUnknown_085B3D6C[] = +static const struct WindowTemplate sTrainerHillRecordsWindowTemplates[] = { {0x0, 0x2, 0x1, 0x1A, 0x12, 0xF, 0x14}, DUMMY_WIN_TEMPLATE }; -const struct WindowTemplate gUnknown_085B3D7C = {0x0, 0x2, 0x1, 0x1A, 0x11, 0xF, 0x1}; +static const struct WindowTemplate sLinkBattleRecordsWindow = {0x0, 0x2, 0x1, 0x1A, 0x11, 0xF, 0x1}; -const u8 gUnknown_085B3D84[] = _("-------"); -const u8 gUnknown_085B3D8C[] = _("----"); +static const u8 sText_DashesNoPlayer[] = _("-------"); +static const u8 sText_DashesNoScore[] = _("----"); // code static void ClearLinkBattleRecord(struct LinkBattleRecord *record) @@ -274,10 +274,10 @@ static void PrintLinkBattleRecord(struct LinkBattleRecord *record, u8 y, s32 lan if (record->wins == 0 && record->losses == 0 && record->draws == 0) { // empty slot - PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D84, 8, (y * 8) + 1, 0, NULL); - PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D8C, 80, (y * 8) + 1, 0, NULL); - PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D8C, 128, (y * 8) + 1, 0, NULL); - PrintTextOnWindow(gRecordsWindowId, 1, gUnknown_085B3D8C, 176, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, sText_DashesNoPlayer, 8, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, sText_DashesNoScore, 80, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, sText_DashesNoScore, 128, (y * 8) + 1, 0, NULL); + PrintTextOnWindow(gRecordsWindowId, 1, sText_DashesNoScore, 176, (y * 8) + 1, 0, NULL); } else { @@ -302,7 +302,7 @@ void ShowLinkBattleRecords(void) { s32 i, x; - gRecordsWindowId = AddWindow(&gUnknown_085B3D7C); + gRecordsWindowId = AddWindow(&sLinkBattleRecordsWindow); NewMenuHelpers_DrawStdWindowFrame(gRecordsWindowId, FALSE); FillWindowPixelBuffer(gRecordsWindowId, 0x11); StringExpandPlaceholders(gStringVar4, gText_PlayersBattleResults); @@ -329,42 +329,42 @@ void RemoveRecordsWindow(void) RemoveWindow(gRecordsWindowId); } -static void sub_813C5BC(u8 taskId) +static void Task_TrainerHillWaitForPaletteFade(u8 taskId) { if (!gPaletteFade.active) - gTasks[taskId].func = sub_813C5EC; + gTasks[taskId].func = Task_CloseTrainerHillRecordsOnButton; } -static void sub_813C5EC(u8 taskId) +static void Task_CloseTrainerHillRecordsOnButton(u8 taskId) { struct Task *task = &gTasks[taskId]; if (gMain.newKeys & A_BUTTON || gMain.newKeys & B_BUTTON) { PlaySE(SE_SELECT); - task->func = sub_813C62C; + task->func = Task_BeginPaletteFade; } } -static void sub_813C62C(u8 taskId) +static void Task_BeginPaletteFade(u8 taskId) { BeginNormalPaletteFade(-1, 0, 0, 0x10, 0); - gTasks[taskId].func = sub_813C664; + gTasks[taskId].func = Task_ExitTrainerHillRecords; } -static void sub_813C664(u8 taskId) +static void Task_ExitTrainerHillRecords(u8 taskId) { if (!gPaletteFade.active) { SetMainCallback2(CB2_ReturnToFieldContinueScript); - Free(sUnknown_0203AB78); - sub_813C6A8(0); + Free(sTilemapBuffer); + RemoveTrainerHillRecordsWindow(0); FreeAllWindowBuffers(); DestroyTask(taskId); } } -static void sub_813C6A8(u8 windowId) +static void RemoveTrainerHillRecordsWindow(u8 windowId) { FillWindowPixelBuffer(windowId, 0); ClearWindowTilemap(windowId); @@ -372,7 +372,7 @@ static void sub_813C6A8(u8 windowId) RemoveWindow(windowId); } -static void sub_813C6D4(void) +static void ClearVramOamPlttRegs(void) { DmaClearLarge16(3, (void*)(VRAM), VRAM_SIZE, 0x1000); DmaClear32(3, OAM, OAM_SIZE); @@ -400,7 +400,7 @@ static void sub_813C6D4(void) SetGpuReg(REG_OFFSET_BLDY, 0); } -static void sub_813C80C(void) +static void ClearTasksAndGraphicalStructs(void) { ScanlineEffect_Stop(); ResetTasks(); @@ -421,26 +421,26 @@ static void ResetBgCoordinates(void) ChangeBgY(3, 0, 0); } -static void sub_813C880(void) +static void SetDispcntReg(void) { SetGpuReg(REG_OFFSET_DISPCNT, DISPCNT_BG0_ON | DISPCNT_BG3_ON | DISPCNT_OBJ_1D_MAP); } -static void sub_813C890(u8 bgId) +static void LoadTrainerHillRecordsWindowGfx(u8 bgId) { - LoadBgTiles(bgId, gUnknown_085B3484, sizeof(gUnknown_085B3484), 0); - CopyToBgTilemapBufferRect(bgId, gUnknown_085B3564, 0, 0, 0x20, 0x20); - LoadPalette(gUnknown_085B3544, 0, 0x20); + LoadBgTiles(bgId, sTrainerHillWindowTileset, sizeof(sTrainerHillWindowTileset), 0); + CopyToBgTilemapBufferRect(bgId, sTrainerHillWindowTilemap, 0, 0, 0x20, 0x20); + LoadPalette(sTrainerHillWindowPalette, 0, 0x20); } -static void sub_813C8D8(void) +static void VblankCB_TrainerHillRecords(void) { LoadOam(); ProcessSpriteCopyRequests(); TransferPlttBuffer(); } -static void sub_813C8EC(void) +static void MainCB2_TrainerHillRecords(void) { RunTasks(); AnimateSprites(); @@ -451,32 +451,32 @@ static void sub_813C8EC(void) void ShowTrainerHillRecords(void) { SetVBlankCallback(NULL); - SetMainCallback2(sub_813C91C); + SetMainCallback2(CB2_ShowTrainerHillRecords); } -static void sub_813C91C(void) +static void CB2_ShowTrainerHillRecords(void) { switch (gMain.state) { case 0: SetVBlankCallback(NULL); - sub_813C6D4(); + ClearVramOamPlttRegs(); gMain.state++; break; case 1: - sub_813C80C(); + ClearTasksAndGraphicalStructs(); gMain.state++; break; case 2: - sUnknown_0203AB78 = AllocZeroed(0x800); + sTilemapBuffer = AllocZeroed(0x800); ResetBgsAndClearDma3BusyFlags(0); - InitBgsFromTemplates(0, gUnknown_085B3D64, ARRAY_COUNT(gUnknown_085B3D64)); - SetBgTilemapBuffer(3, sUnknown_0203AB78); + InitBgsFromTemplates(0, sTrainerHillRecordsBgTemplates, ARRAY_COUNT(sTrainerHillRecordsBgTemplates)); + SetBgTilemapBuffer(3, sTilemapBuffer); ResetBgCoordinates(); gMain.state++; break; case 3: - sub_813C890(3); + LoadTrainerHillRecordsWindowGfx(3); LoadPalette(stdpal_get(0), 0xF0, 0x20); gMain.state++; break; @@ -490,7 +490,7 @@ static void sub_813C91C(void) } break; case 5: - InitWindows(gUnknown_085B3D6C); + InitWindows(sTrainerHillRecordsWindowTemplates); DeactivateAllTextPrinters(); gMain.state++; break; @@ -499,11 +499,11 @@ static void sub_813C91C(void) gMain.state++; break; case 7: - sub_813C880(); - SetVBlankCallback(sub_813C8D8); + SetDispcntReg(); + SetVBlankCallback(VblankCB_TrainerHillRecords); PrintOnTrainerHillRecordsWindow(); - CreateTask(sub_813C5BC, 8); - SetMainCallback2(sub_813C8EC); + CreateTask(Task_TrainerHillWaitForPaletteFade, 8); + SetMainCallback2(MainCB2_TrainerHillRecords); gMain.state = 0; break; } diff --git a/src/new_game.c b/src/new_game.c index 92ca916d6..37336016e 100644 --- a/src/new_game.c +++ b/src/new_game.c @@ -20,8 +20,10 @@ #include "tv.h" #include "coins.h" #include "text.h" +#include "overworld.h" +#include "mail.h" +#include "battle_records.h" -extern u8 gPlayerPartyCount; extern u8 gDifferentSaveFile; extern u16 gSaveFileStatus; extern u8 gUnknown_030060B0; @@ -29,19 +31,15 @@ extern u8 gUnknown_030060B0; // TODO: replace those declarations with file headers extern u16 GetGeneratedTrainerIdLower(void); extern void ClearContestWinnerPicsInContestHall(void); -extern void Overworld_SetWarpDestination(s8 mapBank, s8 mapNo, s8 warpNo, s8 xPos, s8 yPos); extern void warp_in(void); extern void sub_80BB358(void); extern void ResetBagScrollPositions(void); extern void ResetPokedex(void); extern void sub_8084400(void); -extern void ClearMailData(void); extern void ResetGabbyAndTy(void); extern void ResetSecretBases(void); extern void ResetLinkContestBoolean(void); -extern void ResetGameStats(void); extern void sub_8052DA8(void); -extern void ClearPlayerLinkBattleRecords(void); extern void ResetPokemonStorageSystem(void); extern void ClearBag(void); extern void NewGameInitPCItems(void); @@ -58,7 +56,7 @@ extern void ResetContestLinkResults(void); extern void ResetPokeJumpResults(void); extern void SetBerryPowder(u32* powder, u32 newValue); -extern u8 EventScript_2715DE[]; +extern const u8 EventScript_2715DE[]; void WriteUnalignedWord(u32 var, u8 *dataPtr) { -- cgit v1.2.3 From b80fb98d9a316d2f8f0400b398fa0bc9974ac085 Mon Sep 17 00:00:00 2001 From: DizzyEggg Date: Tue, 1 May 2018 16:35:38 +0200 Subject: make battle records compile --- src/tv.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/tv.c b/src/tv.c index b7c2812fe..67544ef8a 100644 --- a/src/tv.c +++ b/src/tv.c @@ -1380,13 +1380,13 @@ void PutFanClubSpecialOnTheAir(void) StringCopy(show->fanClubSpecial.idolName, name); tv_store_id_2x(show); show->fanClubSpecial.language = gGameLanguage; - if (show->fanClubSpecial.language == LANGUAGE_JAPANESE || gSaveBlock1Ptr->unk_31A0 == LANGUAGE_JAPANESE) + if (show->fanClubSpecial.language == LANGUAGE_JAPANESE || gSaveBlock1Ptr->linkBattleRecords.languages[0] == LANGUAGE_JAPANESE) { show->fanClubSpecial.idolNameLanguage = LANGUAGE_JAPANESE; } else { - show->fanClubSpecial.idolNameLanguage = gSaveBlock1Ptr->unk_31A0; + show->fanClubSpecial.idolNameLanguage = gSaveBlock1Ptr->linkBattleRecords.languages[0]; } } @@ -2465,7 +2465,7 @@ bool8 sub_80EE7C0(void) { return TRUE; } - if (gSaveBlock1Ptr->linkBattleRecords[0].name[0] == EOS) + if (gSaveBlock1Ptr->linkBattleRecords.entries[0].name[0] == EOS) { return TRUE; } -- cgit v1.2.3 From 4acbcf5759cb2d5453631dd104e3a845931df66c Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Tue, 1 May 2018 15:19:24 -0400 Subject: Port trader from Ruby --- src/trader.c | 209 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 209 insertions(+) create mode 100644 src/trader.c (limited to 'src') diff --git a/src/trader.c b/src/trader.c new file mode 100644 index 000000000..4914f8140 --- /dev/null +++ b/src/trader.c @@ -0,0 +1,209 @@ +#include "global.h" +#include "constants/decorations.h" +#include "constants/mauville_man.h" +#include "decoration.h" +#include "decoration_inventory.h" +#include "event_data.h" +#include "main.h" +#include "menu.h" +#include "menu_helpers.h" +#include "script.h" +#include "constants/songs.h" +#include "sound.h" +#include "string_util.h" +#include "strings.h" +#include "task.h" +#include "script_menu.h" + +static const u8 * const gUnknown_085B09E4[] = +{ + gText_Tristan, + gText_Philip, + gText_Dennis, + gText_Roberto, +}; + +static const u8 gTraderDecorations[] = +{ + DECOR_DUSKULL_DOLL, + DECOR_BALL_CUSHION, + DECOR_TIRE, + DECOR_PRETTY_FLOWERS, +}; + +void TraderSetup(void) +{ + u8 i; + struct MauvilleOldManTrader *trader = &gSaveBlock1Ptr->oldMan.trader; + + trader->id = MAUVILLE_MAN_TRADER; + trader->alreadyTraded = FALSE; + + for (i = 0; i < 4; i++) + { + StringCopy(trader->unk5[i], gUnknown_085B09E4[i]); + trader->unk1[i] = gTraderDecorations[i]; + trader->language[i] = GAME_LANGUAGE; + } +} + +void sub_8133A60(void) +{ + struct MauvilleOldManTrader *trader = &gSaveBlock1Ptr->oldMan.trader; + trader->alreadyTraded = FALSE; +} + +void CreateAvailableDecorationsMenu(u8 taskId) +{ + u8 i; + s16 * data = gTasks[taskId].data; + struct MauvilleOldManTrader *trader = &gSaveBlock1Ptr->oldMan.trader; + struct WindowTemplate windowTemplate = {0, 1, 1, 10, 10, 15, 1}; + s32 windowWidth = GetStringWidth(1, gText_Exit, 0); + s32 fiveMarksWidth = GetStringWidth(1, gText_FiveMarks, 0); + for (i = 0; i < 4; i++) + { + s32 curWidth; + if (trader->unk1[i] > NUM_DECORATIONS) + curWidth = fiveMarksWidth; + else + curWidth = GetStringWidth(1, gDecorations[trader->unk1[i]].name, 0); + if (curWidth > windowWidth) + windowWidth = curWidth; + } + windowTemplate.width = convert_pixel_width_to_tile_width(windowWidth); + data[3] = AddWindow(&windowTemplate); + SetWindowBorderStyle(data[3], FALSE, 0x214, 14); + for (i = 0; i < 4; i++) + { + if (trader->unk1[i] > NUM_DECORATIONS) + PrintTextOnWindow(data[3], 1, gText_FiveMarks, 8, 16 * i + 1, 255, NULL); + else + PrintTextOnWindow(data[3], 1, gDecorations[trader->unk1[i]].name, 8, 16 * i + 1, 255, NULL); + } + PrintTextOnWindow(data[3], 1, gText_Exit, 8, 16 * i + 1, 255, NULL); + InitMenuInUpperLeftCornerPlaySoundWhenAPressed(data[3], 5, 0); + schedule_bg_copy_tilemap_to_vram(0); +} + +void sub_8133BE4(u8 taskId, u8 decorationId) +{ + s16 * data = gTasks[taskId].data; + if (decorationId > NUM_DECORATIONS) + { + gSpecialVar_0x8004 = 0xFFFF; + } + else + { + gSpecialVar_0x8004 = decorationId; + } + + sub_8198070(data[3], FALSE); + ClearWindowTilemap(data[3]); + RemoveWindow(data[3]); + schedule_bg_copy_tilemap_to_vram(0); + DestroyTask(taskId); + EnableBothScriptContexts(); +} + +void Task_HandleGetDecorationMenuInput(u8 taskId) +{ + struct MauvilleOldManTrader *trader = &gSaveBlock1Ptr->oldMan.trader; + s8 input = ProcessMenuInput(); + + switch (input) + { + case -2: + break; + case -1: + case 4: + PlaySE(SE_SELECT); + sub_8133BE4(taskId, 0); + break; + default: + PlaySE(SE_SELECT); + gSpecialVar_0x8005 = input; + StringCopy(gStringVar1, trader->unk5[input]); + ConvertInternationalString(gStringVar1, trader->language[input]); + sub_8133BE4(taskId, trader->unk1[input]); + break; + } +} + +void ScrSpecial_GetTraderTradedFlag(void) +{ + struct MauvilleOldManTrader *trader = &gSaveBlock1Ptr->oldMan.trader; + gSpecialVar_Result = trader->alreadyTraded; +} + +void ScrSpecial_DoesPlayerHaveNoDecorations(void) +{ + u8 i; + + for (i = 0; i < 8; i++) + { + if (CountDecorationCategoryN(i)) + { + gSpecialVar_Result = FALSE; + return; + } + } + gSpecialVar_Result = TRUE; +} + +void ScrSpecial_IsDecorationFull(void) +{ + gSpecialVar_Result = FALSE; + if (gDecorations[gSpecialVar_0x8004].category != gDecorations[gSpecialVar_0x8006].category + && GetFirstEmptyDecorSlot(gDecorations[gSpecialVar_0x8004].category) == -1) + { + sub_8127250(gStringVar2, gDecorations[gSpecialVar_0x8004].category); + gSpecialVar_Result = TRUE; + } +} + +void ScrSpecial_TraderMenuGiveDecoration(void) +{ + CreateTask(sub_8127208, 0); +} + +void sub_8133DA0(u8 taskId) +{ + if (IsSelectedDecorInThePC() == TRUE) + { + gSpecialVar_0x8006 = gCurDecorInventoryItems[gCurDecorationIndex]; + StringCopy(gStringVar3, gDecorations[gSpecialVar_0x8004].name); + StringCopy(gStringVar2, gDecorations[gSpecialVar_0x8006].name); + } + else + { + gSpecialVar_0x8006 = 0xFFFF; + } + DestroyTask(taskId); + EnableBothScriptContexts(); +} + +void sub_8133E1C(u8 taskId) +{ + gSpecialVar_0x8006 = 0; + DestroyTask(taskId); + EnableBothScriptContexts(); +} + +void ScrSpecial_TraderDoDecorationTrade(void) +{ + struct MauvilleOldManTrader *trader = &gSaveBlock1Ptr->oldMan.trader; + + DecorationRemove(gSpecialVar_0x8006); + DecorationAdd(gSpecialVar_0x8004); + StringCopy(trader->unk5[gSpecialVar_0x8005], gSaveBlock2Ptr->playerName); + trader->unk1[gSpecialVar_0x8005] = gSpecialVar_0x8006; + trader->language[gSpecialVar_0x8005] = GAME_LANGUAGE; + trader->alreadyTraded = TRUE; +} + +void ScrSpecial_TraderMenuGetDecoration(void) +{ + u8 taskId = CreateTask(Task_HandleGetDecorationMenuInput, 0); + CreateAvailableDecorationsMenu(taskId); +} -- cgit v1.2.3 From 21c3e7e8e5555af964f7419aa9213446eaa421d6 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Wed, 2 May 2018 11:31:58 -0400 Subject: through SetMauvilleOldMan --- src/mauville_old_man.c | 84 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 src/mauville_old_man.c (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c new file mode 100644 index 000000000..592b5c4ce --- /dev/null +++ b/src/mauville_old_man.c @@ -0,0 +1,84 @@ +#include "global.h" +#include "main.h" +#include "constants/easy_chat.h" +#include "mauville_old_man.h" + +void sub_8120E08(void); // StorytellerSetup +void sub_81339F8(void); // TraderSetup +void sub_8120B5C(void); + +static const u16 sDefaultBardSongLyrics[6] = { + EC_WORD_SHAKE, + EC_WORD_IT, + EC_WORD_DO, + EC_WORD_THE, + EC_WORD_DIET, + EC_WORD_DANCE +}; + +static void SetupBard(void) +{ + u16 i; + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + + bard->id = MAUVILLE_MAN_BARD; + bard->hasChangedSong = FALSE; + bard->language = gGameLanguage; + for (i = 0; i < 6; i++) + bard->songLyrics[i] = sDefaultBardSongLyrics[i]; +} + +static void SetupHipster(void) +{ + struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; + + hipster->id = MAUVILLE_MAN_HIPSTER; + hipster->alreadySpoken = FALSE; + hipster->language = gGameLanguage; +} + +static void SetupStoryteller(void) +{ + sub_8120E08(); +} + +static void SetupGiddy(void) +{ + struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; + + giddy->id = MAUVILLE_MAN_GIDDY; + giddy->taleCounter = 0; + giddy->language = gGameLanguage; +} + +static void SetupTrader(void) +{ + sub_81339F8(); +} + +void SetMauvilleOldMan(void) +{ + u16 trainerId = (gSaveBlock2Ptr->playerTrainerId[1] << 8) | gSaveBlock2Ptr->playerTrainerId[0]; + + + // Determine man based on the last digit of the player's trainer ID. + switch ((trainerId % 10) / 2) + { + case MAUVILLE_MAN_BARD: + SetupBard(); + break; + case MAUVILLE_MAN_HIPSTER: + SetupHipster(); + break; + case MAUVILLE_MAN_TRADER: + SetupTrader(); + break; + case MAUVILLE_MAN_STORYTELLER: + SetupStoryteller(); + break; + case MAUVILLE_MAN_GIDDY: + SetupGiddy(); + break; + } + sub_8120B5C(); +} -- cgit v1.2.3 From cae0fb8ec277adc4a7a6a27d1bbfa5aff8c49239 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Wed, 2 May 2018 16:57:34 -0400 Subject: through sub_81203FC --- src/bard_music.c | 1 + src/mail.c | 2 +- src/mauville_old_man.c | 207 +++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 209 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/bard_music.c b/src/bard_music.c index 6fb1496e5..6c2578071 100644 --- a/src/bard_music.c +++ b/src/bard_music.c @@ -2,6 +2,7 @@ // Includes #include "global.h" #include "bard_music.h" +#include "constants/easy_chat.h" #include "easy_chat.h" #include "data/bard_music/bard_sounds.h" diff --git a/src/mail.c b/src/mail.c index 85ba86974..8fddc7045 100644 --- a/src/mail.c +++ b/src/mail.c @@ -101,7 +101,7 @@ struct MailRead /*0x021c*/ u8 monIconSprite; /*0x021d*/ u8 language; /*0x021e*/ bool8 playerIsSender; - /*0x0220*/ void (*parserSingle)(u8 *dest, u16 word); + /*0x0220*/ u8 * (*parserSingle)(u8 *dest, u16 word); /*0x0224*/ void (*parserMultiple)(u8 *dest, const u16 *src, u16 length1, u16 length2); /*0x0228*/ const struct MailLayout *layout; /*0x022c*/ u8 bg1TilemapBuffer[0x1000]; diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index 592b5c4ce..f39f80ab7 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -2,10 +2,21 @@ #include "main.h" #include "constants/easy_chat.h" #include "mauville_old_man.h" +#include "event_data.h" +#include "string_util.h" +#include "text.h" +#include "easy_chat.h" +#include "script.h" +#include "random.h" +#include "event_scripts.h" + +#define CHAR_SONG_WORD_SEPARATOR 0x37 void sub_8120E08(void); // StorytellerSetup void sub_81339F8(void); // TraderSetup void sub_8120B5C(void); +void sub_81206C0(u8 a0); // StartBardSong +void sub_81204DC(void); static const u16 sDefaultBardSongLyrics[6] = { EC_WORD_SHAKE, @@ -16,6 +27,28 @@ static const u16 sDefaultBardSongLyrics[6] = { EC_WORD_DANCE }; +static const u8 * const sGiddyAdjectives[] = { + gText_SoPretty, + gText_SoDarling, + gText_SoRelaxed, + gText_SoSunny, + gText_SoDesirable, + gText_SoExciting, + gText_SoAmusing, + gText_SoMagical +}; + +static const u8 * const sGiddyQuestions[] = { + gUnknown_08294313, + gUnknown_08294359, + gUnknown_08294398, + gUnknown_082943DA, + gUnknown_0829441C, + gUnknown_08294460, + gUnknown_082944A0, + gUnknown_082944D5 +}; + static void SetupBard(void) { u16 i; @@ -82,3 +115,177 @@ void SetMauvilleOldMan(void) } sub_8120B5C(); } + +u8 sub_81201C8(void) // GetCurrentMauvilleOldMan +{ + struct MauvilleManCommon *common = &gSaveBlock1Ptr->oldMan.common; + + return common->id; +} + +void sub_81201DC(void) // ScrSpecial_GetCurrentMauvilleMan +{ + gSpecialVar_Result = sub_81201C8(); +} + +void sub_81201F4(void) // ScrSpecial_HasBardSongBeenChanged +{ + u16 *scriptResult = &gSpecialVar_Result; // why?? + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + + *scriptResult = bard->hasChangedSong; +} + +void sub_8120210(void) // ScrSpecial_SaveBardSongLyrics +{ + u16 i; + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + + StringCopy(bard->playerName, gSaveBlock2Ptr->playerName); + + for (i = 0; i < 4; i++) + bard->playerTrainerId[i] = gSaveBlock2Ptr->playerTrainerId[i]; + + for (i = 0; i < 6; i++) + bard->songLyrics[i] = bard->temporaryLyrics[i]; + + bard->hasChangedSong = TRUE; +} + +// Copies lyrics into gStringVar4 +void sub_8120280(void) +{ + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + u16 specialVar = gSpecialVar_0x8004; // It's a bit odd to use this temp variable, but it seems needed to match. + u16 *lyrics; + u16 lineNum; + u8 *wordEnd; + u8 *str; + + lyrics = bard->temporaryLyrics; + if (specialVar == 0) + lyrics = bard->songLyrics; + wordEnd = gStringVar4; + str = wordEnd; + // Put three words on each line + for (lineNum = 0; lineNum < 2; lineNum++) + { + wordEnd = CopyEasyChatWord(wordEnd, *(lyrics++)); + while (wordEnd != str) + { + if (*str == CHAR_SPACE) + *str = CHAR_SONG_WORD_SEPARATOR; + str++; + } + + str++; + *(wordEnd++) = CHAR_SPACE; + + wordEnd = CopyEasyChatWord(wordEnd, *(lyrics++)); + while (wordEnd != str) + { + if (*str == CHAR_SPACE) + *str = CHAR_SONG_WORD_SEPARATOR; + str++; + } + + str++; + *(wordEnd++) = CHAR_NEWLINE; + + wordEnd = CopyEasyChatWord(wordEnd, *(lyrics++)); + while (wordEnd != str) + { + if (*str == CHAR_SPACE) + *str = CHAR_SONG_WORD_SEPARATOR; + str++; + } + + if (lineNum == 0) + { + *(wordEnd++) = EXT_CTRL_CODE_BEGIN; + *(wordEnd++) = 15; + } + } +} + +void sub_8120340(void) // ScrSpecial_PlayBardSong +{ + sub_81206C0(gSpecialVar_0x8004); + ScriptContext1_Stop(); +} + +void sub_8120358(void) // ScrSpecial_GetHipsterSpokenFlag +{ + u16 *scriptResult = &gSpecialVar_Result; // again?? + struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; + + *scriptResult = hipster->alreadySpoken; +} + +void sub_8120374(void) // ScrSpecial_SetHipsterSpokenFlag +{ + struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; + + hipster->alreadySpoken = TRUE; +} + +void sub_812038C(void) // ScrSpecial_HipsterTeachWord +{ + u16 var = sub_811F01C(); + + if (var == 0xFFFF) + { + gSpecialVar_Result = FALSE; + } + else + { + CopyEasyChatWord(gStringVar1, var); + gSpecialVar_Result = TRUE; + } +} + +void sub_81203C4(void) // ScrSpecial_GiddyShouldTellAnotherTale +{ + struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; + + if (giddy->taleCounter == 10) + { + gSpecialVar_Result = FALSE; + giddy->taleCounter = 0; + } + else + { + gSpecialVar_Result = TRUE; + } +} + +void sub_81203FC(void) // ScrSpecial_GenerateGiddyLine +{ + struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; + + if (giddy->taleCounter == 0) + sub_81204DC(); + + if (giddy->randomWords[giddy->taleCounter] != 0xFFFF) // is not the last element of the array? + { + u8 *stringPtr; + u32 adjective = Random(); + + adjective %= 8; + stringPtr = CopyEasyChatWord(gStringVar4, giddy->randomWords[giddy->taleCounter]); + stringPtr = StringCopy(stringPtr, gOtherText_Is); + stringPtr = StringCopy(stringPtr, sGiddyAdjectives[adjective]); + StringCopy(stringPtr, gOtherText_DontYouAgree); + } + else + { + StringCopy(gStringVar4, sGiddyQuestions[giddy->questionList[giddy->questionNum++]]); + } + + if (!(Random() % 10)) + giddy->taleCounter = 10; + else + giddy->taleCounter++; + + gSpecialVar_Result = TRUE; +} -- cgit v1.2.3 From 0bc7759f9b2ee1e8b442d2b7cc9da44bb146e765 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Thu, 3 May 2018 13:40:08 -0400 Subject: through sub_8120748 --- src/mauville_old_man.c | 254 ++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 251 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index f39f80ab7..fa486748b 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -9,14 +9,24 @@ #include "script.h" #include "random.h" #include "event_scripts.h" +#include "task.h" +#include "menu.h" +#include "m4a.h" +#include "bard_music.h" +#include "constants/songs.h" #define CHAR_SONG_WORD_SEPARATOR 0x37 +extern struct MusicPlayerInfo gMPlayInfo_SE2; + +void sub_81204DC(void); +void sub_81206C0(bool8 useTemporaryLyrics); // StartBardSong +void sub_8120944(u8 taskId); +void sub_8120B5C(void); void sub_8120E08(void); // StorytellerSetup +void sub_8120E50(void); void sub_81339F8(void); // TraderSetup -void sub_8120B5C(void); -void sub_81206C0(u8 a0); // StartBardSong -void sub_81204DC(void); +void sub_8133A60(void); static const u16 sDefaultBardSongLyrics[6] = { EC_WORD_SHAKE, @@ -289,3 +299,241 @@ void sub_81203FC(void) // ScrSpecial_GenerateGiddyLine gSpecialVar_Result = TRUE; } + +void sub_81204DC(void) +{ + struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; + u16 arr[][2] = { + {EC_GROUP_POKEMON, 0}, + {EC_GROUP_LIFESTYLE, 0}, + {EC_GROUP_HOBBIES, 0}, + {EC_GROUP_MOVE_1, 0}, + {EC_GROUP_MOVE_2, 0}, + {EC_GROUP_POKEMON_2, 0} + }; + u16 i; + u16 r10; + u16 r7; + u16 r1; + + for (i = 0; i < 8; i++) + giddy->questionList[i] = i; + + for (i = 0; i < 8; i++) + { + r1 = Random() % (i + 1); + r7 = giddy->questionList[i]; + giddy->questionList[i] = giddy->questionList[r1]; + giddy->questionList[r1] = r7; + } + + r10 = 0; + for (i = 0; i < 6; i++) + { + arr[i][1] = EasyChat_GetNumWordsInGroup(arr[i][0]); + r10 += arr[i][1]; + } + + giddy->questionNum = 0; + r7 = 0; + for (i = 0; i < 10; i++) + { + r1 = Random() % 10; + if (r1 < 3 && r7 < 8) + { + giddy->randomWords[i] = 0xFFFF; + r7++; + } + else + { + s16 r2 = Random() % r10; + for (r1 = 0; i < 6; r1++) + if ((r2 -= arr[r1][1]) <= 0) + break; + if (r1 == 6) + r1 = 0; + giddy->randomWords[i] = sub_811EE90(arr[r1][0]); + } + } +} +void sub_8120628(void) +{ + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + + bard->hasChangedSong = FALSE; +} + +void sub_8120640(void) +{ + struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; + + hipster->alreadySpoken = FALSE; +} + +void sub_8120658(void) +{ + sub_8133A60(); +} + +void sub_8120664(void) +{ + sub_8120E50(); +} + +void sub_8120670(void) // ResetMauvilleOldManFlag +{ + switch (sub_81201C8()) + { + case MAUVILLE_MAN_BARD: + sub_8120628(); + break; + case MAUVILLE_MAN_HIPSTER: + sub_8120640(); + break; + case MAUVILLE_MAN_STORYTELLER: + sub_8120664(); + break; + case MAUVILLE_MAN_TRADER: + sub_8120658(); + break; + case MAUVILLE_MAN_GIDDY: + break; + } + sub_8120B5C(); +} + + +#define tState data[0] +#define tCharIndex data[3] +#define tCurrWord data[4] +#define tUseTemporaryLyrics data[5] + +#define MACRO1(a) (((a) & 3) + (((a) / 8) & 1)) + +void sub_81206C0(bool8 useTemporaryLyrics) +{ + u8 taskId = CreateTask(sub_8120944, 80); + + gTasks[taskId].tUseTemporaryLyrics = useTemporaryLyrics; +} + +void sub_81206F0(struct TextSubPrinter * printer, u16 a1) +{ + gUnknown_03002F84 = FALSE; +} + +void sub_81206FC(struct TextSubPrinter * printer, u16 a1) +{ + gUnknown_03002F84 = TRUE; +} + +void sub_8120708(const u8 * src) +{ + NewMenuHelpers_DrawDialogueFrame(0, 0); + PrintTextOnWindow(0, 1, src, 0, 1, 1, sub_81206FC); + gUnknown_03002F84 = TRUE; + CopyWindowToVram(0, 3); +} + +void sub_8120748(struct Task *task, struct BardSong *song) +{ + switch (task->tState) + { + case 0: // Initialize song + { + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + u16 *lyrics; + s32 i; + + // Copy lyrics + if (gSpecialVar_0x8004 == 0) + lyrics = bard->songLyrics; + else + lyrics = bard->temporaryLyrics; + for (i = 0; i < 6; i++) + song->lyrics[i] = lyrics[i]; + song->currWord = 0; + } + break; + case 1: // Wait for BGM to end + break; + case 2: // Initialize word + { + u16 word = song->lyrics[song->currWord]; + song->sound = GetWordSounds(word); + GetWordPhonemes(song, MACRO1(word)); + song->currWord++; + if (song->sound->var00 != 0xFF) + song->state = 0; + else + { + song->state = 3; + song->phonemeTimer = 2; + } + break; + } + case 3: + case 4: + { + const struct BardSound *sound = &song->sound[song->currPhoneme]; + + switch (song->state) + { + case 0: + song->phonemeTimer = song->phonemes[song->currPhoneme].length; + if (sound->var00 <= 50) + { + u8 num = sound->var00 / 3; + m4aSongNumStart(PH_TRAP_HELD + 3 * num); + } + song->state = 2; + song->phonemeTimer--; + break; + case 2: + song->state = 1; + if (sound->var00 <= 50) + { + song->volume = 0x100 + sound->volume * 16; + m4aMPlayVolumeControl(&gMPlayInfo_SE2, 0xFFFF, song->volume); + song->pitch = 0x200 + song->phonemes[song->currPhoneme].pitch; + m4aMPlayPitchControl(&gMPlayInfo_SE2, 0xFFFF, song->pitch); + } + break; + case 1: + if (song->voiceInflection > 10) + song->volume -= 2; + if (song->voiceInflection & 1) + song->pitch += 64; + else + song->pitch -= 64; + m4aMPlayVolumeControl(&gMPlayInfo_SE2, 0xFFFF, song->volume); + m4aMPlayPitchControl(&gMPlayInfo_SE2, 0xFFFF, song->pitch); + song->voiceInflection++; + song->phonemeTimer--; + if (song->phonemeTimer == 0) + { + song->currPhoneme++; + if (song->currPhoneme != 6 && song->sound[song->currPhoneme].var00 != 0xFF) + song->state = 0; + else + { + song->state = 3; + song->phonemeTimer = 2; + } + } + break; + case 3: + song->phonemeTimer--; + if (song->phonemeTimer == 0) + { + m4aMPlayStop(&gMPlayInfo_SE2); + song->state = 4; + } + break; + } + } + break; + case 5: + break; + } +} -- cgit v1.2.3 From c6115a2fec2955803e65eedf5e8de1b8a134c188 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Thu, 3 May 2018 17:03:52 -0400 Subject: through sub_8120C0C --- src/mauville_old_man.c | 310 ++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 307 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index fa486748b..b0e7fb491 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -1,6 +1,9 @@ #include "global.h" #include "main.h" +#include "constants/songs.h" #include "constants/easy_chat.h" +#include "constants/map_objects.h" +#include "constants/vars.h" #include "mauville_old_man.h" #include "event_data.h" #include "string_util.h" @@ -13,7 +16,8 @@ #include "menu.h" #include "m4a.h" #include "bard_music.h" -#include "constants/songs.h" +#include "sound.h" +#include "strings.h" #define CHAR_SONG_WORD_SEPARATOR 0x37 @@ -28,6 +32,12 @@ void sub_8120E50(void); void sub_81339F8(void); // TraderSetup void sub_8133A60(void); +struct BardSong gUnknown_03006130; + +EWRAM_DATA u16 gUnknown_0203A128 = 0; +EWRAM_DATA struct MauvilleOldMan * gUnknown_0203A12C = NULL; +EWRAM_DATA u8 gUnknown_0203A130 = 0; + static const u16 sDefaultBardSongLyrics[6] = { EC_WORD_SHAKE, EC_WORD_IT, @@ -409,6 +419,7 @@ void sub_8120670(void) // ResetMauvilleOldManFlag #define tUseTemporaryLyrics data[5] #define MACRO1(a) (((a) & 3) + (((a) / 8) & 1)) +#define MACRO2(a) (((a) % 4) + (((a) / 8) & 1)) void sub_81206C0(bool8 useTemporaryLyrics) { @@ -417,7 +428,7 @@ void sub_81206C0(bool8 useTemporaryLyrics) gTasks[taskId].tUseTemporaryLyrics = useTemporaryLyrics; } -void sub_81206F0(struct TextSubPrinter * printer, u16 a1) +void sub_81206F0(void) { gUnknown_03002F84 = FALSE; } @@ -435,7 +446,7 @@ void sub_8120708(const u8 * src) CopyWindowToVram(0, 3); } -void sub_8120748(struct Task *task, struct BardSong *song) +void sub_8120748(struct Task *task, struct BardSong *song) // BardSing { switch (task->tState) { @@ -537,3 +548,296 @@ void sub_8120748(struct Task *task, struct BardSong *song) break; } } + +void sub_8120944(u8 taskId) +{ + struct Task *task = &gTasks[taskId]; // r5 + + sub_8120748(task, &gUnknown_03006130); + switch (task->tState) + { + case 0: // Initialize song + sub_8120280(); + sub_8120708(gStringVar4); + task->data[1] = 0; + task->data[2] = 0; + task->tCharIndex = 0; + task->tCurrWord = 0; + FadeOutBGMTemporarily(4); + task->tState = 1; + break; + case 1: // Wait for BGM to end + if (IsBGMPausedOrStopped()) + task->tState = 2; + break; + case 2: // Initialize word + { + struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; + u8 *str = gStringVar4 + task->tCharIndex; + u16 wordLen = 0; + // Can't get it to match without hacking + u32 temp; + register s16 zero asm("r1"); + + while (*str != CHAR_SPACE + && *str != CHAR_NEWLINE + && *str != EXT_CTRL_CODE_BEGIN + && *str != EOS) + { + str++; + wordLen++; + } + if (!task->tUseTemporaryLyrics) + gUnknown_0203A128 = MACRO2(bard->songLyrics[task->tCurrWord]); + else + gUnknown_0203A128 = MACRO2(bard->temporaryLyrics[task->tCurrWord]); + temp = gUnknown_03006130.length / wordLen; + zero = 0; + gUnknown_03006130.length = temp; + if (gUnknown_03006130.length <= 0) + gUnknown_03006130.length = 1; + task->tCurrWord++; + if (task->data[2] == 0) + task->tState = 3; + else + task->tState = 5; + task->data[1] = zero; + } + break; + case 5: + if (task->data[2] == 0) + task->tState = 3; + else + task->data[2]--; + break; + case 3: + if (gStringVar4[task->tCharIndex] == EOS) + { + FadeInBGM(6); + m4aMPlayFadeOutTemporarily(&gMPlayInfo_SE2, 2); + EnableBothScriptContexts(); + DestroyTask(taskId); + } + else if (gStringVar4[task->tCharIndex] == CHAR_SPACE) + { + + sub_81206F0(); + task->tCharIndex++; + task->tState = 2; + task->data[2] = 0; + } + else if (gStringVar4[task->tCharIndex] == CHAR_NEWLINE) + { + task->tCharIndex++; + task->tState = 2; + task->data[2] = 0; + } + else if (gStringVar4[task->tCharIndex] == EXT_CTRL_CODE_BEGIN) + { + task->tCharIndex += 2; // skip over control codes + task->tState = 2; + task->data[2] = 8; + } + else if (gStringVar4[task->tCharIndex] == CHAR_SONG_WORD_SEPARATOR) + { + gStringVar4[task->tCharIndex] = CHAR_SPACE; // restore it back to a space + sub_81206F0(); + task->tCharIndex++; + task->data[2] = 0; + } + else + { + switch (task->data[1]) + { + case 0: + sub_81206F0(); + task->data[1]++; + break; + case 1: + task->data[1]++; + break; + case 2: + task->tCharIndex++; + task->data[1] = 0; + task->data[2] = gUnknown_03006130.length; + task->tState = 4; + break; + } + } + break; + case 4: + task->data[2]--; + if (task->data[2] == 0) + task->tState = 3; + break; + } + sub_8197224(); +} + +void sub_8120B5C(void) +{ + VarSet(VAR_0x4010, MAP_OBJ_GFX_BARD); +} + +struct Story +{ + u8 stat; + u8 minVal; + const u8 *title; + const u8 *action; + const u8 *fullText; +}; + +const struct Story gUnknown_0859F048[] = { + {GAME_STAT_50, 1, MauvilleCity_PokemonCenter_1F_Text_28E930, MauvilleCity_PokemonCenter_1F_Text_28E947, MauvilleCity_PokemonCenter_1F_Text_28E956}, + {GAME_STAT_STARTED_TRENDS, 1, MauvilleCity_PokemonCenter_1F_Text_28E9D7, MauvilleCity_PokemonCenter_1F_Text_28E9EF, MauvilleCity_PokemonCenter_1F_Text_28E9FE}, + {GAME_STAT_PLANTED_BERRIES, 1, MauvilleCity_PokemonCenter_1F_Text_28EA7D, MauvilleCity_PokemonCenter_1F_Text_28EA98, MauvilleCity_PokemonCenter_1F_Text_28EAA8}, + {GAME_STAT_TRADED_BIKES, 1, MauvilleCity_PokemonCenter_1F_Text_28EB19, MauvilleCity_PokemonCenter_1F_Text_28EB31, MauvilleCity_PokemonCenter_1F_Text_28EB3E}, + {GAME_STAT_GOT_INTERVIEWED, 1, MauvilleCity_PokemonCenter_1F_Text_28EBB5, MauvilleCity_PokemonCenter_1F_Text_28EBCD, MauvilleCity_PokemonCenter_1F_Text_28EBDD}, + {GAME_STAT_TRAINER_BATTLES, 1, MauvilleCity_PokemonCenter_1F_Text_28EC60, MauvilleCity_PokemonCenter_1F_Text_28EC79, MauvilleCity_PokemonCenter_1F_Text_28EC81}, + {GAME_STAT_POKEMON_CAPTURES, 1, MauvilleCity_PokemonCenter_1F_Text_28ED04, MauvilleCity_PokemonCenter_1F_Text_28ED21, MauvilleCity_PokemonCenter_1F_Text_28ED30}, + {GAME_STAT_FISHING_CAPTURES, 1, MauvilleCity_PokemonCenter_1F_Text_28EDA1, MauvilleCity_PokemonCenter_1F_Text_28EDB5, MauvilleCity_PokemonCenter_1F_Text_28EDCF}, + {GAME_STAT_HATCHED_EGGS, 1, MauvilleCity_PokemonCenter_1F_Text_28EE45, MauvilleCity_PokemonCenter_1F_Text_28EE5D, MauvilleCity_PokemonCenter_1F_Text_28EE6A}, + {GAME_STAT_EVOLVED_POKEMON, 1, MauvilleCity_PokemonCenter_1F_Text_28EEDD, MauvilleCity_PokemonCenter_1F_Text_28EEF1, MauvilleCity_PokemonCenter_1F_Text_28EF01}, + {GAME_STAT_USED_POKECENTER, 1, MauvilleCity_PokemonCenter_1F_Text_28EF73, MauvilleCity_PokemonCenter_1F_Text_28EF95, MauvilleCity_PokemonCenter_1F_Text_28EFAA}, + {GAME_STAT_RESTED_AT_HOME, 1, MauvilleCity_PokemonCenter_1F_Text_28F045, MauvilleCity_PokemonCenter_1F_Text_28F05A, MauvilleCity_PokemonCenter_1F_Text_28F071}, + {GAME_STAT_ENTERED_SAFARI_ZONE, 1, MauvilleCity_PokemonCenter_1F_Text_28F0F3, MauvilleCity_PokemonCenter_1F_Text_28F10D, MauvilleCity_PokemonCenter_1F_Text_28F125}, + {GAME_STAT_USED_CUT, 1, MauvilleCity_PokemonCenter_1F_Text_28F1BE, MauvilleCity_PokemonCenter_1F_Text_28F1D5, MauvilleCity_PokemonCenter_1F_Text_28F1DE}, + {GAME_STAT_USED_ROCK_SMASH, 1, MauvilleCity_PokemonCenter_1F_Text_28F24F, MauvilleCity_PokemonCenter_1F_Text_28F269, MauvilleCity_PokemonCenter_1F_Text_28F277}, + {GAME_STAT_MOVED_SECRET_BASE, 1, MauvilleCity_PokemonCenter_1F_Text_28F2FC, MauvilleCity_PokemonCenter_1F_Text_28F314, MauvilleCity_PokemonCenter_1F_Text_28F32A}, + {GAME_STAT_USED_SPLASH, 1, MauvilleCity_PokemonCenter_1F_Text_28F3AD, MauvilleCity_PokemonCenter_1F_Text_28F3C6, MauvilleCity_PokemonCenter_1F_Text_28F3D2}, + {GAME_STAT_USED_STRUGGLE, 1, MauvilleCity_PokemonCenter_1F_Text_28F44B, MauvilleCity_PokemonCenter_1F_Text_28F461, MauvilleCity_PokemonCenter_1F_Text_28F47C}, + {GAME_STAT_SLOT_JACKPOTS, 1, MauvilleCity_PokemonCenter_1F_Text_28F50C, MauvilleCity_PokemonCenter_1F_Text_28F51B, MauvilleCity_PokemonCenter_1F_Text_28F538}, + {GAME_STAT_CONSECUTIVE_ROULETTE_WINS, 2, MauvilleCity_PokemonCenter_1F_Text_28F5BE, MauvilleCity_PokemonCenter_1F_Text_28F5D1, MauvilleCity_PokemonCenter_1F_Text_28F5F2}, + {GAME_STAT_ENTERED_BATTLE_TOWER, 1, MauvilleCity_PokemonCenter_1F_Text_28F678, MauvilleCity_PokemonCenter_1F_Text_28F694, MauvilleCity_PokemonCenter_1F_Text_28F6B4}, + {GAME_STAT_POKEBLOCKS, 1, MauvilleCity_PokemonCenter_1F_Text_28F751, MauvilleCity_PokemonCenter_1F_Text_28F76A, MauvilleCity_PokemonCenter_1F_Text_28F776}, + {GAME_STAT_ENTERED_CONTEST, 1, MauvilleCity_PokemonCenter_1F_Text_28F7F6, MauvilleCity_PokemonCenter_1F_Text_28F811, MauvilleCity_PokemonCenter_1F_Text_28F822}, + {GAME_STAT_WON_CONTEST, 1, MauvilleCity_PokemonCenter_1F_Text_28F89C, MauvilleCity_PokemonCenter_1F_Text_28F8AF, MauvilleCity_PokemonCenter_1F_Text_28F8BC}, + {GAME_STAT_SHOPPED, 1, MauvilleCity_PokemonCenter_1F_Text_28F92F, MauvilleCity_PokemonCenter_1F_Text_28F941, MauvilleCity_PokemonCenter_1F_Text_28F949}, + {GAME_STAT_USED_ITEMFINDER, 1, MauvilleCity_PokemonCenter_1F_Text_28F9D1, MauvilleCity_PokemonCenter_1F_Text_28F9EA, MauvilleCity_PokemonCenter_1F_Text_28F9FD}, + {GAME_STAT_GOT_RAINED_ON, 1, MauvilleCity_PokemonCenter_1F_Text_28FA81, MauvilleCity_PokemonCenter_1F_Text_28FA99, MauvilleCity_PokemonCenter_1F_Text_28FAA7}, + {GAME_STAT_CHECKED_POKEDEX, 1, MauvilleCity_PokemonCenter_1F_Text_28FB1D, MauvilleCity_PokemonCenter_1F_Text_28FB35, MauvilleCity_PokemonCenter_1F_Text_28FB47}, + {GAME_STAT_RECEIVED_RIBBONS, 1, MauvilleCity_PokemonCenter_1F_Text_28FBC4, MauvilleCity_PokemonCenter_1F_Text_28FBD9, MauvilleCity_PokemonCenter_1F_Text_28FBEA}, + {GAME_STAT_JUMPED_DOWN_LEDGES, 1, MauvilleCity_PokemonCenter_1F_Text_28FC6B, MauvilleCity_PokemonCenter_1F_Text_28FC85, MauvilleCity_PokemonCenter_1F_Text_28FC98}, + {GAME_STAT_WATCHED_TV, 1, MauvilleCity_PokemonCenter_1F_Text_28FD1D, MauvilleCity_PokemonCenter_1F_Text_28FD35, MauvilleCity_PokemonCenter_1F_Text_28FD40}, + {GAME_STAT_CHECKED_CLOCK, 1, MauvilleCity_PokemonCenter_1F_Text_28FDA2, MauvilleCity_PokemonCenter_1F_Text_28FDBD, MauvilleCity_PokemonCenter_1F_Text_28FDCE}, + {GAME_STAT_WON_POKEMON_LOTTERY, 1, MauvilleCity_PokemonCenter_1F_Text_28FE57, MauvilleCity_PokemonCenter_1F_Text_28FE72, MauvilleCity_PokemonCenter_1F_Text_28FE88}, + {GAME_STAT_USED_DAYCARE, 1, MauvilleCity_PokemonCenter_1F_Text_28FF0C, MauvilleCity_PokemonCenter_1F_Text_28FF27, MauvilleCity_PokemonCenter_1F_Text_28FF44}, + {GAME_STAT_RODE_CABLE_CAR, 1, MauvilleCity_PokemonCenter_1F_Text_28FFDD, MauvilleCity_PokemonCenter_1F_Text_28FFFA, MauvilleCity_PokemonCenter_1F_Text_29000D}, + {GAME_STAT_ENTERED_HOT_SPRINGS, 1, MauvilleCity_PokemonCenter_1F_Text_290097, MauvilleCity_PokemonCenter_1F_Text_2900B5, MauvilleCity_PokemonCenter_1F_Text_2900CB} +}; + +void sub_8120B70(union OldMan * oldMan) +{ + s32 i; + u8 sp00[8]; + + switch (oldMan->common.id) + { + case MAUVILLE_MAN_TRADER: + { + struct MauvilleOldManTrader * trader = &oldMan->trader; + for (i = 0; i < 4; i++) + { + if (trader->unk32[i] == LANGUAGE_JAPANESE) + { + ConvertInternationalString(trader->unk5[i], LANGUAGE_JAPANESE); + } + } + } + break; + case MAUVILLE_MAN_STORYTELLER: + { + struct MauvilleManStoryteller * storyteller = &oldMan->storyteller; + for (i = 0; i < 4; i++) + { + if (storyteller->gameStatIDs[i] != 0) + { + memcpy(sp00, storyteller->trainerNames[i], 7); + sp00[7] = EOS; + if (IsStringJapanese(sp00)) + { + memset(sp00, CHAR_SPACE, 8); + StringCopy(sp00, gText_Friend); + memcpy(storyteller->trainerNames[i], sp00, 7); + storyteller->unk34[i] = GAME_LANGUAGE; + } + } + } + } + break; + } +} + +void sub_8120C0C(union OldMan * oldMan, u32 r8, u32 r7, u32 r3) +{ + s32 i; + + switch (oldMan->common.id) + { + case MAUVILLE_MAN_TRADER: + { + struct MauvilleOldManTrader * trader = &oldMan->trader; + + for (i = 0; i < 4; i++) + { + if (IsStringJapanese(trader->unk5[i])) + { + trader->unk32[i] = r8; + } + else + { + trader->unk32[i] = r7; + } + } + } + break; + case MAUVILLE_MAN_STORYTELLER: + { + struct MauvilleManStoryteller * storyteller = &oldMan->storyteller; + + for (i = 0; i < 4; i++) + { + if (IsStringJapanese(storyteller->trainerNames[i])) + { + storyteller->unk34[i] = r8; + } + else + { + storyteller->unk34[i] = r7; + } + } + } + break; + case MAUVILLE_MAN_BARD: + { + struct MauvilleManBard * bard = &oldMan->bard; + + if (r3 == LANGUAGE_JAPANESE) + bard->language = r8; + else + bard->language = r7; + } + break; + case MAUVILLE_MAN_HIPSTER: + { + struct MauvilleManHipster * hipster = &oldMan->hipster; + + if (r3 == LANGUAGE_JAPANESE) + hipster->language = r8; + else + hipster->language = r7; + } + break; + case MAUVILLE_MAN_GIDDY: + { + struct MauvilleManGiddy * giddy = &oldMan->giddy; + + if (r3 == LANGUAGE_JAPANESE) + giddy->language = r8; + else + giddy->language = r7; + } + break; + } +} -- cgit v1.2.3 From 1943118a1e0edcadcbf8c602aedb191f44b8b9f6 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Thu, 3 May 2018 17:26:02 -0400 Subject: through sub_8120D34 --- src/mauville_old_man.c | 204 +++++++++++++++++++++++++++++++++++++------------ 1 file changed, 156 insertions(+), 48 deletions(-) (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index b0e7fb491..1f398569c 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -679,54 +679,6 @@ void sub_8120B5C(void) VarSet(VAR_0x4010, MAP_OBJ_GFX_BARD); } -struct Story -{ - u8 stat; - u8 minVal; - const u8 *title; - const u8 *action; - const u8 *fullText; -}; - -const struct Story gUnknown_0859F048[] = { - {GAME_STAT_50, 1, MauvilleCity_PokemonCenter_1F_Text_28E930, MauvilleCity_PokemonCenter_1F_Text_28E947, MauvilleCity_PokemonCenter_1F_Text_28E956}, - {GAME_STAT_STARTED_TRENDS, 1, MauvilleCity_PokemonCenter_1F_Text_28E9D7, MauvilleCity_PokemonCenter_1F_Text_28E9EF, MauvilleCity_PokemonCenter_1F_Text_28E9FE}, - {GAME_STAT_PLANTED_BERRIES, 1, MauvilleCity_PokemonCenter_1F_Text_28EA7D, MauvilleCity_PokemonCenter_1F_Text_28EA98, MauvilleCity_PokemonCenter_1F_Text_28EAA8}, - {GAME_STAT_TRADED_BIKES, 1, MauvilleCity_PokemonCenter_1F_Text_28EB19, MauvilleCity_PokemonCenter_1F_Text_28EB31, MauvilleCity_PokemonCenter_1F_Text_28EB3E}, - {GAME_STAT_GOT_INTERVIEWED, 1, MauvilleCity_PokemonCenter_1F_Text_28EBB5, MauvilleCity_PokemonCenter_1F_Text_28EBCD, MauvilleCity_PokemonCenter_1F_Text_28EBDD}, - {GAME_STAT_TRAINER_BATTLES, 1, MauvilleCity_PokemonCenter_1F_Text_28EC60, MauvilleCity_PokemonCenter_1F_Text_28EC79, MauvilleCity_PokemonCenter_1F_Text_28EC81}, - {GAME_STAT_POKEMON_CAPTURES, 1, MauvilleCity_PokemonCenter_1F_Text_28ED04, MauvilleCity_PokemonCenter_1F_Text_28ED21, MauvilleCity_PokemonCenter_1F_Text_28ED30}, - {GAME_STAT_FISHING_CAPTURES, 1, MauvilleCity_PokemonCenter_1F_Text_28EDA1, MauvilleCity_PokemonCenter_1F_Text_28EDB5, MauvilleCity_PokemonCenter_1F_Text_28EDCF}, - {GAME_STAT_HATCHED_EGGS, 1, MauvilleCity_PokemonCenter_1F_Text_28EE45, MauvilleCity_PokemonCenter_1F_Text_28EE5D, MauvilleCity_PokemonCenter_1F_Text_28EE6A}, - {GAME_STAT_EVOLVED_POKEMON, 1, MauvilleCity_PokemonCenter_1F_Text_28EEDD, MauvilleCity_PokemonCenter_1F_Text_28EEF1, MauvilleCity_PokemonCenter_1F_Text_28EF01}, - {GAME_STAT_USED_POKECENTER, 1, MauvilleCity_PokemonCenter_1F_Text_28EF73, MauvilleCity_PokemonCenter_1F_Text_28EF95, MauvilleCity_PokemonCenter_1F_Text_28EFAA}, - {GAME_STAT_RESTED_AT_HOME, 1, MauvilleCity_PokemonCenter_1F_Text_28F045, MauvilleCity_PokemonCenter_1F_Text_28F05A, MauvilleCity_PokemonCenter_1F_Text_28F071}, - {GAME_STAT_ENTERED_SAFARI_ZONE, 1, MauvilleCity_PokemonCenter_1F_Text_28F0F3, MauvilleCity_PokemonCenter_1F_Text_28F10D, MauvilleCity_PokemonCenter_1F_Text_28F125}, - {GAME_STAT_USED_CUT, 1, MauvilleCity_PokemonCenter_1F_Text_28F1BE, MauvilleCity_PokemonCenter_1F_Text_28F1D5, MauvilleCity_PokemonCenter_1F_Text_28F1DE}, - {GAME_STAT_USED_ROCK_SMASH, 1, MauvilleCity_PokemonCenter_1F_Text_28F24F, MauvilleCity_PokemonCenter_1F_Text_28F269, MauvilleCity_PokemonCenter_1F_Text_28F277}, - {GAME_STAT_MOVED_SECRET_BASE, 1, MauvilleCity_PokemonCenter_1F_Text_28F2FC, MauvilleCity_PokemonCenter_1F_Text_28F314, MauvilleCity_PokemonCenter_1F_Text_28F32A}, - {GAME_STAT_USED_SPLASH, 1, MauvilleCity_PokemonCenter_1F_Text_28F3AD, MauvilleCity_PokemonCenter_1F_Text_28F3C6, MauvilleCity_PokemonCenter_1F_Text_28F3D2}, - {GAME_STAT_USED_STRUGGLE, 1, MauvilleCity_PokemonCenter_1F_Text_28F44B, MauvilleCity_PokemonCenter_1F_Text_28F461, MauvilleCity_PokemonCenter_1F_Text_28F47C}, - {GAME_STAT_SLOT_JACKPOTS, 1, MauvilleCity_PokemonCenter_1F_Text_28F50C, MauvilleCity_PokemonCenter_1F_Text_28F51B, MauvilleCity_PokemonCenter_1F_Text_28F538}, - {GAME_STAT_CONSECUTIVE_ROULETTE_WINS, 2, MauvilleCity_PokemonCenter_1F_Text_28F5BE, MauvilleCity_PokemonCenter_1F_Text_28F5D1, MauvilleCity_PokemonCenter_1F_Text_28F5F2}, - {GAME_STAT_ENTERED_BATTLE_TOWER, 1, MauvilleCity_PokemonCenter_1F_Text_28F678, MauvilleCity_PokemonCenter_1F_Text_28F694, MauvilleCity_PokemonCenter_1F_Text_28F6B4}, - {GAME_STAT_POKEBLOCKS, 1, MauvilleCity_PokemonCenter_1F_Text_28F751, MauvilleCity_PokemonCenter_1F_Text_28F76A, MauvilleCity_PokemonCenter_1F_Text_28F776}, - {GAME_STAT_ENTERED_CONTEST, 1, MauvilleCity_PokemonCenter_1F_Text_28F7F6, MauvilleCity_PokemonCenter_1F_Text_28F811, MauvilleCity_PokemonCenter_1F_Text_28F822}, - {GAME_STAT_WON_CONTEST, 1, MauvilleCity_PokemonCenter_1F_Text_28F89C, MauvilleCity_PokemonCenter_1F_Text_28F8AF, MauvilleCity_PokemonCenter_1F_Text_28F8BC}, - {GAME_STAT_SHOPPED, 1, MauvilleCity_PokemonCenter_1F_Text_28F92F, MauvilleCity_PokemonCenter_1F_Text_28F941, MauvilleCity_PokemonCenter_1F_Text_28F949}, - {GAME_STAT_USED_ITEMFINDER, 1, MauvilleCity_PokemonCenter_1F_Text_28F9D1, MauvilleCity_PokemonCenter_1F_Text_28F9EA, MauvilleCity_PokemonCenter_1F_Text_28F9FD}, - {GAME_STAT_GOT_RAINED_ON, 1, MauvilleCity_PokemonCenter_1F_Text_28FA81, MauvilleCity_PokemonCenter_1F_Text_28FA99, MauvilleCity_PokemonCenter_1F_Text_28FAA7}, - {GAME_STAT_CHECKED_POKEDEX, 1, MauvilleCity_PokemonCenter_1F_Text_28FB1D, MauvilleCity_PokemonCenter_1F_Text_28FB35, MauvilleCity_PokemonCenter_1F_Text_28FB47}, - {GAME_STAT_RECEIVED_RIBBONS, 1, MauvilleCity_PokemonCenter_1F_Text_28FBC4, MauvilleCity_PokemonCenter_1F_Text_28FBD9, MauvilleCity_PokemonCenter_1F_Text_28FBEA}, - {GAME_STAT_JUMPED_DOWN_LEDGES, 1, MauvilleCity_PokemonCenter_1F_Text_28FC6B, MauvilleCity_PokemonCenter_1F_Text_28FC85, MauvilleCity_PokemonCenter_1F_Text_28FC98}, - {GAME_STAT_WATCHED_TV, 1, MauvilleCity_PokemonCenter_1F_Text_28FD1D, MauvilleCity_PokemonCenter_1F_Text_28FD35, MauvilleCity_PokemonCenter_1F_Text_28FD40}, - {GAME_STAT_CHECKED_CLOCK, 1, MauvilleCity_PokemonCenter_1F_Text_28FDA2, MauvilleCity_PokemonCenter_1F_Text_28FDBD, MauvilleCity_PokemonCenter_1F_Text_28FDCE}, - {GAME_STAT_WON_POKEMON_LOTTERY, 1, MauvilleCity_PokemonCenter_1F_Text_28FE57, MauvilleCity_PokemonCenter_1F_Text_28FE72, MauvilleCity_PokemonCenter_1F_Text_28FE88}, - {GAME_STAT_USED_DAYCARE, 1, MauvilleCity_PokemonCenter_1F_Text_28FF0C, MauvilleCity_PokemonCenter_1F_Text_28FF27, MauvilleCity_PokemonCenter_1F_Text_28FF44}, - {GAME_STAT_RODE_CABLE_CAR, 1, MauvilleCity_PokemonCenter_1F_Text_28FFDD, MauvilleCity_PokemonCenter_1F_Text_28FFFA, MauvilleCity_PokemonCenter_1F_Text_29000D}, - {GAME_STAT_ENTERED_HOT_SPRINGS, 1, MauvilleCity_PokemonCenter_1F_Text_290097, MauvilleCity_PokemonCenter_1F_Text_2900B5, MauvilleCity_PokemonCenter_1F_Text_2900CB} -}; - void sub_8120B70(union OldMan * oldMan) { s32 i; @@ -841,3 +793,159 @@ void sub_8120C0C(union OldMan * oldMan, u32 r8, u32 r7, u32 r3) break; } } + +void sub_8120CD0(union OldMan * oldMan, u32 unused, u32 a2) +{ + u8 sp00[8]; + s32 i; + if (oldMan->common.id == MAUVILLE_MAN_STORYTELLER && a2 == LANGUAGE_JAPANESE) + { + struct MauvilleManStoryteller * storyteller = &oldMan->storyteller; + + for (i = 0; i < 4; i++) + { + if (storyteller->gameStatIDs[i] != 0) + { + memcpy(sp00, storyteller->trainerNames[i], 7); + sp00[7] = EOS; + if (IsStringJapanese(sp00)) + storyteller->unk34[i] = LANGUAGE_JAPANESE; + else + storyteller->unk34[i] = GAME_LANGUAGE; + } + } + } +} + +void sub_8120D34(union OldMan * oldMan, u32 r1, u32 r6) +{ + u32 r2 = (r1 == LANGUAGE_JAPANESE || r1 == LANGUAGE_ENGLISH) ? 1 : 0; + switch (oldMan->common.id) + { + case MAUVILLE_MAN_TRADER: + { + struct MauvilleOldManTrader * trader = &oldMan->trader; + s32 i; + + if (r2) + { + for (i = 0; i < 4; i++) + { + u8 * str = trader->unk5[i]; + if (str[0] == EXT_CTRL_CODE_BEGIN && str[1] == EXT_CTRL_CODE_JPN) + { + StripExtCtrlCodes(str); + trader->unk32[i] = LANGUAGE_JAPANESE; + } + else + trader->unk32[i] = r6; + } + } + else + { + for (i = 0; i < 4; i++) + { + if (trader->unk32[i] == LANGUAGE_JAPANESE) + { + StripExtCtrlCodes(trader->unk5[i]); + } + } + } + } + break; + case MAUVILLE_MAN_STORYTELLER: + { + + struct MauvilleManStoryteller * storyteller = &oldMan->storyteller; + s32 i; + + if (r2) + { + for (i = 0; i < 4; i++) + { + if (storyteller->gameStatIDs[i] != 0) + storyteller->unk34[i] = r6; + } + } + } + break; + case MAUVILLE_MAN_BARD: + { + struct MauvilleManBard * bard = &oldMan->bard; + + if (r2) + { + bard->language = r6; + } + } + break; + case MAUVILLE_MAN_HIPSTER: + { + struct MauvilleManHipster * hipster = &oldMan->hipster; + + if (r2) + { + hipster->language = r6; + } + } + break; + case MAUVILLE_MAN_GIDDY: + { + struct MauvilleManGiddy * giddy = &oldMan->giddy; + + if (r2) + { + giddy->language = r6; + } + } + break; + } +} + +struct Story +{ + u8 stat; + u8 minVal; + const u8 *title; + const u8 *action; + const u8 *fullText; +}; + +const struct Story gUnknown_0859F048[] = { + {GAME_STAT_50, 1, MauvilleCity_PokemonCenter_1F_Text_28E930, MauvilleCity_PokemonCenter_1F_Text_28E947, MauvilleCity_PokemonCenter_1F_Text_28E956}, + {GAME_STAT_STARTED_TRENDS, 1, MauvilleCity_PokemonCenter_1F_Text_28E9D7, MauvilleCity_PokemonCenter_1F_Text_28E9EF, MauvilleCity_PokemonCenter_1F_Text_28E9FE}, + {GAME_STAT_PLANTED_BERRIES, 1, MauvilleCity_PokemonCenter_1F_Text_28EA7D, MauvilleCity_PokemonCenter_1F_Text_28EA98, MauvilleCity_PokemonCenter_1F_Text_28EAA8}, + {GAME_STAT_TRADED_BIKES, 1, MauvilleCity_PokemonCenter_1F_Text_28EB19, MauvilleCity_PokemonCenter_1F_Text_28EB31, MauvilleCity_PokemonCenter_1F_Text_28EB3E}, + {GAME_STAT_GOT_INTERVIEWED, 1, MauvilleCity_PokemonCenter_1F_Text_28EBB5, MauvilleCity_PokemonCenter_1F_Text_28EBCD, MauvilleCity_PokemonCenter_1F_Text_28EBDD}, + {GAME_STAT_TRAINER_BATTLES, 1, MauvilleCity_PokemonCenter_1F_Text_28EC60, MauvilleCity_PokemonCenter_1F_Text_28EC79, MauvilleCity_PokemonCenter_1F_Text_28EC81}, + {GAME_STAT_POKEMON_CAPTURES, 1, MauvilleCity_PokemonCenter_1F_Text_28ED04, MauvilleCity_PokemonCenter_1F_Text_28ED21, MauvilleCity_PokemonCenter_1F_Text_28ED30}, + {GAME_STAT_FISHING_CAPTURES, 1, MauvilleCity_PokemonCenter_1F_Text_28EDA1, MauvilleCity_PokemonCenter_1F_Text_28EDB5, MauvilleCity_PokemonCenter_1F_Text_28EDCF}, + {GAME_STAT_HATCHED_EGGS, 1, MauvilleCity_PokemonCenter_1F_Text_28EE45, MauvilleCity_PokemonCenter_1F_Text_28EE5D, MauvilleCity_PokemonCenter_1F_Text_28EE6A}, + {GAME_STAT_EVOLVED_POKEMON, 1, MauvilleCity_PokemonCenter_1F_Text_28EEDD, MauvilleCity_PokemonCenter_1F_Text_28EEF1, MauvilleCity_PokemonCenter_1F_Text_28EF01}, + {GAME_STAT_USED_POKECENTER, 1, MauvilleCity_PokemonCenter_1F_Text_28EF73, MauvilleCity_PokemonCenter_1F_Text_28EF95, MauvilleCity_PokemonCenter_1F_Text_28EFAA}, + {GAME_STAT_RESTED_AT_HOME, 1, MauvilleCity_PokemonCenter_1F_Text_28F045, MauvilleCity_PokemonCenter_1F_Text_28F05A, MauvilleCity_PokemonCenter_1F_Text_28F071}, + {GAME_STAT_ENTERED_SAFARI_ZONE, 1, MauvilleCity_PokemonCenter_1F_Text_28F0F3, MauvilleCity_PokemonCenter_1F_Text_28F10D, MauvilleCity_PokemonCenter_1F_Text_28F125}, + {GAME_STAT_USED_CUT, 1, MauvilleCity_PokemonCenter_1F_Text_28F1BE, MauvilleCity_PokemonCenter_1F_Text_28F1D5, MauvilleCity_PokemonCenter_1F_Text_28F1DE}, + {GAME_STAT_USED_ROCK_SMASH, 1, MauvilleCity_PokemonCenter_1F_Text_28F24F, MauvilleCity_PokemonCenter_1F_Text_28F269, MauvilleCity_PokemonCenter_1F_Text_28F277}, + {GAME_STAT_MOVED_SECRET_BASE, 1, MauvilleCity_PokemonCenter_1F_Text_28F2FC, MauvilleCity_PokemonCenter_1F_Text_28F314, MauvilleCity_PokemonCenter_1F_Text_28F32A}, + {GAME_STAT_USED_SPLASH, 1, MauvilleCity_PokemonCenter_1F_Text_28F3AD, MauvilleCity_PokemonCenter_1F_Text_28F3C6, MauvilleCity_PokemonCenter_1F_Text_28F3D2}, + {GAME_STAT_USED_STRUGGLE, 1, MauvilleCity_PokemonCenter_1F_Text_28F44B, MauvilleCity_PokemonCenter_1F_Text_28F461, MauvilleCity_PokemonCenter_1F_Text_28F47C}, + {GAME_STAT_SLOT_JACKPOTS, 1, MauvilleCity_PokemonCenter_1F_Text_28F50C, MauvilleCity_PokemonCenter_1F_Text_28F51B, MauvilleCity_PokemonCenter_1F_Text_28F538}, + {GAME_STAT_CONSECUTIVE_ROULETTE_WINS, 2, MauvilleCity_PokemonCenter_1F_Text_28F5BE, MauvilleCity_PokemonCenter_1F_Text_28F5D1, MauvilleCity_PokemonCenter_1F_Text_28F5F2}, + {GAME_STAT_ENTERED_BATTLE_TOWER, 1, MauvilleCity_PokemonCenter_1F_Text_28F678, MauvilleCity_PokemonCenter_1F_Text_28F694, MauvilleCity_PokemonCenter_1F_Text_28F6B4}, + {GAME_STAT_POKEBLOCKS, 1, MauvilleCity_PokemonCenter_1F_Text_28F751, MauvilleCity_PokemonCenter_1F_Text_28F76A, MauvilleCity_PokemonCenter_1F_Text_28F776}, + {GAME_STAT_ENTERED_CONTEST, 1, MauvilleCity_PokemonCenter_1F_Text_28F7F6, MauvilleCity_PokemonCenter_1F_Text_28F811, MauvilleCity_PokemonCenter_1F_Text_28F822}, + {GAME_STAT_WON_CONTEST, 1, MauvilleCity_PokemonCenter_1F_Text_28F89C, MauvilleCity_PokemonCenter_1F_Text_28F8AF, MauvilleCity_PokemonCenter_1F_Text_28F8BC}, + {GAME_STAT_SHOPPED, 1, MauvilleCity_PokemonCenter_1F_Text_28F92F, MauvilleCity_PokemonCenter_1F_Text_28F941, MauvilleCity_PokemonCenter_1F_Text_28F949}, + {GAME_STAT_USED_ITEMFINDER, 1, MauvilleCity_PokemonCenter_1F_Text_28F9D1, MauvilleCity_PokemonCenter_1F_Text_28F9EA, MauvilleCity_PokemonCenter_1F_Text_28F9FD}, + {GAME_STAT_GOT_RAINED_ON, 1, MauvilleCity_PokemonCenter_1F_Text_28FA81, MauvilleCity_PokemonCenter_1F_Text_28FA99, MauvilleCity_PokemonCenter_1F_Text_28FAA7}, + {GAME_STAT_CHECKED_POKEDEX, 1, MauvilleCity_PokemonCenter_1F_Text_28FB1D, MauvilleCity_PokemonCenter_1F_Text_28FB35, MauvilleCity_PokemonCenter_1F_Text_28FB47}, + {GAME_STAT_RECEIVED_RIBBONS, 1, MauvilleCity_PokemonCenter_1F_Text_28FBC4, MauvilleCity_PokemonCenter_1F_Text_28FBD9, MauvilleCity_PokemonCenter_1F_Text_28FBEA}, + {GAME_STAT_JUMPED_DOWN_LEDGES, 1, MauvilleCity_PokemonCenter_1F_Text_28FC6B, MauvilleCity_PokemonCenter_1F_Text_28FC85, MauvilleCity_PokemonCenter_1F_Text_28FC98}, + {GAME_STAT_WATCHED_TV, 1, MauvilleCity_PokemonCenter_1F_Text_28FD1D, MauvilleCity_PokemonCenter_1F_Text_28FD35, MauvilleCity_PokemonCenter_1F_Text_28FD40}, + {GAME_STAT_CHECKED_CLOCK, 1, MauvilleCity_PokemonCenter_1F_Text_28FDA2, MauvilleCity_PokemonCenter_1F_Text_28FDBD, MauvilleCity_PokemonCenter_1F_Text_28FDCE}, + {GAME_STAT_WON_POKEMON_LOTTERY, 1, MauvilleCity_PokemonCenter_1F_Text_28FE57, MauvilleCity_PokemonCenter_1F_Text_28FE72, MauvilleCity_PokemonCenter_1F_Text_28FE88}, + {GAME_STAT_USED_DAYCARE, 1, MauvilleCity_PokemonCenter_1F_Text_28FF0C, MauvilleCity_PokemonCenter_1F_Text_28FF27, MauvilleCity_PokemonCenter_1F_Text_28FF44}, + {GAME_STAT_RODE_CABLE_CAR, 1, MauvilleCity_PokemonCenter_1F_Text_28FFDD, MauvilleCity_PokemonCenter_1F_Text_28FFFA, MauvilleCity_PokemonCenter_1F_Text_29000D}, + {GAME_STAT_ENTERED_HOT_SPRINGS, 1, MauvilleCity_PokemonCenter_1F_Text_290097, MauvilleCity_PokemonCenter_1F_Text_2900B5, MauvilleCity_PokemonCenter_1F_Text_2900CB} +}; -- cgit v1.2.3 From 876e1eb7cccb729a801cfb2005f7b190955f9129 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Thu, 3 May 2018 17:51:14 -0400 Subject: through sub_8121064 --- src/mauville_old_man.c | 138 ++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 137 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index 1f398569c..04af0e066 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -18,6 +18,7 @@ #include "bard_music.h" #include "sound.h" #include "strings.h" +#include "overworld.h" #define CHAR_SONG_WORD_SEPARATOR 0x37 @@ -35,7 +36,7 @@ void sub_8133A60(void); struct BardSong gUnknown_03006130; EWRAM_DATA u16 gUnknown_0203A128 = 0; -EWRAM_DATA struct MauvilleOldMan * gUnknown_0203A12C = NULL; +EWRAM_DATA struct MauvilleManStoryteller * gUnknown_0203A12C = NULL; EWRAM_DATA u8 gUnknown_0203A130 = 0; static const u16 sDefaultBardSongLyrics[6] = { @@ -949,3 +950,138 @@ const struct Story gUnknown_0859F048[] = { {GAME_STAT_RODE_CABLE_CAR, 1, MauvilleCity_PokemonCenter_1F_Text_28FFDD, MauvilleCity_PokemonCenter_1F_Text_28FFFA, MauvilleCity_PokemonCenter_1F_Text_29000D}, {GAME_STAT_ENTERED_HOT_SPRINGS, 1, MauvilleCity_PokemonCenter_1F_Text_290097, MauvilleCity_PokemonCenter_1F_Text_2900B5, MauvilleCity_PokemonCenter_1F_Text_2900CB} }; + +void sub_8120E08(void) // StorytellerSetup +{ + s32 i; + gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + + gUnknown_0203A12C->id = MAUVILLE_MAN_STORYTELLER; + gUnknown_0203A12C->alreadyRecorded = FALSE; + for (i = 0; i < 4; i++) + { + gUnknown_0203A12C->gameStatIDs[i] = 0; + gUnknown_0203A12C->trainerNames[0][i] = EOS; // Maybe they meant storyteller->trainerNames[i][0] instead? + } +} + +void sub_8120E50(void) +{ + gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + + gUnknown_0203A12C->id = MAUVILLE_MAN_STORYTELLER; + gUnknown_0203A12C->alreadyRecorded = FALSE; +} + +u32 sub_8120E74(u8 stat) // StorytellerGetGameStat +{ + if (stat == 50) + stat = 0; + return GetGameStat(stat); +} + +const struct Story *sub_8120E88(u32 stat) // GetStoryByStat +{ + s32 i; + + for (i = 0; i < 36; i++) + { + if (gUnknown_0859F048[i].stat == stat) + return &gUnknown_0859F048[i]; + } + return &gUnknown_0859F048[35]; +} + +const u8 *sub_8120EB4(u32 stat) // GetStoryTitleByStat +{ + return sub_8120E88(stat)->title; +} + +const u8 *sub_8120EC0(u32 stat) // GetStoryTextByStat +{ + return sub_8120E88(stat)->fullText; +} + +const u8 *sub_8120ECC(u32 stat) // GetStoryActionByStat +{ + return sub_8120E88(stat)->action; +} + +u8 sub_8120ED8(void) // GetFreeStorySlot +{ + u8 i; + + for (i = 0; i < 4; i++) + { + if (gUnknown_0203A12C->gameStatIDs[i] == 0) + break; + } + return i; +} + +u32 sub_8120F08(u32 trainer) // StorytellerGetRecordedTrainerStat +{ + u8 *ptr = gUnknown_0203A12C->statValues[trainer]; + + return ptr[0] | (ptr[1] << 8) | (ptr[2] << 16) | (ptr[3] << 24); +} + +void sub_8120F2C(u32 trainer, u32 val) // StorytellerSetRecordedTrainerStat +{ + u8 *ptr = gUnknown_0203A12C->statValues[trainer]; + + ptr[0] = val; + ptr[1] = val >> 8; + ptr[2] = val >> 16; + ptr[3] = val >> 24; +} + +bool32 sub_8120F4C(u32 trainer) // HasTrainerStatIncreased +{ + if (sub_8120E74(gUnknown_0203A12C->gameStatIDs[trainer]) > sub_8120F08(trainer)) + return TRUE; + else + return FALSE; +} + +void sub_8120F7C(u32 player, void *dst) // GetStoryByStattellerPlayerName +{ + u8 *name = gUnknown_0203A12C->trainerNames[player]; + + memset(dst, EOS, 8); + memcpy(dst, name, 7); +} + +void sub_8120FAC(u32 player, const u8 * src) // StorytellerSetPlayerName +{ + u8 * name = gUnknown_0203A12C->trainerNames[player]; + memset(name, EOS, 7); + memcpy(name, src, 7); +} + + +void sub_8120FDC(u32 player, u32 stat) // StorytellerRecordNewStat +{ + gUnknown_0203A12C->gameStatIDs[player] = stat; + sub_8120FAC(player, gSaveBlock2Ptr->playerName); + sub_8120F2C(player, sub_8120E74(stat)); + ConvertIntToDecimalStringN(gStringVar1, sub_8120E74(stat), STR_CONV_MODE_LEFT_ALIGN, 10); + StringCopy(gStringVar2, sub_8120ECC(stat)); + gUnknown_0203A12C->unk34[player] = gGameLanguage; +} + +void sub_8121064(u8 * arr, s32 count) // ScrambleStatList +{ + s32 i; + + for (i = 0; i < count; i++) + arr[i] = i; + for (i = 0; i < count; i++) + { + u32 a = Random() % count; + u32 b = Random() % count; + u8 temp = arr[a]; + arr[a] = arr[b]; + arr[b] = temp; + } +} -- cgit v1.2.3 From 8aa462cd747ab3c3127401aa8905d0bdd5e2a1f4 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Thu, 3 May 2018 18:05:07 -0400 Subject: through sub_8121178 --- src/mauville_old_man.c | 55 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index 04af0e066..4f85d4577 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -19,6 +19,7 @@ #include "sound.h" #include "strings.h" #include "overworld.h" +#include "field_message_box.h" #define CHAR_SONG_WORD_SEPARATOR 0x37 @@ -33,6 +34,8 @@ void sub_8120E50(void); void sub_81339F8(void); // TraderSetup void sub_8133A60(void); +IWRAM_DATA u8 gUnknown_03001178; + struct BardSong gUnknown_03006130; EWRAM_DATA u16 gUnknown_0203A128 = 0; @@ -1085,3 +1088,55 @@ void sub_8121064(u8 * arr, s32 count) // ScrambleStatList arr[b] = temp; } } + +struct UnknownStruct_0859F288 +{ + u32 length; + u32 unused2; +}; + +const struct UnknownStruct_0859F288 gUnknown_0859F288 = { + 36, + 8 +}; + +bool8 sub_81210B8(void) // StorytellerInitializeRandomStat +{ + u8 arr[gUnknown_0859F288.length]; + s32 i; + s32 j; + + sub_8121064(arr, 36); + for (i = 0; i < 36; i++) + { + u8 stat = gUnknown_0859F048[arr[i]].stat; + u8 minVal = gUnknown_0859F048[arr[i]].minVal; + + for (j = 0; j < 4; j++) + { + if (gUnknown_0203A12C->gameStatIDs[j] == stat) + break; + } + if (j == 4 && sub_8120E74(stat) >= minVal) + { + gUnknown_0203A12C->alreadyRecorded = TRUE; + if (sub_8120ED8() == 4) + sub_8120FDC(gUnknown_03001178, stat); + else + sub_8120FDC(sub_8120ED8(), stat); + return TRUE; + } + } + return FALSE; +} + +void sub_8121178(u32 player) // StorytellerDisplayStory +{ + u8 stat = gUnknown_0203A12C->gameStatIDs[player]; + + ConvertIntToDecimalStringN(gStringVar1, sub_8120F08(player), 0, 10); + StringCopy(gStringVar2, sub_8120ECC(stat)); + sub_8120F7C(player, gStringVar3); + ConvertInternationalString(gStringVar3, gUnknown_0203A12C->unk34[player]); + ShowFieldMessage(sub_8120EC0(stat)); +} -- cgit v1.2.3 From 546217d28124daa204f804469e7d4bc18a048398 Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Sat, 5 May 2018 23:27:26 +0100 Subject: Convert item_graphics.inc to C I have tried to group the items that share the same icon but have different palettes where possible. This commit also splits data/graphics.s into two files. --- src/item_graphics.c | 740 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 740 insertions(+) create mode 100644 src/item_graphics.c (limited to 'src') diff --git a/src/item_graphics.c b/src/item_graphics.c new file mode 100644 index 000000000..3b2b8cff2 --- /dev/null +++ b/src/item_graphics.c @@ -0,0 +1,740 @@ +#include "global.h" + +const u8 gItemIcon_QuestionMark[] = INCBIN_U8("graphics/items/icons/question_mark.4bpp.lz"); +const u16 gItemIconPalette_QuestionMark[] = INCBIN_U16("graphics/items/icon_palettes/question_mark.gbapal.lz"); + +const u8 gItemIcon_ReturnToFieldArrow[] = INCBIN_U8("graphics/items/icons/return_to_field_arrow.4bpp.lz"); +const u16 gItemIconPalette_ReturnToFieldArrow[] = INCBIN_U16("graphics/items/icon_palettes/return_to_field_arrow.gbapal.lz"); + +// Pokeballs + +const u8 gItemIcon_MasterBall[] = INCBIN_U8("graphics/items/icons/master_ball.4bpp.lz"); +const u16 gItemIconPalette_MasterBall[] = INCBIN_U16("graphics/items/icon_palettes/master_ball.gbapal.lz"); + +const u8 gItemIcon_UltraBall[] = INCBIN_U8("graphics/items/icons/ultra_ball.4bpp.lz"); +const u16 gItemIconPalette_UltraBall[] = INCBIN_U16("graphics/items/icon_palettes/ultra_ball.gbapal.lz"); + +const u8 gItemIcon_GreatBall[] = INCBIN_U8("graphics/items/icons/great_ball.4bpp.lz"); +const u16 gItemIconPalette_GreatBall[] = INCBIN_U16("graphics/items/icon_palettes/great_ball.gbapal.lz"); + +const u8 gItemIcon_PokeBall[] = INCBIN_U8("graphics/items/icons/poke_ball.4bpp.lz"); +const u16 gItemIconPalette_PokeBall[] = INCBIN_U16("graphics/items/icon_palettes/poke_ball.gbapal.lz"); + +const u8 gItemIcon_SafariBall[] = INCBIN_U8("graphics/items/icons/safari_ball.4bpp.lz"); +const u16 gItemIconPalette_SafariBall[] = INCBIN_U16("graphics/items/icon_palettes/safari_ball.gbapal.lz"); + +const u8 gItemIcon_NetBall[] = INCBIN_U8("graphics/items/icons/net_ball.4bpp.lz"); +const u16 gItemIconPalette_NetBall[] = INCBIN_U16("graphics/items/icon_palettes/net_ball.gbapal.lz"); + +const u8 gItemIcon_DiveBall[] = INCBIN_U8("graphics/items/icons/dive_ball.4bpp.lz"); +const u16 gItemIconPalette_DiveBall[] = INCBIN_U16("graphics/items/icon_palettes/dive_ball.gbapal.lz"); + +const u8 gItemIcon_NestBall[] = INCBIN_U8("graphics/items/icons/nest_ball.4bpp.lz"); +const u16 gItemIconPalette_NestBall[] = INCBIN_U16("graphics/items/icon_palettes/nest_ball.gbapal.lz"); + +const u8 gItemIcon_RepeatBall[] = INCBIN_U8("graphics/items/icons/repeat_ball.4bpp.lz"); +const u16 gItemIconPalette_RepeatBall[] = INCBIN_U16("graphics/items/icon_palettes/repeat_ball.gbapal.lz"); + +const u8 gItemIcon_TimerBall[] = INCBIN_U8("graphics/items/icons/timer_ball.4bpp.lz"); + +const u8 gItemIcon_LuxuryBall[] = INCBIN_U8("graphics/items/icons/luxury_ball.4bpp.lz"); +const u16 gItemIconPalette_LuxuryBall[] = INCBIN_U16("graphics/items/icon_palettes/luxury_ball.gbapal.lz"); + +const u8 gItemIcon_PremierBall[] = INCBIN_U8("graphics/items/icons/premier_ball.4bpp.lz"); + +// Medicine + +const u8 gItemIcon_Potion[] = INCBIN_U8("graphics/items/icons/potion.4bpp.lz"); +const u16 gItemIconPalette_Potion[] = INCBIN_U16("graphics/items/icon_palettes/potion.gbapal.lz"); + +const u8 gItemIcon_Antidote[] = INCBIN_U8("graphics/items/icons/antidote.4bpp.lz"); +const u16 gItemIconPalette_Antidote[] = INCBIN_U16("graphics/items/icon_palettes/antidote.gbapal.lz"); + +const u16 gItemIconPalette_BurnHeal[] = INCBIN_U16("graphics/items/icon_palettes/burn_heal.gbapal.lz"); +const u16 gItemIconPalette_IceHeal[] = INCBIN_U16("graphics/items/icon_palettes/ice_heal.gbapal.lz"); +const u8 gItemIcon_StatusHeal[] = INCBIN_U8("graphics/items/icons/status_heal.4bpp.lz"); +const u16 gItemIconPalette_Awakening[] = INCBIN_U16("graphics/items/icon_palettes/awakening.gbapal.lz"); +const u16 gItemIconPalette_ParalyzeHeal[] = INCBIN_U16("graphics/items/icon_palettes/paralyze_heal.gbapal.lz"); + +const u8 gItemIcon_LargePotion[] = INCBIN_U8("graphics/items/icons/large_potion.4bpp.lz"); +const u16 gItemIconPalette_FullRestore[] = INCBIN_U16("graphics/items/icon_palettes/full_restore.gbapal.lz"); +const u16 gItemIconPalette_MaxPotion[] = INCBIN_U16("graphics/items/icon_palettes/max_potion.gbapal.lz"); + +const u16 gItemIconPalette_HyperPotion[] = INCBIN_U16("graphics/items/icon_palettes/hyper_potion.gbapal.lz"); + +const u16 gItemIconPalette_SuperPotion[] = INCBIN_U16("graphics/items/icon_palettes/super_potion.gbapal.lz"); + +const u8 gItemIcon_FullHeal[] = INCBIN_U8("graphics/items/icons/full_heal.4bpp.lz"); +const u16 gItemIconPalette_FullHeal[] = INCBIN_U16("graphics/items/icon_palettes/full_heal.gbapal.lz"); + +const u8 gItemIcon_Revive[] = INCBIN_U8("graphics/items/icons/revive.4bpp.lz"); + +const u8 gItemIcon_MaxRevive[] = INCBIN_U8("graphics/items/icons/max_revive.4bpp.lz"); + +const u16 gItemIconPalette_Revive[] = INCBIN_U16("graphics/items/icon_palettes/revive.gbapal.lz"); + +const u8 gItemIcon_FreshWater[] = INCBIN_U8("graphics/items/icons/fresh_water.4bpp.lz"); +const u16 gItemIconPalette_FreshWater[] = INCBIN_U16("graphics/items/icon_palettes/fresh_water.gbapal.lz"); + +const u8 gItemIcon_SodaPop[] = INCBIN_U8("graphics/items/icons/soda_pop.4bpp.lz"); +const u16 gItemIconPalette_SodaPop[] = INCBIN_U16("graphics/items/icon_palettes/soda_pop.gbapal.lz"); + +const u8 gItemIcon_Lemonade[] = INCBIN_U8("graphics/items/icons/lemonade.4bpp.lz"); +const u16 gItemIconPalette_Lemonade[] = INCBIN_U16("graphics/items/icon_palettes/lemonade.gbapal.lz"); + +const u8 gItemIcon_MoomooMilk[] = INCBIN_U8("graphics/items/icons/moomoo_milk.4bpp.lz"); +const u16 gItemIconPalette_MoomooMilk[] = INCBIN_U16("graphics/items/icon_palettes/moomoo_milk.gbapal.lz"); + +const u8 gItemIcon_Powder[] = INCBIN_U8("graphics/items/icons/powder.4bpp.lz"); +const u16 gItemIconPalette_EnergyPowder[] = INCBIN_U16("graphics/items/icon_palettes/energy_powder.gbapal.lz"); + +const u8 gItemIcon_EnergyRoot[] = INCBIN_U8("graphics/items/icons/energy_root.4bpp.lz"); +const u16 gItemIconPalette_EnergyRoot[] = INCBIN_U16("graphics/items/icon_palettes/energy_root.gbapal.lz"); + +const u16 gItemIconPalette_HealPowder[] = INCBIN_U16("graphics/items/icon_palettes/heal_powder.gbapal.lz"); + +const u8 gItemIcon_RevivalHerb[] = INCBIN_U8("graphics/items/icons/revival_herb.4bpp.lz"); +const u16 gItemIconPalette_RevivalHerb[] = INCBIN_U16("graphics/items/icon_palettes/revival_herb.gbapal.lz"); + +const u8 gItemIcon_Ether[] = INCBIN_U8("graphics/items/icons/ether.4bpp.lz"); +const u16 gItemIconPalette_Ether[] = INCBIN_U16("graphics/items/icon_palettes/ether.gbapal.lz"); +const u16 gItemIconPalette_MaxEther[] = INCBIN_U16("graphics/items/icon_palettes/max_ether.gbapal.lz"); +const u16 gItemIconPalette_Elixir[] = INCBIN_U16("graphics/items/icon_palettes/elixir.gbapal.lz"); +const u16 gItemIconPalette_MaxElixir[] = INCBIN_U16("graphics/items/icon_palettes/max_elixir.gbapal.lz"); + +const u8 gItemIcon_LavaCookie[] = INCBIN_U8("graphics/items/icons/lava_cookie.4bpp.lz"); +const u16 gItemIconPalette_LavaCookieAndLetter[] = INCBIN_U16("graphics/items/icon_palettes/lava_cookie_and_letter.gbapal.lz"); + +const u8 gItemIcon_Flute[] = INCBIN_U8("graphics/items/icons/flute.4bpp.lz"); +const u16 gItemIconPalette_BlueFlute[] = INCBIN_U16("graphics/items/icon_palettes/blue_flute.gbapal.lz"); +const u16 gItemIconPalette_YellowFlute[] = INCBIN_U16("graphics/items/icon_palettes/yellow_flute.gbapal.lz"); +const u16 gItemIconPalette_RedFlute[] = INCBIN_U16("graphics/items/icon_palettes/red_flute.gbapal.lz"); +const u16 gItemIconPalette_BlackFlute[] = INCBIN_U16("graphics/items/icon_palettes/black_flute.gbapal.lz"); +const u16 gItemIconPalette_WhiteFlute[] = INCBIN_U16("graphics/items/icon_palettes/white_flute.gbapal.lz"); + +const u8 gItemIcon_BerryJuice[] = INCBIN_U8("graphics/items/icons/berry_juice.4bpp.lz"); +const u16 gItemIconPalette_BerryJuice[] = INCBIN_U16("graphics/items/icon_palettes/berry_juice.gbapal.lz"); + +const u8 gItemIcon_SacredAsh[] = INCBIN_U8("graphics/items/icons/sacred_ash.4bpp.lz"); +const u16 gItemIconPalette_SacredAsh[] = INCBIN_U16("graphics/items/icon_palettes/sacred_ash.gbapal.lz"); + +// Collectibles + +const u16 gItemIconPalette_ShoalSalt[] = INCBIN_U16("graphics/items/icon_palettes/shoal_salt.gbapal.lz"); + +const u8 gItemIcon_ShoalShell[] = INCBIN_U8("graphics/items/icons/shoal_shell.4bpp.lz"); +const u16 gItemIconPalette_Shell[] = INCBIN_U16("graphics/items/icon_palettes/shell.gbapal.lz"); + +const u8 gItemIcon_Shard[] = INCBIN_U8("graphics/items/icons/shard.4bpp.lz"); +const u16 gItemIconPalette_RedShard[] = INCBIN_U16("graphics/items/icon_palettes/red_shard.gbapal.lz"); +const u16 gItemIconPalette_BlueShard[] = INCBIN_U16("graphics/items/icon_palettes/blue_shard.gbapal.lz"); +const u16 gItemIconPalette_YellowShard[] = INCBIN_U16("graphics/items/icon_palettes/yellow_shard.gbapal.lz"); +const u16 gItemIconPalette_GreenShard[] = INCBIN_U16("graphics/items/icon_palettes/green_shard.gbapal.lz"); + +// Vitamins + +const u8 gItemIcon_HPUp[] = INCBIN_U8("graphics/items/icons/hp_up.4bpp.lz"); +const u16 gItemIconPalette_HPUp[] = INCBIN_U16("graphics/items/icon_palettes/hp_up.gbapal.lz"); + +const u8 gItemIcon_Vitamin[] = INCBIN_U8("graphics/items/icons/vitamin.4bpp.lz"); +const u16 gItemIconPalette_Protein[] = INCBIN_U16("graphics/items/icon_palettes/protein.gbapal.lz"); +const u16 gItemIconPalette_Iron[] = INCBIN_U16("graphics/items/icon_palettes/iron.gbapal.lz"); +const u16 gItemIconPalette_Carbos[] = INCBIN_U16("graphics/items/icon_palettes/carbos.gbapal.lz"); +const u16 gItemIconPalette_Calcium[] = INCBIN_U16("graphics/items/icon_palettes/calcium.gbapal.lz"); + +const u8 gItemIcon_RareCandy[] = INCBIN_U8("graphics/items/icons/rare_candy.4bpp.lz"); +const u16 gItemIconPalette_RareCandy[] = INCBIN_U16("graphics/items/icon_palettes/rare_candy.gbapal.lz"); + +const u8 gItemIcon_PPUp[] = INCBIN_U8("graphics/items/icons/pp_up.4bpp.lz"); +const u16 gItemIconPalette_PPUp[] = INCBIN_U16("graphics/items/icon_palettes/pp_up.gbapal.lz"); + +const u16 gItemIconPalette_Zinc[] = INCBIN_U16("graphics/items/icon_palettes/zinc.gbapal.lz"); + +const u8 gItemIcon_PPMax[] = INCBIN_U8("graphics/items/icons/pp_max.4bpp.lz"); +const u16 gItemIconPalette_PPMax[] = INCBIN_U16("graphics/items/icon_palettes/pp_max.gbapal.lz"); + +// Battle items + +const u16 gItemIconPalette_GuardSpec[] = INCBIN_U16("graphics/items/icon_palettes/guard_spec.gbapal.lz"); +const u16 gItemIconPalette_DireHit[] = INCBIN_U16("graphics/items/icon_palettes/dire_hit.gbapal.lz"); +const u16 gItemIconPalette_XAttack[] = INCBIN_U16("graphics/items/icon_palettes/x_attack.gbapal.lz"); +const u8 gItemIcon_BattleStatItem[] = INCBIN_U8("graphics/items/icons/battle_stat_item.4bpp.lz"); +const u16 gItemIconPalette_XDefend[] = INCBIN_U16("graphics/items/icon_palettes/x_defend.gbapal.lz"); +const u16 gItemIconPalette_XSpeed[] = INCBIN_U16("graphics/items/icon_palettes/x_speed.gbapal.lz"); +const u16 gItemIconPalette_XAccuracy[] = INCBIN_U16("graphics/items/icon_palettes/x_accuracy.gbapal.lz"); +const u16 gItemIconPalette_XSpecial[] = INCBIN_U16("graphics/items/icon_palettes/x_special.gbapal.lz"); + +const u8 gItemIcon_PokeDoll[] = INCBIN_U8("graphics/items/icons/poke_doll.4bpp.lz"); +const u16 gItemIconPalette_PokeDoll[] = INCBIN_U16("graphics/items/icon_palettes/poke_doll.gbapal.lz"); + +const u8 gItemIcon_FluffyTail[] = INCBIN_U8("graphics/items/icons/fluffy_tail.4bpp.lz"); +const u16 gItemIconPalette_FluffyTail[] = INCBIN_U16("graphics/items/icon_palettes/fluffy_tail.gbapal.lz"); + +// Field items + +const u8 gItemIcon_Repel[] = INCBIN_U8("graphics/items/icons/repel.4bpp.lz"); +const u16 gItemIconPalette_SuperRepel[] = INCBIN_U16("graphics/items/icon_palettes/super_repel.gbapal.lz"); +const u16 gItemIconPalette_MaxRepel[] = INCBIN_U16("graphics/items/icon_palettes/max_repel.gbapal.lz"); + +const u8 gItemIcon_EscapeRope[] = INCBIN_U8("graphics/items/icons/escape_rope.4bpp.lz"); + +const u16 gItemIconPalette_EscapeRope[] = INCBIN_U16("graphics/items/icon_palettes/escape_rope.gbapal.lz"); + +const u16 gItemIconPalette_Repel[] = INCBIN_U16("graphics/items/icon_palettes/repel.gbapal.lz"); + +// Evolution stones + +const u8 gItemIcon_SunStone[] = INCBIN_U8("graphics/items/icons/sun_stone.4bpp.lz"); +const u16 gItemIconPalette_SunStone[] = INCBIN_U16("graphics/items/icon_palettes/sun_stone.gbapal.lz"); + +const u8 gItemIcon_MoonStone[] = INCBIN_U8("graphics/items/icons/moon_stone.4bpp.lz"); +const u16 gItemIconPalette_MoonStone[] = INCBIN_U16("graphics/items/icon_palettes/moon_stone.gbapal.lz"); + +const u8 gItemIcon_FireStone[] = INCBIN_U8("graphics/items/icons/fire_stone.4bpp.lz"); +const u16 gItemIconPalette_FireStone[] = INCBIN_U16("graphics/items/icon_palettes/fire_stone.gbapal.lz"); + +const u8 gItemIcon_ThunderStone[] = INCBIN_U8("graphics/items/icons/thunder_stone.4bpp.lz"); +const u16 gItemIconPalette_ThunderStone[] = INCBIN_U16("graphics/items/icon_palettes/thunder_stone.gbapal.lz"); + +const u8 gItemIcon_WaterStone[] = INCBIN_U8("graphics/items/icons/water_stone.4bpp.lz"); +const u16 gItemIconPalette_WaterStone[] = INCBIN_U16("graphics/items/icon_palettes/water_stone.gbapal.lz"); + +const u8 gItemIcon_LeafStone[] = INCBIN_U8("graphics/items/icons/leaf_stone.4bpp.lz"); +const u16 gItemIconPalette_LeafStone[] = INCBIN_U16("graphics/items/icon_palettes/leaf_stone.gbapal.lz"); + +// Valuables + +const u8 gItemIcon_TinyMushroom[] = INCBIN_U8("graphics/items/icons/tiny_mushroom.4bpp.lz"); +const u8 gItemIcon_BigMushroom[] = INCBIN_U8("graphics/items/icons/big_mushroom.4bpp.lz"); +const u16 gItemIconPalette_Mushroom[] = INCBIN_U16("graphics/items/icon_palettes/mushroom.gbapal.lz"); + +const u8 gItemIcon_Pearl[] = INCBIN_U8("graphics/items/icons/pearl.4bpp.lz"); +const u16 gItemIconPalette_Pearl[] = INCBIN_U16("graphics/items/icon_palettes/pearl.gbapal.lz"); +const u8 gItemIcon_BigPearl[] = INCBIN_U8("graphics/items/icons/big_pearl.4bpp.lz"); + +const u8 gItemIcon_Stardust[] = INCBIN_U8("graphics/items/icons/stardust.4bpp.lz"); +const u16 gItemIconPalette_Star[] = INCBIN_U16("graphics/items/icon_palettes/star.gbapal.lz"); +const u8 gItemIcon_StarPiece[] = INCBIN_U8("graphics/items/icons/star_piece.4bpp.lz"); + +const u8 gItemIcon_Nugget[] = INCBIN_U8("graphics/items/icons/nugget.4bpp.lz"); +const u16 gItemIconPalette_Nugget[] = INCBIN_U16("graphics/items/icon_palettes/nugget.gbapal.lz"); + +const u8 gItemIcon_HeartScale[] = INCBIN_U8("graphics/items/icons/heart_scale.4bpp.lz"); +const u16 gItemIconPalette_HeartScale[] = INCBIN_U16("graphics/items/icon_palettes/heart_scale.gbapal.lz"); + +// Mail + +const u8 gItemIcon_OrangeMail[] = INCBIN_U8("graphics/items/icons/orange_mail.4bpp.lz"); +const u16 gItemIconPalette_OrangeMail[] = INCBIN_U16("graphics/items/icon_palettes/orange_mail.gbapal.lz"); + +const u8 gItemIcon_HarborMail[] = INCBIN_U8("graphics/items/icons/harbor_mail.4bpp.lz"); +const u16 gItemIconPalette_HarborMail[] = INCBIN_U16("graphics/items/icon_palettes/harbor_mail.gbapal.lz"); + +const u8 gItemIcon_GlitterMail[] = INCBIN_U8("graphics/items/icons/glitter_mail.4bpp.lz"); +const u16 gItemIconPalette_GlitterMail[] = INCBIN_U16("graphics/items/icon_palettes/glitter_mail.gbapal.lz"); + +const u8 gItemIcon_MechMail[] = INCBIN_U8("graphics/items/icons/mech_mail.4bpp.lz"); +const u16 gItemIconPalette_MechMail[] = INCBIN_U16("graphics/items/icon_palettes/mech_mail.gbapal.lz"); + +const u8 gItemIcon_WoodMail[] = INCBIN_U8("graphics/items/icons/wood_mail.4bpp.lz"); +const u16 gItemIconPalette_WoodMail[] = INCBIN_U16("graphics/items/icon_palettes/wood_mail.gbapal.lz"); + +const u8 gItemIcon_WaveMail[] = INCBIN_U8("graphics/items/icons/wave_mail.4bpp.lz"); +const u16 gItemIconPalette_WaveMail[] = INCBIN_U16("graphics/items/icon_palettes/wave_mail.gbapal.lz"); + +const u8 gItemIcon_BeadMail[] = INCBIN_U8("graphics/items/icons/bead_mail.4bpp.lz"); +const u16 gItemIconPalette_BeadMail[] = INCBIN_U16("graphics/items/icon_palettes/bead_mail.gbapal.lz"); + +const u8 gItemIcon_ShadowMail[] = INCBIN_U8("graphics/items/icons/shadow_mail.4bpp.lz"); +const u16 gItemIconPalette_ShadowMail[] = INCBIN_U16("graphics/items/icon_palettes/shadow_mail.gbapal.lz"); + +const u8 gItemIcon_TropicMail[] = INCBIN_U8("graphics/items/icons/tropic_mail.4bpp.lz"); +const u16 gItemIconPalette_TropicMail[] = INCBIN_U16("graphics/items/icon_palettes/tropic_mail.gbapal.lz"); + +const u8 gItemIcon_DreamMail[] = INCBIN_U8("graphics/items/icons/dream_mail.4bpp.lz"); +const u16 gItemIconPalette_DreamMail[] = INCBIN_U16("graphics/items/icon_palettes/dream_mail.gbapal.lz"); + +const u8 gItemIcon_FabMail[] = INCBIN_U8("graphics/items/icons/fab_mail.4bpp.lz"); +const u16 gItemIconPalette_FabMail[] = INCBIN_U16("graphics/items/icon_palettes/fab_mail.gbapal.lz"); + +const u8 gItemIcon_RetroMail[] = INCBIN_U8("graphics/items/icons/retro_mail.4bpp.lz"); +const u16 gItemIconPalette_RetroMail[] = INCBIN_U16("graphics/items/icon_palettes/retro_mail.gbapal.lz"); + +// Berries + +const u8 gItemIcon_CheriBerry[] = INCBIN_U8("graphics/items/icons/cheri_berry.4bpp.lz"); +const u16 gItemIconPalette_CheriBerry[] = INCBIN_U16("graphics/items/icon_palettes/cheri_berry.gbapal.lz"); + +const u8 gItemIcon_ChestoBerry[] = INCBIN_U8("graphics/items/icons/chesto_berry.4bpp.lz"); +const u16 gItemIconPalette_ChestoBerry[] = INCBIN_U16("graphics/items/icon_palettes/chesto_berry.gbapal.lz"); + +const u8 gItemIcon_PechaBerry[] = INCBIN_U8("graphics/items/icons/pecha_berry.4bpp.lz"); +const u16 gItemIconPalette_PechaBerry[] = INCBIN_U16("graphics/items/icon_palettes/pecha_berry.gbapal.lz"); + +const u8 gItemIcon_RawstBerry[] = INCBIN_U8("graphics/items/icons/rawst_berry.4bpp.lz"); +const u16 gItemIconPalette_RawstBerry[] = INCBIN_U16("graphics/items/icon_palettes/rawst_berry.gbapal.lz"); + +const u8 gItemIcon_AspearBerry[] = INCBIN_U8("graphics/items/icons/aspear_berry.4bpp.lz"); +const u16 gItemIconPalette_AspearBerry[] = INCBIN_U16("graphics/items/icon_palettes/aspear_berry.gbapal.lz"); + +const u8 gItemIcon_LeppaBerry[] = INCBIN_U8("graphics/items/icons/leppa_berry.4bpp.lz"); +const u16 gItemIconPalette_LeppaBerry[] = INCBIN_U16("graphics/items/icon_palettes/leppa_berry.gbapal.lz"); + +const u8 gItemIcon_OranBerry[] = INCBIN_U8("graphics/items/icons/oran_berry.4bpp.lz"); +const u16 gItemIconPalette_OranBerry[] = INCBIN_U16("graphics/items/icon_palettes/oran_berry.gbapal.lz"); + +const u8 gItemIcon_PersimBerry[] = INCBIN_U8("graphics/items/icons/persim_berry.4bpp.lz"); +const u16 gItemIconPalette_PersimBerry[] = INCBIN_U16("graphics/items/icon_palettes/persim_berry.gbapal.lz"); + +const u8 gItemIcon_LumBerry[] = INCBIN_U8("graphics/items/icons/lum_berry.4bpp.lz"); +const u16 gItemIconPalette_LumBerry[] = INCBIN_U16("graphics/items/icon_palettes/lum_berry.gbapal.lz"); + +const u8 gItemIcon_SitrusBerry[] = INCBIN_U8("graphics/items/icons/sitrus_berry.4bpp.lz"); +const u16 gItemIconPalette_SitrusBerry[] = INCBIN_U16("graphics/items/icon_palettes/sitrus_berry.gbapal.lz"); + +const u8 gItemIcon_FigyBerry[] = INCBIN_U8("graphics/items/icons/figy_berry.4bpp.lz"); +const u16 gItemIconPalette_FigyBerry[] = INCBIN_U16("graphics/items/icon_palettes/figy_berry.gbapal.lz"); + +const u8 gItemIcon_WikiBerry[] = INCBIN_U8("graphics/items/icons/wiki_berry.4bpp.lz"); +const u16 gItemIconPalette_WikiBerry[] = INCBIN_U16("graphics/items/icon_palettes/wiki_berry.gbapal.lz"); + +const u8 gItemIcon_MagoBerry[] = INCBIN_U8("graphics/items/icons/mago_berry.4bpp.lz"); +const u16 gItemIconPalette_MagoBerry[] = INCBIN_U16("graphics/items/icon_palettes/mago_berry.gbapal.lz"); + +const u8 gItemIcon_AguavBerry[] = INCBIN_U8("graphics/items/icons/aguav_berry.4bpp.lz"); +const u16 gItemIconPalette_AguavBerry[] = INCBIN_U16("graphics/items/icon_palettes/aguav_berry.gbapal.lz"); + +const u8 gItemIcon_IapapaBerry[] = INCBIN_U8("graphics/items/icons/iapapa_berry.4bpp.lz"); +const u16 gItemIconPalette_IapapaBerry[] = INCBIN_U16("graphics/items/icon_palettes/iapapa_berry.gbapal.lz"); + +const u8 gItemIcon_RazzBerry[] = INCBIN_U8("graphics/items/icons/razz_berry.4bpp.lz"); +const u16 gItemIconPalette_RazzBerry[] = INCBIN_U16("graphics/items/icon_palettes/razz_berry.gbapal.lz"); + +const u8 gItemIcon_BlukBerry[] = INCBIN_U8("graphics/items/icons/bluk_berry.4bpp.lz"); +const u16 gItemIconPalette_BlukBerry[] = INCBIN_U16("graphics/items/icon_palettes/bluk_berry.gbapal.lz"); + +const u8 gItemIcon_NanabBerry[] = INCBIN_U8("graphics/items/icons/nanab_berry.4bpp.lz"); +const u16 gItemIconPalette_NanabBerry[] = INCBIN_U16("graphics/items/icon_palettes/nanab_berry.gbapal.lz"); + +const u8 gItemIcon_WepearBerry[] = INCBIN_U8("graphics/items/icons/wepear_berry.4bpp.lz"); +const u16 gItemIconPalette_WepearBerry[] = INCBIN_U16("graphics/items/icon_palettes/wepear_berry.gbapal.lz"); + +const u8 gItemIcon_PinapBerry[] = INCBIN_U8("graphics/items/icons/pinap_berry.4bpp.lz"); +const u16 gItemIconPalette_PinapBerry[] = INCBIN_U16("graphics/items/icon_palettes/pinap_berry.gbapal.lz"); + +const u8 gItemIcon_PomegBerry[] = INCBIN_U8("graphics/items/icons/pomeg_berry.4bpp.lz"); +const u16 gItemIconPalette_PomegBerry[] = INCBIN_U16("graphics/items/icon_palettes/pomeg_berry.gbapal.lz"); + +const u8 gItemIcon_KelpsyBerry[] = INCBIN_U8("graphics/items/icons/kelpsy_berry.4bpp.lz"); +const u16 gItemIconPalette_KelpsyBerry[] = INCBIN_U16("graphics/items/icon_palettes/kelpsy_berry.gbapal.lz"); + +const u8 gItemIcon_QualotBerry[] = INCBIN_U8("graphics/items/icons/qualot_berry.4bpp.lz"); +const u16 gItemIconPalette_QualotBerry[] = INCBIN_U16("graphics/items/icon_palettes/qualot_berry.gbapal.lz"); + +const u8 gItemIcon_HondewBerry[] = INCBIN_U8("graphics/items/icons/hondew_berry.4bpp.lz"); +const u16 gItemIconPalette_HondewBerry[] = INCBIN_U16("graphics/items/icon_palettes/hondew_berry.gbapal.lz"); + +const u8 gItemIcon_GrepaBerry[] = INCBIN_U8("graphics/items/icons/grepa_berry.4bpp.lz"); +const u16 gItemIconPalette_GrepaBerry[] = INCBIN_U16("graphics/items/icon_palettes/grepa_berry.gbapal.lz"); + +const u8 gItemIcon_TamatoBerry[] = INCBIN_U8("graphics/items/icons/tamato_berry.4bpp.lz"); +const u16 gItemIconPalette_TamatoBerry[] = INCBIN_U16("graphics/items/icon_palettes/tamato_berry.gbapal.lz"); + +const u8 gItemIcon_CornnBerry[] = INCBIN_U8("graphics/items/icons/cornn_berry.4bpp.lz"); +const u16 gItemIconPalette_CornnBerry[] = INCBIN_U16("graphics/items/icon_palettes/cornn_berry.gbapal.lz"); + +const u8 gItemIcon_MagostBerry[] = INCBIN_U8("graphics/items/icons/magost_berry.4bpp.lz"); +const u16 gItemIconPalette_MagostBerry[] = INCBIN_U16("graphics/items/icon_palettes/magost_berry.gbapal.lz"); + +const u8 gItemIcon_RabutaBerry[] = INCBIN_U8("graphics/items/icons/rabuta_berry.4bpp.lz"); +const u16 gItemIconPalette_RabutaBerry[] = INCBIN_U16("graphics/items/icon_palettes/rabuta_berry.gbapal.lz"); + +const u8 gItemIcon_NomelBerry[] = INCBIN_U8("graphics/items/icons/nomel_berry.4bpp.lz"); +const u16 gItemIconPalette_NomelBerry[] = INCBIN_U16("graphics/items/icon_palettes/nomel_berry.gbapal.lz"); + +const u8 gItemIcon_SpelonBerry[] = INCBIN_U8("graphics/items/icons/spelon_berry.4bpp.lz"); +const u16 gItemIconPalette_SpelonBerry[] = INCBIN_U16("graphics/items/icon_palettes/spelon_berry.gbapal.lz"); + +const u8 gItemIcon_PamtreBerry[] = INCBIN_U8("graphics/items/icons/pamtre_berry.4bpp.lz"); +const u16 gItemIconPalette_PamtreBerry[] = INCBIN_U16("graphics/items/icon_palettes/pamtre_berry.gbapal.lz"); + +const u8 gItemIcon_WatmelBerry[] = INCBIN_U8("graphics/items/icons/watmel_berry.4bpp.lz"); +const u16 gItemIconPalette_WatmelBerry[] = INCBIN_U16("graphics/items/icon_palettes/watmel_berry.gbapal.lz"); + +const u8 gItemIcon_DurinBerry[] = INCBIN_U8("graphics/items/icons/durin_berry.4bpp.lz"); +const u16 gItemIconPalette_DurinBerry[] = INCBIN_U16("graphics/items/icon_palettes/durin_berry.gbapal.lz"); + +const u8 gItemIcon_BelueBerry[] = INCBIN_U8("graphics/items/icons/belue_berry.4bpp.lz"); +const u16 gItemIconPalette_BelueBerry[] = INCBIN_U16("graphics/items/icon_palettes/belue_berry.gbapal.lz"); + +const u8 gItemIcon_LiechiBerry[] = INCBIN_U8("graphics/items/icons/liechi_berry.4bpp.lz"); +const u16 gItemIconPalette_LiechiBerry[] = INCBIN_U16("graphics/items/icon_palettes/liechi_berry.gbapal.lz"); + +const u8 gItemIcon_GanlonBerry[] = INCBIN_U8("graphics/items/icons/ganlon_berry.4bpp.lz"); +const u16 gItemIconPalette_GanlonBerry[] = INCBIN_U16("graphics/items/icon_palettes/ganlon_berry.gbapal.lz"); + +const u8 gItemIcon_SalacBerry[] = INCBIN_U8("graphics/items/icons/salac_berry.4bpp.lz"); +const u16 gItemIconPalette_SalacBerry[] = INCBIN_U16("graphics/items/icon_palettes/salac_berry.gbapal.lz"); + +const u8 gItemIcon_PetayaBerry[] = INCBIN_U8("graphics/items/icons/petaya_berry.4bpp.lz"); +const u16 gItemIconPalette_PetayaBerry[] = INCBIN_U16("graphics/items/icon_palettes/petaya_berry.gbapal.lz"); + +const u8 gItemIcon_ApicotBerry[] = INCBIN_U8("graphics/items/icons/apicot_berry.4bpp.lz"); +const u16 gItemIconPalette_ApicotBerry[] = INCBIN_U16("graphics/items/icon_palettes/apicot_berry.gbapal.lz"); + +const u8 gItemIcon_LansatBerry[] = INCBIN_U8("graphics/items/icons/lansat_berry.4bpp.lz"); +const u16 gItemIconPalette_LansatBerry[] = INCBIN_U16("graphics/items/icon_palettes/lansat_berry.gbapal.lz"); + +const u8 gItemIcon_StarfBerry[] = INCBIN_U8("graphics/items/icons/starf_berry.4bpp.lz"); +const u16 gItemIconPalette_StarfBerry[] = INCBIN_U16("graphics/items/icon_palettes/starf_berry.gbapal.lz"); + +const u8 gItemIcon_EnigmaBerry[] = INCBIN_U8("graphics/items/icons/enigma_berry.4bpp.lz"); +const u16 gItemIconPalette_EnigmaBerry[] = INCBIN_U16("graphics/items/icon_palettes/enigma_berry.gbapal.lz"); + +// Hold items + +const u8 gItemIcon_BrightPowder[] = INCBIN_U8("graphics/items/icons/bright_powder.4bpp.lz"); +const u16 gItemIconPalette_BrightPowder[] = INCBIN_U16("graphics/items/icon_palettes/bright_powder.gbapal.lz"); + +const u8 gItemIcon_InBattleHerb[] = INCBIN_U8("graphics/items/icons/in_battle_herb.4bpp.lz"); +const u16 gItemIconPalette_WhiteHerb[] = INCBIN_U16("graphics/items/icon_palettes/white_herb.gbapal.lz"); + +const u8 gItemIcon_MachoBrace[] = INCBIN_U8("graphics/items/icons/macho_brace.4bpp.lz"); +const u16 gItemIconPalette_MachoBrace[] = INCBIN_U16("graphics/items/icon_palettes/macho_brace.gbapal.lz"); + +const u8 gItemIcon_ExpShare[] = INCBIN_U8("graphics/items/icons/exp_share.4bpp.lz"); +const u16 gItemIconPalette_ExpShare[] = INCBIN_U16("graphics/items/icon_palettes/exp_share.gbapal.lz"); + +const u8 gItemIcon_QuickClaw[] = INCBIN_U8("graphics/items/icons/quick_claw.4bpp.lz"); +const u16 gItemIconPalette_QuickClaw[] = INCBIN_U16("graphics/items/icon_palettes/quick_claw.gbapal.lz"); + +const u8 gItemIcon_SootheBell[] = INCBIN_U8("graphics/items/icons/soothe_bell.4bpp.lz"); +const u16 gItemIconPalette_SootheBell[] = INCBIN_U16("graphics/items/icon_palettes/soothe_bell.gbapal.lz"); + +const u16 gItemIconPalette_MentalHerb[] = INCBIN_U16("graphics/items/icon_palettes/mental_herb.gbapal.lz"); + +const u8 gItemIcon_ChoiceBand[] = INCBIN_U8("graphics/items/icons/choice_band.4bpp.lz"); +const u16 gItemIconPalette_ChoiceBand[] = INCBIN_U16("graphics/items/icon_palettes/choice_band.gbapal.lz"); + +const u8 gItemIcon_KingsRock[] = INCBIN_U8("graphics/items/icons/kings_rock.4bpp.lz"); +const u16 gItemIconPalette_KingsRock[] = INCBIN_U16("graphics/items/icon_palettes/kings_rock.gbapal.lz"); + +const u8 gItemIcon_SilverPowder[] = INCBIN_U8("graphics/items/icons/silver_powder.4bpp.lz"); +const u16 gItemIconPalette_SilverPowder[] = INCBIN_U16("graphics/items/icon_palettes/silver_powder.gbapal.lz"); + +const u8 gItemIcon_AmuletCoin[] = INCBIN_U8("graphics/items/icons/amulet_coin.4bpp.lz"); +const u16 gItemIconPalette_AmuletCoin[] = INCBIN_U16("graphics/items/icon_palettes/amulet_coin.gbapal.lz"); + +const u8 gItemIcon_CleanseTag[] = INCBIN_U8("graphics/items/icons/cleanse_tag.4bpp.lz"); +const u16 gItemIconPalette_CleanseTag[] = INCBIN_U16("graphics/items/icon_palettes/cleanse_tag.gbapal.lz"); + +const u8 gItemIcon_SoulDew[] = INCBIN_U8("graphics/items/icons/soul_dew.4bpp.lz"); +const u16 gItemIconPalette_SoulDew[] = INCBIN_U16("graphics/items/icon_palettes/soul_dew.gbapal.lz"); + +const u8 gItemIcon_DeepSeaTooth[] = INCBIN_U8("graphics/items/icons/deep_sea_tooth.4bpp.lz"); +const u16 gItemIconPalette_DeepSeaTooth[] = INCBIN_U16("graphics/items/icon_palettes/deep_sea_tooth.gbapal.lz"); + +const u8 gItemIcon_DeepSeaScale[] = INCBIN_U8("graphics/items/icons/deep_sea_scale.4bpp.lz"); +const u16 gItemIconPalette_DeepSeaScale[] = INCBIN_U16("graphics/items/icon_palettes/deep_sea_scale.gbapal.lz"); + +const u8 gItemIcon_SmokeBall[] = INCBIN_U8("graphics/items/icons/smoke_ball.4bpp.lz"); +const u16 gItemIconPalette_SmokeBall[] = INCBIN_U16("graphics/items/icon_palettes/smoke_ball.gbapal.lz"); + +const u8 gItemIcon_Everstone[] = INCBIN_U8("graphics/items/icons/everstone.4bpp.lz"); +const u16 gItemIconPalette_Everstone[] = INCBIN_U16("graphics/items/icon_palettes/everstone.gbapal.lz"); + +const u8 gItemIcon_FocusBand[] = INCBIN_U8("graphics/items/icons/focus_band.4bpp.lz"); +const u16 gItemIconPalette_FocusBand[] = INCBIN_U16("graphics/items/icon_palettes/focus_band.gbapal.lz"); + +const u8 gItemIcon_LuckyEgg[] = INCBIN_U8("graphics/items/icons/lucky_egg.4bpp.lz"); +const u16 gItemIconPalette_LuckyEgg[] = INCBIN_U16("graphics/items/icon_palettes/lucky_egg.gbapal.lz"); + +const u8 gItemIcon_ScopeLens[] = INCBIN_U8("graphics/items/icons/scope_lens.4bpp.lz"); +const u16 gItemIconPalette_ScopeLens[] = INCBIN_U16("graphics/items/icon_palettes/scope_lens.gbapal.lz"); + +const u8 gItemIcon_MetalCoat[] = INCBIN_U8("graphics/items/icons/metal_coat.4bpp.lz"); +const u16 gItemIconPalette_MetalCoat[] = INCBIN_U16("graphics/items/icon_palettes/metal_coat.gbapal.lz"); + +const u8 gItemIcon_Leftovers[] = INCBIN_U8("graphics/items/icons/leftovers.4bpp.lz"); +const u16 gItemIconPalette_Leftovers[] = INCBIN_U16("graphics/items/icon_palettes/leftovers.gbapal.lz"); + +const u8 gItemIcon_DragonScale[] = INCBIN_U8("graphics/items/icons/dragon_scale.4bpp.lz"); +const u16 gItemIconPalette_DragonScale[] = INCBIN_U16("graphics/items/icon_palettes/dragon_scale.gbapal.lz"); + +const u8 gItemIcon_LightBall[] = INCBIN_U8("graphics/items/icons/light_ball.4bpp.lz"); +const u16 gItemIconPalette_LightBall[] = INCBIN_U16("graphics/items/icon_palettes/light_ball.gbapal.lz"); + +const u8 gItemIcon_SoftSand[] = INCBIN_U8("graphics/items/icons/soft_sand.4bpp.lz"); +const u16 gItemIconPalette_SoftSand[] = INCBIN_U16("graphics/items/icon_palettes/soft_sand.gbapal.lz"); + +const u8 gItemIcon_HardStone[] = INCBIN_U8("graphics/items/icons/hard_stone.4bpp.lz"); +const u16 gItemIconPalette_HardStone[] = INCBIN_U16("graphics/items/icon_palettes/hard_stone.gbapal.lz"); + +const u8 gItemIcon_MiracleSeed[] = INCBIN_U8("graphics/items/icons/miracle_seed.4bpp.lz"); +const u16 gItemIconPalette_MiracleSeed[] = INCBIN_U16("graphics/items/icon_palettes/miracle_seed.gbapal.lz"); + +const u8 gItemIcon_BlackGlasses[] = INCBIN_U8("graphics/items/icons/black_glasses.4bpp.lz"); +const u16 gItemIconPalette_BlackTypeEnhancingItem[] = INCBIN_U16("graphics/items/icon_palettes/black_type_enhancing_item.gbapal.lz"); + +const u8 gItemIcon_BlackBelt[] = INCBIN_U8("graphics/items/icons/black_belt.4bpp.lz"); + +const u8 gItemIcon_Magnet[] = INCBIN_U8("graphics/items/icons/magnet.4bpp.lz"); +const u16 gItemIconPalette_Magnet[] = INCBIN_U16("graphics/items/icon_palettes/magnet.gbapal.lz"); + +const u8 gItemIcon_MysticWater[] = INCBIN_U8("graphics/items/icons/mystic_water.4bpp.lz"); +const u16 gItemIconPalette_MysticWater[] = INCBIN_U16("graphics/items/icon_palettes/mystic_water.gbapal.lz"); + +const u8 gItemIcon_SharpBeak[] = INCBIN_U8("graphics/items/icons/sharp_beak.4bpp.lz"); +const u16 gItemIconPalette_SharpBeak[] = INCBIN_U16("graphics/items/icon_palettes/sharp_beak.gbapal.lz"); + +const u8 gItemIcon_PoisonBarb[] = INCBIN_U8("graphics/items/icons/poison_barb.4bpp.lz"); +const u16 gItemIconPalette_PoisonBarb[] = INCBIN_U16("graphics/items/icon_palettes/poison_barb.gbapal.lz"); + +const u8 gItemIcon_NeverMeltIce[] = INCBIN_U8("graphics/items/icons/never_melt_ice.4bpp.lz"); +const u16 gItemIconPalette_NeverMeltIce[] = INCBIN_U16("graphics/items/icon_palettes/never_melt_ice.gbapal.lz"); + +const u8 gItemIcon_SpellTag[] = INCBIN_U8("graphics/items/icons/spell_tag.4bpp.lz"); +const u16 gItemIconPalette_SpellTag[] = INCBIN_U16("graphics/items/icon_palettes/spell_tag.gbapal.lz"); + +const u8 gItemIcon_TwistedSpoon[] = INCBIN_U8("graphics/items/icons/twisted_spoon.4bpp.lz"); +const u16 gItemIconPalette_TwistedSpoon[] = INCBIN_U16("graphics/items/icon_palettes/twisted_spoon.gbapal.lz"); + +const u8 gItemIcon_Charcoal[] = INCBIN_U8("graphics/items/icons/charcoal.4bpp.lz"); +const u16 gItemIconPalette_Charcoal[] = INCBIN_U16("graphics/items/icon_palettes/charcoal.gbapal.lz"); + +const u8 gItemIcon_DragonFang[] = INCBIN_U8("graphics/items/icons/dragon_fang.4bpp.lz"); +const u16 gItemIconPalette_DragonFang[] = INCBIN_U16("graphics/items/icon_palettes/dragon_fang.gbapal.lz"); + +const u8 gItemIcon_SilkScarf[] = INCBIN_U8("graphics/items/icons/silk_scarf.4bpp.lz"); +const u16 gItemIconPalette_SilkScarf[] = INCBIN_U16("graphics/items/icon_palettes/silk_scarf.gbapal.lz"); + +const u8 gItemIcon_UpGrade[] = INCBIN_U8("graphics/items/icons/up_grade.4bpp.lz"); +const u16 gItemIconPalette_UpGrade[] = INCBIN_U16("graphics/items/icon_palettes/up_grade.gbapal.lz"); + +const u8 gItemIcon_ShellBell[] = INCBIN_U8("graphics/items/icons/shell_bell.4bpp.lz"); + +const u8 gItemIcon_SeaIncense[] = INCBIN_U8("graphics/items/icons/sea_incense.4bpp.lz"); +const u16 gItemIconPalette_SeaIncense[] = INCBIN_U16("graphics/items/icon_palettes/sea_incense.gbapal.lz"); + +const u8 gItemIcon_LaxIncense[] = INCBIN_U8("graphics/items/icons/lax_incense.4bpp.lz"); +const u16 gItemIconPalette_LaxIncense[] = INCBIN_U16("graphics/items/icon_palettes/lax_incense.gbapal.lz"); + +const u8 gItemIcon_LuckyPunch[] = INCBIN_U8("graphics/items/icons/lucky_punch.4bpp.lz"); +const u16 gItemIconPalette_LuckyPunch[] = INCBIN_U16("graphics/items/icon_palettes/lucky_punch.gbapal.lz"); + +const u8 gItemIcon_MetalPowder[] = INCBIN_U8("graphics/items/icons/metal_powder.4bpp.lz"); +const u16 gItemIconPalette_MetalPowder[] = INCBIN_U16("graphics/items/icon_palettes/metal_powder.gbapal.lz"); + +const u8 gItemIcon_ThickClub[] = INCBIN_U8("graphics/items/icons/thick_club.4bpp.lz"); +const u16 gItemIconPalette_ThickClub[] = INCBIN_U16("graphics/items/icon_palettes/thick_club.gbapal.lz"); + +const u8 gItemIcon_Stick[] = INCBIN_U8("graphics/items/icons/stick.4bpp.lz"); +const u16 gItemIconPalette_Stick[] = INCBIN_U16("graphics/items/icon_palettes/stick.gbapal.lz"); + +const u8 gItemIcon_Scarf[] = INCBIN_U8("graphics/items/icons/scarf.4bpp.lz"); +const u16 gItemIconPalette_RedScarf[] = INCBIN_U16("graphics/items/icon_palettes/red_scarf.gbapal.lz"); +const u16 gItemIconPalette_BlueScarf[] = INCBIN_U16("graphics/items/icon_palettes/blue_scarf.gbapal.lz"); +const u16 gItemIconPalette_PinkScarf[] = INCBIN_U16("graphics/items/icon_palettes/pink_scarf.gbapal.lz"); +const u16 gItemIconPalette_GreenScarf[] = INCBIN_U16("graphics/items/icon_palettes/green_scarf.gbapal.lz"); +const u16 gItemIconPalette_YellowScarf[] = INCBIN_U16("graphics/items/icon_palettes/yellow_scarf.gbapal.lz"); + +// Key items + +const u8 gItemIcon_MachBike[] = INCBIN_U8("graphics/items/icons/mach_bike.4bpp.lz"); +const u16 gItemIconPalette_MachBike[] = INCBIN_U16("graphics/items/icon_palettes/mach_bike.gbapal.lz"); + +const u8 gItemIcon_CoinCase[] = INCBIN_U8("graphics/items/icons/coin_case.4bpp.lz"); +const u16 gItemIconPalette_CoinCase[] = INCBIN_U16("graphics/items/icon_palettes/coin_case.gbapal.lz"); + +const u8 gItemIcon_Itemfinder[] = INCBIN_U8("graphics/items/icons/itemfinder.4bpp.lz"); +const u16 gItemIconPalette_Itemfinder[] = INCBIN_U16("graphics/items/icon_palettes/itemfinder.gbapal.lz"); + +const u8 gItemIcon_OldRod[] = INCBIN_U8("graphics/items/icons/old_rod.4bpp.lz"); +const u16 gItemIconPalette_OldRod[] = INCBIN_U16("graphics/items/icon_palettes/old_rod.gbapal.lz"); + +const u8 gItemIcon_GoodRod[] = INCBIN_U8("graphics/items/icons/good_rod.4bpp.lz"); +const u16 gItemIconPalette_GoodRod[] = INCBIN_U16("graphics/items/icon_palettes/good_rod.gbapal.lz"); + +const u8 gItemIcon_SuperRod[] = INCBIN_U8("graphics/items/icons/super_rod.4bpp.lz"); +const u16 gItemIconPalette_SuperRod[] = INCBIN_U16("graphics/items/icon_palettes/super_rod.gbapal.lz"); + +const u8 gItemIcon_SSTicket[] = INCBIN_U8("graphics/items/icons/ss_ticket.4bpp.lz"); +const u16 gItemIconPalette_SSTicket[] = INCBIN_U16("graphics/items/icon_palettes/ss_ticket.gbapal.lz"); + +const u8 gItemIcon_ContestPass[] = INCBIN_U8("graphics/items/icons/contest_pass.4bpp.lz"); +const u16 gItemIconPalette_ContestPass[] = INCBIN_U16("graphics/items/icon_palettes/contest_pass.gbapal.lz"); + +const u8 gItemIcon_WailmerPail[] = INCBIN_U8("graphics/items/icons/wailmer_pail.4bpp.lz"); +const u16 gItemIconPalette_WailmerPail[] = INCBIN_U16("graphics/items/icon_palettes/wailmer_pail.gbapal.lz"); + +const u8 gItemIcon_DevonGoods[] = INCBIN_U8("graphics/items/icons/devon_goods.4bpp.lz"); +const u16 gItemIconPalette_DevonGoods[] = INCBIN_U16("graphics/items/icon_palettes/devon_goods.gbapal.lz"); + +const u8 gItemIcon_SootSack[] = INCBIN_U8("graphics/items/icons/soot_sack.4bpp.lz"); +const u16 gItemIconPalette_SootSack[] = INCBIN_U16("graphics/items/icon_palettes/soot_sack.gbapal.lz"); + +const u8 gItemIcon_BasementKey[] = INCBIN_U8("graphics/items/icons/basement_key.4bpp.lz"); +const u16 gItemIconPalette_OldKey[] = INCBIN_U16("graphics/items/icon_palettes/old_key.gbapal.lz"); + +const u8 gItemIcon_AcroBike[] = INCBIN_U8("graphics/items/icons/acro_bike.4bpp.lz"); +const u16 gItemIconPalette_AcroBike[] = INCBIN_U16("graphics/items/icon_palettes/acro_bike.gbapal.lz"); + +const u8 gItemIcon_PokeblockCase[] = INCBIN_U8("graphics/items/icons/pokeblock_case.4bpp.lz"); +const u16 gItemIconPalette_PokeblockCase[] = INCBIN_U16("graphics/items/icon_palettes/pokeblock_case.gbapal.lz"); + +const u8 gItemIcon_Letter[] = INCBIN_U8("graphics/items/icons/letter.4bpp.lz"); +const u8 gItemIcon_EonTicket[] = INCBIN_U8("graphics/items/icons/eon_ticket.4bpp.lz"); + +const u16 gItemIconPalette_EonTicket[] = INCBIN_U16("graphics/items/icon_palettes/eon_ticket.gbapal.lz"); + +const u8 gItemIcon_Orb[] = INCBIN_U8("graphics/items/icons/orb.4bpp.lz"); +const u16 gItemIconPalette_RedOrb[] = INCBIN_U16("graphics/items/icon_palettes/red_orb.gbapal.lz"); +const u16 gItemIconPalette_BlueOrb[] = INCBIN_U16("graphics/items/icon_palettes/blue_orb.gbapal.lz"); + +const u8 gItemIcon_Scanner[] = INCBIN_U8("graphics/items/icons/scanner.4bpp.lz"); +const u16 gItemIconPalette_Scanner[] = INCBIN_U16("graphics/items/icon_palettes/scanner.gbapal.lz"); + +const u8 gItemIcon_GoGoggles[] = INCBIN_U8("graphics/items/icons/go_goggles.4bpp.lz"); +const u16 gItemIconPalette_GoGoggles[] = INCBIN_U16("graphics/items/icon_palettes/go_goggles.gbapal.lz"); + +const u8 gItemIcon_Meteorite[] = INCBIN_U8("graphics/items/icons/meteorite.4bpp.lz"); +const u16 gItemIconPalette_Meteorite[] = INCBIN_U16("graphics/items/icon_palettes/meteorite.gbapal.lz"); + +const u8 gItemIcon_Room1Key[] = INCBIN_U8("graphics/items/icons/room1_key.4bpp.lz"); + +const u8 gItemIcon_Room2Key[] = INCBIN_U8("graphics/items/icons/room2_key.4bpp.lz"); + +const u8 gItemIcon_Room4Key[] = INCBIN_U8("graphics/items/icons/room4_key.4bpp.lz"); + +const u8 gItemIcon_Room6Key[] = INCBIN_U8("graphics/items/icons/room6_key.4bpp.lz"); + +const u8 gItemIcon_StorageKey[] = INCBIN_U8("graphics/items/icons/storage_key.4bpp.lz"); + +const u8 gItemIcon_RootFossil[] = INCBIN_U8("graphics/items/icons/root_fossil.4bpp.lz"); +const u16 gItemIconPalette_HoennFossil[] = INCBIN_U16("graphics/items/icon_palettes/hoenn_fossil.gbapal.lz"); +const u8 gItemIcon_ClawFossil[] = INCBIN_U8("graphics/items/icons/claw_fossil.4bpp.lz"); + +const u8 gItemIcon_DevonScope[] = INCBIN_U8("graphics/items/icons/devon_scope.4bpp.lz"); +const u16 gItemIconPalette_DevonScope[] = INCBIN_U16("graphics/items/icon_palettes/devon_scope.gbapal.lz"); + +// TMs/HMs + +const u8 gItemIcon_TM[] = INCBIN_U8("graphics/items/icons/tm.4bpp.lz"); + +const u16 gItemIconPalette_FightingTMHM[] = INCBIN_U16("graphics/items/icon_palettes/fighting_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_DragonTMHM[] = INCBIN_U16("graphics/items/icon_palettes/dragon_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_WaterTMHM[] = INCBIN_U16("graphics/items/icon_palettes/water_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_PsychicTMHM[] = INCBIN_U16("graphics/items/icon_palettes/psychic_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_NormalTMHM[] = INCBIN_U16("graphics/items/icon_palettes/normal_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_PoisonTMHM[] = INCBIN_U16("graphics/items/icon_palettes/poison_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_IceTMHM[] = INCBIN_U16("graphics/items/icon_palettes/ice_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_GrassTMHM[] = INCBIN_U16("graphics/items/icon_palettes/grass_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_FireTMHM[] = INCBIN_U16("graphics/items/icon_palettes/fire_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_DarkTMHM[] = INCBIN_U16("graphics/items/icon_palettes/dark_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_SteelTMHM[] = INCBIN_U16("graphics/items/icon_palettes/steel_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_ElectricTMHM[] = INCBIN_U16("graphics/items/icon_palettes/electric_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_GroundTMHM[] = INCBIN_U16("graphics/items/icon_palettes/ground_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_GhostTMHM[] = INCBIN_U16("graphics/items/icon_palettes/ghost_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_RockTMHM[] = INCBIN_U16("graphics/items/icon_palettes/rock_tm_hm.gbapal.lz"); + +const u16 gItemIconPalette_FlyingTMHM[] = INCBIN_U16("graphics/items/icon_palettes/flying_tm_hm.gbapal.lz"); + +const u8 gItemIcon_HM[] = INCBIN_U8("graphics/items/icons/hm.4bpp.lz"); + +// FireRed/LeafGreen key items + +const u8 gItemIcon_OaksParcel[] = INCBIN_U8("graphics/items/icons/oaks_parcel.4bpp.lz"); +const u16 gItemIconPalette_OaksParcel[] = INCBIN_U16("graphics/items/icon_palettes/oaks_parcel.gbapal.lz"); + +const u8 gItemIcon_PokeFlute[] = INCBIN_U8("graphics/items/icons/poke_flute.4bpp.lz"); +const u16 gItemIconPalette_PokeFlute[] = INCBIN_U16("graphics/items/icon_palettes/poke_flute.gbapal.lz"); + +const u8 gItemIcon_SecretKey[] = INCBIN_U8("graphics/items/icons/secret_key.4bpp.lz"); +const u16 gItemIconPalette_SecretKey[] = INCBIN_U16("graphics/items/icon_palettes/secret_key.gbapal.lz"); + +const u8 gItemIcon_BikeVoucher[] = INCBIN_U8("graphics/items/icons/bike_voucher.4bpp.lz"); +const u16 gItemIconPalette_BikeVoucher[] = INCBIN_U16("graphics/items/icon_palettes/bike_voucher.gbapal.lz"); + +const u8 gItemIcon_GoldTeeth[] = INCBIN_U8("graphics/items/icons/gold_teeth.4bpp.lz"); +const u16 gItemIconPalette_GoldTeeth[] = INCBIN_U16("graphics/items/icon_palettes/gold_teeth.gbapal.lz"); + +const u8 gItemIcon_OldAmber[] = INCBIN_U8("graphics/items/icons/old_amber.4bpp.lz"); +const u16 gItemIconPalette_OldAmber[] = INCBIN_U16("graphics/items/icon_palettes/old_amber.gbapal.lz"); + +const u8 gItemIcon_CardKey[] = INCBIN_U8("graphics/items/icons/card_key.4bpp.lz"); +const u16 gItemIconPalette_CardKey[] = INCBIN_U16("graphics/items/icon_palettes/card_key.gbapal.lz"); + +const u8 gItemIcon_LiftKey[] = INCBIN_U8("graphics/items/icons/lift_key.4bpp.lz"); +const u16 gItemIconPalette_Key[] = INCBIN_U16("graphics/items/icon_palettes/key.gbapal.lz"); + +const u8 gItemIcon_HelixFossil[] = INCBIN_U8("graphics/items/icons/helix_fossil.4bpp.lz"); +const u16 gItemIconPalette_KantoFossil[] = INCBIN_U16("graphics/items/icon_palettes/kanto_fossil.gbapal.lz"); +const u8 gItemIcon_DomeFossil[] = INCBIN_U8("graphics/items/icons/dome_fossil.4bpp.lz"); + +const u8 gItemIcon_SilphScope[] = INCBIN_U8("graphics/items/icons/silph_scope.4bpp.lz"); +const u16 gItemIconPalette_SilphScope[] = INCBIN_U16("graphics/items/icon_palettes/silph_scope.gbapal.lz"); + +const u8 gItemIcon_Bicycle[] = INCBIN_U8("graphics/items/icons/bicycle.4bpp.lz"); +const u16 gItemIconPalette_Bicycle[] = INCBIN_U16("graphics/items/icon_palettes/bicycle.gbapal.lz"); + +const u8 gItemIcon_TownMap[] = INCBIN_U8("graphics/items/icons/town_map.4bpp.lz"); +const u16 gItemIconPalette_TownMap[] = INCBIN_U16("graphics/items/icon_palettes/town_map.gbapal.lz"); + +const u8 gItemIcon_VSSeeker[] = INCBIN_U8("graphics/items/icons/vs_seeker.4bpp.lz"); +const u16 gItemIconPalette_VSSeeker[] = INCBIN_U16("graphics/items/icon_palettes/vs_seeker.gbapal.lz"); + +const u8 gItemIcon_FameChecker[] = INCBIN_U8("graphics/items/icons/fame_checker.4bpp.lz"); +const u16 gItemIconPalette_FameChecker[] = INCBIN_U16("graphics/items/icon_palettes/fame_checker.gbapal.lz"); + +const u8 gItemIcon_TMCase[] = INCBIN_U8("graphics/items/icons/tm_case.4bpp.lz"); +const u16 gItemIconPalette_TMCase[] = INCBIN_U16("graphics/items/icon_palettes/tm_case.gbapal.lz"); + +const u8 gItemIcon_BerryPouch[] = INCBIN_U8("graphics/items/icons/berry_pouch.4bpp.lz"); +const u16 gItemIconPalette_BerryPouch[] = INCBIN_U16("graphics/items/icon_palettes/berry_pouch.gbapal.lz"); + +const u8 gItemIcon_TeachyTV[] = INCBIN_U8("graphics/items/icons/teachy_tv.4bpp.lz"); +const u16 gItemIconPalette_TeachyTV[] = INCBIN_U16("graphics/items/icon_palettes/teachy_tv.gbapal.lz"); + +const u8 gItemIcon_TriPass[] = INCBIN_U8("graphics/items/icons/tri_pass.4bpp.lz"); +const u16 gItemIconPalette_TriPass[] = INCBIN_U16("graphics/items/icon_palettes/tri_pass.gbapal.lz"); + +const u8 gItemIcon_RainbowPass[] = INCBIN_U8("graphics/items/icons/rainbow_pass.4bpp.lz"); +const u16 gItemIconPalette_RainbowPass[] = INCBIN_U16("graphics/items/icon_palettes/rainbow_pass.gbapal.lz"); + +const u8 gItemIcon_Tea[] = INCBIN_U8("graphics/items/icons/tea.4bpp.lz"); +const u16 gItemIconPalette_Tea[] = INCBIN_U16("graphics/items/icon_palettes/tea.gbapal.lz"); + +const u8 gItemIcon_MysticTicket[] = INCBIN_U8("graphics/items/icons/mystic_ticket.4bpp.lz"); +const u16 gItemIconPalette_MysticTicket[] = INCBIN_U16("graphics/items/icon_palettes/mystic_ticket.gbapal.lz"); + +const u8 gItemIcon_AuroraTicket[] = INCBIN_U8("graphics/items/icons/aurora_ticket.4bpp.lz"); +const u16 gItemIconPalette_AuroraTicket[] = INCBIN_U16("graphics/items/icon_palettes/aurora_ticket.gbapal.lz"); + +const u8 gItemIcon_PowderJar[] = INCBIN_U8("graphics/items/icons/powder_jar.4bpp.lz"); +const u16 gItemIconPalette_PowderJar[] = INCBIN_U16("graphics/items/icon_palettes/powder_jar.gbapal.lz"); + +const u16 gItemIconPalette_Ruby[] = INCBIN_U16("graphics/items/icon_palettes/ruby.gbapal.lz"); +const u8 gItemIcon_Gem[] = INCBIN_U8("graphics/items/icons/gem.4bpp.lz"); +const u16 gItemIconPalette_Sapphire[] = INCBIN_U16("graphics/items/icon_palettes/sapphire.gbapal.lz"); + +// Emerald-only key items + +const u8 gItemIcon_MagmaEmblem[] = INCBIN_U8("graphics/items/icons/magma_emblem.4bpp.lz"); +const u16 gItemIconPalette_MagmaEmblem[] = INCBIN_U16("graphics/items/icon_palettes/magma_emblem.gbapal.lz"); + +const u8 gItemIcon_OldSeaMap[] = INCBIN_U8("graphics/items/icons/old_sea_map.4bpp.lz"); +const u16 gItemIconPalette_OldSeaMap[] = INCBIN_U16("graphics/items/icon_palettes/old_sea_map.gbapal.lz"); -- cgit v1.2.3 From aab1238ec05935c642430541255ab965d715c350 Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Sun, 6 May 2018 09:12:23 +0100 Subject: Revert "Convert item_graphics.inc to C" This reverts commit 546217d28124daa204f804469e7d4bc18a048398. --- src/item_graphics.c | 740 ---------------------------------------------------- 1 file changed, 740 deletions(-) delete mode 100644 src/item_graphics.c (limited to 'src') diff --git a/src/item_graphics.c b/src/item_graphics.c deleted file mode 100644 index 3b2b8cff2..000000000 --- a/src/item_graphics.c +++ /dev/null @@ -1,740 +0,0 @@ -#include "global.h" - -const u8 gItemIcon_QuestionMark[] = INCBIN_U8("graphics/items/icons/question_mark.4bpp.lz"); -const u16 gItemIconPalette_QuestionMark[] = INCBIN_U16("graphics/items/icon_palettes/question_mark.gbapal.lz"); - -const u8 gItemIcon_ReturnToFieldArrow[] = INCBIN_U8("graphics/items/icons/return_to_field_arrow.4bpp.lz"); -const u16 gItemIconPalette_ReturnToFieldArrow[] = INCBIN_U16("graphics/items/icon_palettes/return_to_field_arrow.gbapal.lz"); - -// Pokeballs - -const u8 gItemIcon_MasterBall[] = INCBIN_U8("graphics/items/icons/master_ball.4bpp.lz"); -const u16 gItemIconPalette_MasterBall[] = INCBIN_U16("graphics/items/icon_palettes/master_ball.gbapal.lz"); - -const u8 gItemIcon_UltraBall[] = INCBIN_U8("graphics/items/icons/ultra_ball.4bpp.lz"); -const u16 gItemIconPalette_UltraBall[] = INCBIN_U16("graphics/items/icon_palettes/ultra_ball.gbapal.lz"); - -const u8 gItemIcon_GreatBall[] = INCBIN_U8("graphics/items/icons/great_ball.4bpp.lz"); -const u16 gItemIconPalette_GreatBall[] = INCBIN_U16("graphics/items/icon_palettes/great_ball.gbapal.lz"); - -const u8 gItemIcon_PokeBall[] = INCBIN_U8("graphics/items/icons/poke_ball.4bpp.lz"); -const u16 gItemIconPalette_PokeBall[] = INCBIN_U16("graphics/items/icon_palettes/poke_ball.gbapal.lz"); - -const u8 gItemIcon_SafariBall[] = INCBIN_U8("graphics/items/icons/safari_ball.4bpp.lz"); -const u16 gItemIconPalette_SafariBall[] = INCBIN_U16("graphics/items/icon_palettes/safari_ball.gbapal.lz"); - -const u8 gItemIcon_NetBall[] = INCBIN_U8("graphics/items/icons/net_ball.4bpp.lz"); -const u16 gItemIconPalette_NetBall[] = INCBIN_U16("graphics/items/icon_palettes/net_ball.gbapal.lz"); - -const u8 gItemIcon_DiveBall[] = INCBIN_U8("graphics/items/icons/dive_ball.4bpp.lz"); -const u16 gItemIconPalette_DiveBall[] = INCBIN_U16("graphics/items/icon_palettes/dive_ball.gbapal.lz"); - -const u8 gItemIcon_NestBall[] = INCBIN_U8("graphics/items/icons/nest_ball.4bpp.lz"); -const u16 gItemIconPalette_NestBall[] = INCBIN_U16("graphics/items/icon_palettes/nest_ball.gbapal.lz"); - -const u8 gItemIcon_RepeatBall[] = INCBIN_U8("graphics/items/icons/repeat_ball.4bpp.lz"); -const u16 gItemIconPalette_RepeatBall[] = INCBIN_U16("graphics/items/icon_palettes/repeat_ball.gbapal.lz"); - -const u8 gItemIcon_TimerBall[] = INCBIN_U8("graphics/items/icons/timer_ball.4bpp.lz"); - -const u8 gItemIcon_LuxuryBall[] = INCBIN_U8("graphics/items/icons/luxury_ball.4bpp.lz"); -const u16 gItemIconPalette_LuxuryBall[] = INCBIN_U16("graphics/items/icon_palettes/luxury_ball.gbapal.lz"); - -const u8 gItemIcon_PremierBall[] = INCBIN_U8("graphics/items/icons/premier_ball.4bpp.lz"); - -// Medicine - -const u8 gItemIcon_Potion[] = INCBIN_U8("graphics/items/icons/potion.4bpp.lz"); -const u16 gItemIconPalette_Potion[] = INCBIN_U16("graphics/items/icon_palettes/potion.gbapal.lz"); - -const u8 gItemIcon_Antidote[] = INCBIN_U8("graphics/items/icons/antidote.4bpp.lz"); -const u16 gItemIconPalette_Antidote[] = INCBIN_U16("graphics/items/icon_palettes/antidote.gbapal.lz"); - -const u16 gItemIconPalette_BurnHeal[] = INCBIN_U16("graphics/items/icon_palettes/burn_heal.gbapal.lz"); -const u16 gItemIconPalette_IceHeal[] = INCBIN_U16("graphics/items/icon_palettes/ice_heal.gbapal.lz"); -const u8 gItemIcon_StatusHeal[] = INCBIN_U8("graphics/items/icons/status_heal.4bpp.lz"); -const u16 gItemIconPalette_Awakening[] = INCBIN_U16("graphics/items/icon_palettes/awakening.gbapal.lz"); -const u16 gItemIconPalette_ParalyzeHeal[] = INCBIN_U16("graphics/items/icon_palettes/paralyze_heal.gbapal.lz"); - -const u8 gItemIcon_LargePotion[] = INCBIN_U8("graphics/items/icons/large_potion.4bpp.lz"); -const u16 gItemIconPalette_FullRestore[] = INCBIN_U16("graphics/items/icon_palettes/full_restore.gbapal.lz"); -const u16 gItemIconPalette_MaxPotion[] = INCBIN_U16("graphics/items/icon_palettes/max_potion.gbapal.lz"); - -const u16 gItemIconPalette_HyperPotion[] = INCBIN_U16("graphics/items/icon_palettes/hyper_potion.gbapal.lz"); - -const u16 gItemIconPalette_SuperPotion[] = INCBIN_U16("graphics/items/icon_palettes/super_potion.gbapal.lz"); - -const u8 gItemIcon_FullHeal[] = INCBIN_U8("graphics/items/icons/full_heal.4bpp.lz"); -const u16 gItemIconPalette_FullHeal[] = INCBIN_U16("graphics/items/icon_palettes/full_heal.gbapal.lz"); - -const u8 gItemIcon_Revive[] = INCBIN_U8("graphics/items/icons/revive.4bpp.lz"); - -const u8 gItemIcon_MaxRevive[] = INCBIN_U8("graphics/items/icons/max_revive.4bpp.lz"); - -const u16 gItemIconPalette_Revive[] = INCBIN_U16("graphics/items/icon_palettes/revive.gbapal.lz"); - -const u8 gItemIcon_FreshWater[] = INCBIN_U8("graphics/items/icons/fresh_water.4bpp.lz"); -const u16 gItemIconPalette_FreshWater[] = INCBIN_U16("graphics/items/icon_palettes/fresh_water.gbapal.lz"); - -const u8 gItemIcon_SodaPop[] = INCBIN_U8("graphics/items/icons/soda_pop.4bpp.lz"); -const u16 gItemIconPalette_SodaPop[] = INCBIN_U16("graphics/items/icon_palettes/soda_pop.gbapal.lz"); - -const u8 gItemIcon_Lemonade[] = INCBIN_U8("graphics/items/icons/lemonade.4bpp.lz"); -const u16 gItemIconPalette_Lemonade[] = INCBIN_U16("graphics/items/icon_palettes/lemonade.gbapal.lz"); - -const u8 gItemIcon_MoomooMilk[] = INCBIN_U8("graphics/items/icons/moomoo_milk.4bpp.lz"); -const u16 gItemIconPalette_MoomooMilk[] = INCBIN_U16("graphics/items/icon_palettes/moomoo_milk.gbapal.lz"); - -const u8 gItemIcon_Powder[] = INCBIN_U8("graphics/items/icons/powder.4bpp.lz"); -const u16 gItemIconPalette_EnergyPowder[] = INCBIN_U16("graphics/items/icon_palettes/energy_powder.gbapal.lz"); - -const u8 gItemIcon_EnergyRoot[] = INCBIN_U8("graphics/items/icons/energy_root.4bpp.lz"); -const u16 gItemIconPalette_EnergyRoot[] = INCBIN_U16("graphics/items/icon_palettes/energy_root.gbapal.lz"); - -const u16 gItemIconPalette_HealPowder[] = INCBIN_U16("graphics/items/icon_palettes/heal_powder.gbapal.lz"); - -const u8 gItemIcon_RevivalHerb[] = INCBIN_U8("graphics/items/icons/revival_herb.4bpp.lz"); -const u16 gItemIconPalette_RevivalHerb[] = INCBIN_U16("graphics/items/icon_palettes/revival_herb.gbapal.lz"); - -const u8 gItemIcon_Ether[] = INCBIN_U8("graphics/items/icons/ether.4bpp.lz"); -const u16 gItemIconPalette_Ether[] = INCBIN_U16("graphics/items/icon_palettes/ether.gbapal.lz"); -const u16 gItemIconPalette_MaxEther[] = INCBIN_U16("graphics/items/icon_palettes/max_ether.gbapal.lz"); -const u16 gItemIconPalette_Elixir[] = INCBIN_U16("graphics/items/icon_palettes/elixir.gbapal.lz"); -const u16 gItemIconPalette_MaxElixir[] = INCBIN_U16("graphics/items/icon_palettes/max_elixir.gbapal.lz"); - -const u8 gItemIcon_LavaCookie[] = INCBIN_U8("graphics/items/icons/lava_cookie.4bpp.lz"); -const u16 gItemIconPalette_LavaCookieAndLetter[] = INCBIN_U16("graphics/items/icon_palettes/lava_cookie_and_letter.gbapal.lz"); - -const u8 gItemIcon_Flute[] = INCBIN_U8("graphics/items/icons/flute.4bpp.lz"); -const u16 gItemIconPalette_BlueFlute[] = INCBIN_U16("graphics/items/icon_palettes/blue_flute.gbapal.lz"); -const u16 gItemIconPalette_YellowFlute[] = INCBIN_U16("graphics/items/icon_palettes/yellow_flute.gbapal.lz"); -const u16 gItemIconPalette_RedFlute[] = INCBIN_U16("graphics/items/icon_palettes/red_flute.gbapal.lz"); -const u16 gItemIconPalette_BlackFlute[] = INCBIN_U16("graphics/items/icon_palettes/black_flute.gbapal.lz"); -const u16 gItemIconPalette_WhiteFlute[] = INCBIN_U16("graphics/items/icon_palettes/white_flute.gbapal.lz"); - -const u8 gItemIcon_BerryJuice[] = INCBIN_U8("graphics/items/icons/berry_juice.4bpp.lz"); -const u16 gItemIconPalette_BerryJuice[] = INCBIN_U16("graphics/items/icon_palettes/berry_juice.gbapal.lz"); - -const u8 gItemIcon_SacredAsh[] = INCBIN_U8("graphics/items/icons/sacred_ash.4bpp.lz"); -const u16 gItemIconPalette_SacredAsh[] = INCBIN_U16("graphics/items/icon_palettes/sacred_ash.gbapal.lz"); - -// Collectibles - -const u16 gItemIconPalette_ShoalSalt[] = INCBIN_U16("graphics/items/icon_palettes/shoal_salt.gbapal.lz"); - -const u8 gItemIcon_ShoalShell[] = INCBIN_U8("graphics/items/icons/shoal_shell.4bpp.lz"); -const u16 gItemIconPalette_Shell[] = INCBIN_U16("graphics/items/icon_palettes/shell.gbapal.lz"); - -const u8 gItemIcon_Shard[] = INCBIN_U8("graphics/items/icons/shard.4bpp.lz"); -const u16 gItemIconPalette_RedShard[] = INCBIN_U16("graphics/items/icon_palettes/red_shard.gbapal.lz"); -const u16 gItemIconPalette_BlueShard[] = INCBIN_U16("graphics/items/icon_palettes/blue_shard.gbapal.lz"); -const u16 gItemIconPalette_YellowShard[] = INCBIN_U16("graphics/items/icon_palettes/yellow_shard.gbapal.lz"); -const u16 gItemIconPalette_GreenShard[] = INCBIN_U16("graphics/items/icon_palettes/green_shard.gbapal.lz"); - -// Vitamins - -const u8 gItemIcon_HPUp[] = INCBIN_U8("graphics/items/icons/hp_up.4bpp.lz"); -const u16 gItemIconPalette_HPUp[] = INCBIN_U16("graphics/items/icon_palettes/hp_up.gbapal.lz"); - -const u8 gItemIcon_Vitamin[] = INCBIN_U8("graphics/items/icons/vitamin.4bpp.lz"); -const u16 gItemIconPalette_Protein[] = INCBIN_U16("graphics/items/icon_palettes/protein.gbapal.lz"); -const u16 gItemIconPalette_Iron[] = INCBIN_U16("graphics/items/icon_palettes/iron.gbapal.lz"); -const u16 gItemIconPalette_Carbos[] = INCBIN_U16("graphics/items/icon_palettes/carbos.gbapal.lz"); -const u16 gItemIconPalette_Calcium[] = INCBIN_U16("graphics/items/icon_palettes/calcium.gbapal.lz"); - -const u8 gItemIcon_RareCandy[] = INCBIN_U8("graphics/items/icons/rare_candy.4bpp.lz"); -const u16 gItemIconPalette_RareCandy[] = INCBIN_U16("graphics/items/icon_palettes/rare_candy.gbapal.lz"); - -const u8 gItemIcon_PPUp[] = INCBIN_U8("graphics/items/icons/pp_up.4bpp.lz"); -const u16 gItemIconPalette_PPUp[] = INCBIN_U16("graphics/items/icon_palettes/pp_up.gbapal.lz"); - -const u16 gItemIconPalette_Zinc[] = INCBIN_U16("graphics/items/icon_palettes/zinc.gbapal.lz"); - -const u8 gItemIcon_PPMax[] = INCBIN_U8("graphics/items/icons/pp_max.4bpp.lz"); -const u16 gItemIconPalette_PPMax[] = INCBIN_U16("graphics/items/icon_palettes/pp_max.gbapal.lz"); - -// Battle items - -const u16 gItemIconPalette_GuardSpec[] = INCBIN_U16("graphics/items/icon_palettes/guard_spec.gbapal.lz"); -const u16 gItemIconPalette_DireHit[] = INCBIN_U16("graphics/items/icon_palettes/dire_hit.gbapal.lz"); -const u16 gItemIconPalette_XAttack[] = INCBIN_U16("graphics/items/icon_palettes/x_attack.gbapal.lz"); -const u8 gItemIcon_BattleStatItem[] = INCBIN_U8("graphics/items/icons/battle_stat_item.4bpp.lz"); -const u16 gItemIconPalette_XDefend[] = INCBIN_U16("graphics/items/icon_palettes/x_defend.gbapal.lz"); -const u16 gItemIconPalette_XSpeed[] = INCBIN_U16("graphics/items/icon_palettes/x_speed.gbapal.lz"); -const u16 gItemIconPalette_XAccuracy[] = INCBIN_U16("graphics/items/icon_palettes/x_accuracy.gbapal.lz"); -const u16 gItemIconPalette_XSpecial[] = INCBIN_U16("graphics/items/icon_palettes/x_special.gbapal.lz"); - -const u8 gItemIcon_PokeDoll[] = INCBIN_U8("graphics/items/icons/poke_doll.4bpp.lz"); -const u16 gItemIconPalette_PokeDoll[] = INCBIN_U16("graphics/items/icon_palettes/poke_doll.gbapal.lz"); - -const u8 gItemIcon_FluffyTail[] = INCBIN_U8("graphics/items/icons/fluffy_tail.4bpp.lz"); -const u16 gItemIconPalette_FluffyTail[] = INCBIN_U16("graphics/items/icon_palettes/fluffy_tail.gbapal.lz"); - -// Field items - -const u8 gItemIcon_Repel[] = INCBIN_U8("graphics/items/icons/repel.4bpp.lz"); -const u16 gItemIconPalette_SuperRepel[] = INCBIN_U16("graphics/items/icon_palettes/super_repel.gbapal.lz"); -const u16 gItemIconPalette_MaxRepel[] = INCBIN_U16("graphics/items/icon_palettes/max_repel.gbapal.lz"); - -const u8 gItemIcon_EscapeRope[] = INCBIN_U8("graphics/items/icons/escape_rope.4bpp.lz"); - -const u16 gItemIconPalette_EscapeRope[] = INCBIN_U16("graphics/items/icon_palettes/escape_rope.gbapal.lz"); - -const u16 gItemIconPalette_Repel[] = INCBIN_U16("graphics/items/icon_palettes/repel.gbapal.lz"); - -// Evolution stones - -const u8 gItemIcon_SunStone[] = INCBIN_U8("graphics/items/icons/sun_stone.4bpp.lz"); -const u16 gItemIconPalette_SunStone[] = INCBIN_U16("graphics/items/icon_palettes/sun_stone.gbapal.lz"); - -const u8 gItemIcon_MoonStone[] = INCBIN_U8("graphics/items/icons/moon_stone.4bpp.lz"); -const u16 gItemIconPalette_MoonStone[] = INCBIN_U16("graphics/items/icon_palettes/moon_stone.gbapal.lz"); - -const u8 gItemIcon_FireStone[] = INCBIN_U8("graphics/items/icons/fire_stone.4bpp.lz"); -const u16 gItemIconPalette_FireStone[] = INCBIN_U16("graphics/items/icon_palettes/fire_stone.gbapal.lz"); - -const u8 gItemIcon_ThunderStone[] = INCBIN_U8("graphics/items/icons/thunder_stone.4bpp.lz"); -const u16 gItemIconPalette_ThunderStone[] = INCBIN_U16("graphics/items/icon_palettes/thunder_stone.gbapal.lz"); - -const u8 gItemIcon_WaterStone[] = INCBIN_U8("graphics/items/icons/water_stone.4bpp.lz"); -const u16 gItemIconPalette_WaterStone[] = INCBIN_U16("graphics/items/icon_palettes/water_stone.gbapal.lz"); - -const u8 gItemIcon_LeafStone[] = INCBIN_U8("graphics/items/icons/leaf_stone.4bpp.lz"); -const u16 gItemIconPalette_LeafStone[] = INCBIN_U16("graphics/items/icon_palettes/leaf_stone.gbapal.lz"); - -// Valuables - -const u8 gItemIcon_TinyMushroom[] = INCBIN_U8("graphics/items/icons/tiny_mushroom.4bpp.lz"); -const u8 gItemIcon_BigMushroom[] = INCBIN_U8("graphics/items/icons/big_mushroom.4bpp.lz"); -const u16 gItemIconPalette_Mushroom[] = INCBIN_U16("graphics/items/icon_palettes/mushroom.gbapal.lz"); - -const u8 gItemIcon_Pearl[] = INCBIN_U8("graphics/items/icons/pearl.4bpp.lz"); -const u16 gItemIconPalette_Pearl[] = INCBIN_U16("graphics/items/icon_palettes/pearl.gbapal.lz"); -const u8 gItemIcon_BigPearl[] = INCBIN_U8("graphics/items/icons/big_pearl.4bpp.lz"); - -const u8 gItemIcon_Stardust[] = INCBIN_U8("graphics/items/icons/stardust.4bpp.lz"); -const u16 gItemIconPalette_Star[] = INCBIN_U16("graphics/items/icon_palettes/star.gbapal.lz"); -const u8 gItemIcon_StarPiece[] = INCBIN_U8("graphics/items/icons/star_piece.4bpp.lz"); - -const u8 gItemIcon_Nugget[] = INCBIN_U8("graphics/items/icons/nugget.4bpp.lz"); -const u16 gItemIconPalette_Nugget[] = INCBIN_U16("graphics/items/icon_palettes/nugget.gbapal.lz"); - -const u8 gItemIcon_HeartScale[] = INCBIN_U8("graphics/items/icons/heart_scale.4bpp.lz"); -const u16 gItemIconPalette_HeartScale[] = INCBIN_U16("graphics/items/icon_palettes/heart_scale.gbapal.lz"); - -// Mail - -const u8 gItemIcon_OrangeMail[] = INCBIN_U8("graphics/items/icons/orange_mail.4bpp.lz"); -const u16 gItemIconPalette_OrangeMail[] = INCBIN_U16("graphics/items/icon_palettes/orange_mail.gbapal.lz"); - -const u8 gItemIcon_HarborMail[] = INCBIN_U8("graphics/items/icons/harbor_mail.4bpp.lz"); -const u16 gItemIconPalette_HarborMail[] = INCBIN_U16("graphics/items/icon_palettes/harbor_mail.gbapal.lz"); - -const u8 gItemIcon_GlitterMail[] = INCBIN_U8("graphics/items/icons/glitter_mail.4bpp.lz"); -const u16 gItemIconPalette_GlitterMail[] = INCBIN_U16("graphics/items/icon_palettes/glitter_mail.gbapal.lz"); - -const u8 gItemIcon_MechMail[] = INCBIN_U8("graphics/items/icons/mech_mail.4bpp.lz"); -const u16 gItemIconPalette_MechMail[] = INCBIN_U16("graphics/items/icon_palettes/mech_mail.gbapal.lz"); - -const u8 gItemIcon_WoodMail[] = INCBIN_U8("graphics/items/icons/wood_mail.4bpp.lz"); -const u16 gItemIconPalette_WoodMail[] = INCBIN_U16("graphics/items/icon_palettes/wood_mail.gbapal.lz"); - -const u8 gItemIcon_WaveMail[] = INCBIN_U8("graphics/items/icons/wave_mail.4bpp.lz"); -const u16 gItemIconPalette_WaveMail[] = INCBIN_U16("graphics/items/icon_palettes/wave_mail.gbapal.lz"); - -const u8 gItemIcon_BeadMail[] = INCBIN_U8("graphics/items/icons/bead_mail.4bpp.lz"); -const u16 gItemIconPalette_BeadMail[] = INCBIN_U16("graphics/items/icon_palettes/bead_mail.gbapal.lz"); - -const u8 gItemIcon_ShadowMail[] = INCBIN_U8("graphics/items/icons/shadow_mail.4bpp.lz"); -const u16 gItemIconPalette_ShadowMail[] = INCBIN_U16("graphics/items/icon_palettes/shadow_mail.gbapal.lz"); - -const u8 gItemIcon_TropicMail[] = INCBIN_U8("graphics/items/icons/tropic_mail.4bpp.lz"); -const u16 gItemIconPalette_TropicMail[] = INCBIN_U16("graphics/items/icon_palettes/tropic_mail.gbapal.lz"); - -const u8 gItemIcon_DreamMail[] = INCBIN_U8("graphics/items/icons/dream_mail.4bpp.lz"); -const u16 gItemIconPalette_DreamMail[] = INCBIN_U16("graphics/items/icon_palettes/dream_mail.gbapal.lz"); - -const u8 gItemIcon_FabMail[] = INCBIN_U8("graphics/items/icons/fab_mail.4bpp.lz"); -const u16 gItemIconPalette_FabMail[] = INCBIN_U16("graphics/items/icon_palettes/fab_mail.gbapal.lz"); - -const u8 gItemIcon_RetroMail[] = INCBIN_U8("graphics/items/icons/retro_mail.4bpp.lz"); -const u16 gItemIconPalette_RetroMail[] = INCBIN_U16("graphics/items/icon_palettes/retro_mail.gbapal.lz"); - -// Berries - -const u8 gItemIcon_CheriBerry[] = INCBIN_U8("graphics/items/icons/cheri_berry.4bpp.lz"); -const u16 gItemIconPalette_CheriBerry[] = INCBIN_U16("graphics/items/icon_palettes/cheri_berry.gbapal.lz"); - -const u8 gItemIcon_ChestoBerry[] = INCBIN_U8("graphics/items/icons/chesto_berry.4bpp.lz"); -const u16 gItemIconPalette_ChestoBerry[] = INCBIN_U16("graphics/items/icon_palettes/chesto_berry.gbapal.lz"); - -const u8 gItemIcon_PechaBerry[] = INCBIN_U8("graphics/items/icons/pecha_berry.4bpp.lz"); -const u16 gItemIconPalette_PechaBerry[] = INCBIN_U16("graphics/items/icon_palettes/pecha_berry.gbapal.lz"); - -const u8 gItemIcon_RawstBerry[] = INCBIN_U8("graphics/items/icons/rawst_berry.4bpp.lz"); -const u16 gItemIconPalette_RawstBerry[] = INCBIN_U16("graphics/items/icon_palettes/rawst_berry.gbapal.lz"); - -const u8 gItemIcon_AspearBerry[] = INCBIN_U8("graphics/items/icons/aspear_berry.4bpp.lz"); -const u16 gItemIconPalette_AspearBerry[] = INCBIN_U16("graphics/items/icon_palettes/aspear_berry.gbapal.lz"); - -const u8 gItemIcon_LeppaBerry[] = INCBIN_U8("graphics/items/icons/leppa_berry.4bpp.lz"); -const u16 gItemIconPalette_LeppaBerry[] = INCBIN_U16("graphics/items/icon_palettes/leppa_berry.gbapal.lz"); - -const u8 gItemIcon_OranBerry[] = INCBIN_U8("graphics/items/icons/oran_berry.4bpp.lz"); -const u16 gItemIconPalette_OranBerry[] = INCBIN_U16("graphics/items/icon_palettes/oran_berry.gbapal.lz"); - -const u8 gItemIcon_PersimBerry[] = INCBIN_U8("graphics/items/icons/persim_berry.4bpp.lz"); -const u16 gItemIconPalette_PersimBerry[] = INCBIN_U16("graphics/items/icon_palettes/persim_berry.gbapal.lz"); - -const u8 gItemIcon_LumBerry[] = INCBIN_U8("graphics/items/icons/lum_berry.4bpp.lz"); -const u16 gItemIconPalette_LumBerry[] = INCBIN_U16("graphics/items/icon_palettes/lum_berry.gbapal.lz"); - -const u8 gItemIcon_SitrusBerry[] = INCBIN_U8("graphics/items/icons/sitrus_berry.4bpp.lz"); -const u16 gItemIconPalette_SitrusBerry[] = INCBIN_U16("graphics/items/icon_palettes/sitrus_berry.gbapal.lz"); - -const u8 gItemIcon_FigyBerry[] = INCBIN_U8("graphics/items/icons/figy_berry.4bpp.lz"); -const u16 gItemIconPalette_FigyBerry[] = INCBIN_U16("graphics/items/icon_palettes/figy_berry.gbapal.lz"); - -const u8 gItemIcon_WikiBerry[] = INCBIN_U8("graphics/items/icons/wiki_berry.4bpp.lz"); -const u16 gItemIconPalette_WikiBerry[] = INCBIN_U16("graphics/items/icon_palettes/wiki_berry.gbapal.lz"); - -const u8 gItemIcon_MagoBerry[] = INCBIN_U8("graphics/items/icons/mago_berry.4bpp.lz"); -const u16 gItemIconPalette_MagoBerry[] = INCBIN_U16("graphics/items/icon_palettes/mago_berry.gbapal.lz"); - -const u8 gItemIcon_AguavBerry[] = INCBIN_U8("graphics/items/icons/aguav_berry.4bpp.lz"); -const u16 gItemIconPalette_AguavBerry[] = INCBIN_U16("graphics/items/icon_palettes/aguav_berry.gbapal.lz"); - -const u8 gItemIcon_IapapaBerry[] = INCBIN_U8("graphics/items/icons/iapapa_berry.4bpp.lz"); -const u16 gItemIconPalette_IapapaBerry[] = INCBIN_U16("graphics/items/icon_palettes/iapapa_berry.gbapal.lz"); - -const u8 gItemIcon_RazzBerry[] = INCBIN_U8("graphics/items/icons/razz_berry.4bpp.lz"); -const u16 gItemIconPalette_RazzBerry[] = INCBIN_U16("graphics/items/icon_palettes/razz_berry.gbapal.lz"); - -const u8 gItemIcon_BlukBerry[] = INCBIN_U8("graphics/items/icons/bluk_berry.4bpp.lz"); -const u16 gItemIconPalette_BlukBerry[] = INCBIN_U16("graphics/items/icon_palettes/bluk_berry.gbapal.lz"); - -const u8 gItemIcon_NanabBerry[] = INCBIN_U8("graphics/items/icons/nanab_berry.4bpp.lz"); -const u16 gItemIconPalette_NanabBerry[] = INCBIN_U16("graphics/items/icon_palettes/nanab_berry.gbapal.lz"); - -const u8 gItemIcon_WepearBerry[] = INCBIN_U8("graphics/items/icons/wepear_berry.4bpp.lz"); -const u16 gItemIconPalette_WepearBerry[] = INCBIN_U16("graphics/items/icon_palettes/wepear_berry.gbapal.lz"); - -const u8 gItemIcon_PinapBerry[] = INCBIN_U8("graphics/items/icons/pinap_berry.4bpp.lz"); -const u16 gItemIconPalette_PinapBerry[] = INCBIN_U16("graphics/items/icon_palettes/pinap_berry.gbapal.lz"); - -const u8 gItemIcon_PomegBerry[] = INCBIN_U8("graphics/items/icons/pomeg_berry.4bpp.lz"); -const u16 gItemIconPalette_PomegBerry[] = INCBIN_U16("graphics/items/icon_palettes/pomeg_berry.gbapal.lz"); - -const u8 gItemIcon_KelpsyBerry[] = INCBIN_U8("graphics/items/icons/kelpsy_berry.4bpp.lz"); -const u16 gItemIconPalette_KelpsyBerry[] = INCBIN_U16("graphics/items/icon_palettes/kelpsy_berry.gbapal.lz"); - -const u8 gItemIcon_QualotBerry[] = INCBIN_U8("graphics/items/icons/qualot_berry.4bpp.lz"); -const u16 gItemIconPalette_QualotBerry[] = INCBIN_U16("graphics/items/icon_palettes/qualot_berry.gbapal.lz"); - -const u8 gItemIcon_HondewBerry[] = INCBIN_U8("graphics/items/icons/hondew_berry.4bpp.lz"); -const u16 gItemIconPalette_HondewBerry[] = INCBIN_U16("graphics/items/icon_palettes/hondew_berry.gbapal.lz"); - -const u8 gItemIcon_GrepaBerry[] = INCBIN_U8("graphics/items/icons/grepa_berry.4bpp.lz"); -const u16 gItemIconPalette_GrepaBerry[] = INCBIN_U16("graphics/items/icon_palettes/grepa_berry.gbapal.lz"); - -const u8 gItemIcon_TamatoBerry[] = INCBIN_U8("graphics/items/icons/tamato_berry.4bpp.lz"); -const u16 gItemIconPalette_TamatoBerry[] = INCBIN_U16("graphics/items/icon_palettes/tamato_berry.gbapal.lz"); - -const u8 gItemIcon_CornnBerry[] = INCBIN_U8("graphics/items/icons/cornn_berry.4bpp.lz"); -const u16 gItemIconPalette_CornnBerry[] = INCBIN_U16("graphics/items/icon_palettes/cornn_berry.gbapal.lz"); - -const u8 gItemIcon_MagostBerry[] = INCBIN_U8("graphics/items/icons/magost_berry.4bpp.lz"); -const u16 gItemIconPalette_MagostBerry[] = INCBIN_U16("graphics/items/icon_palettes/magost_berry.gbapal.lz"); - -const u8 gItemIcon_RabutaBerry[] = INCBIN_U8("graphics/items/icons/rabuta_berry.4bpp.lz"); -const u16 gItemIconPalette_RabutaBerry[] = INCBIN_U16("graphics/items/icon_palettes/rabuta_berry.gbapal.lz"); - -const u8 gItemIcon_NomelBerry[] = INCBIN_U8("graphics/items/icons/nomel_berry.4bpp.lz"); -const u16 gItemIconPalette_NomelBerry[] = INCBIN_U16("graphics/items/icon_palettes/nomel_berry.gbapal.lz"); - -const u8 gItemIcon_SpelonBerry[] = INCBIN_U8("graphics/items/icons/spelon_berry.4bpp.lz"); -const u16 gItemIconPalette_SpelonBerry[] = INCBIN_U16("graphics/items/icon_palettes/spelon_berry.gbapal.lz"); - -const u8 gItemIcon_PamtreBerry[] = INCBIN_U8("graphics/items/icons/pamtre_berry.4bpp.lz"); -const u16 gItemIconPalette_PamtreBerry[] = INCBIN_U16("graphics/items/icon_palettes/pamtre_berry.gbapal.lz"); - -const u8 gItemIcon_WatmelBerry[] = INCBIN_U8("graphics/items/icons/watmel_berry.4bpp.lz"); -const u16 gItemIconPalette_WatmelBerry[] = INCBIN_U16("graphics/items/icon_palettes/watmel_berry.gbapal.lz"); - -const u8 gItemIcon_DurinBerry[] = INCBIN_U8("graphics/items/icons/durin_berry.4bpp.lz"); -const u16 gItemIconPalette_DurinBerry[] = INCBIN_U16("graphics/items/icon_palettes/durin_berry.gbapal.lz"); - -const u8 gItemIcon_BelueBerry[] = INCBIN_U8("graphics/items/icons/belue_berry.4bpp.lz"); -const u16 gItemIconPalette_BelueBerry[] = INCBIN_U16("graphics/items/icon_palettes/belue_berry.gbapal.lz"); - -const u8 gItemIcon_LiechiBerry[] = INCBIN_U8("graphics/items/icons/liechi_berry.4bpp.lz"); -const u16 gItemIconPalette_LiechiBerry[] = INCBIN_U16("graphics/items/icon_palettes/liechi_berry.gbapal.lz"); - -const u8 gItemIcon_GanlonBerry[] = INCBIN_U8("graphics/items/icons/ganlon_berry.4bpp.lz"); -const u16 gItemIconPalette_GanlonBerry[] = INCBIN_U16("graphics/items/icon_palettes/ganlon_berry.gbapal.lz"); - -const u8 gItemIcon_SalacBerry[] = INCBIN_U8("graphics/items/icons/salac_berry.4bpp.lz"); -const u16 gItemIconPalette_SalacBerry[] = INCBIN_U16("graphics/items/icon_palettes/salac_berry.gbapal.lz"); - -const u8 gItemIcon_PetayaBerry[] = INCBIN_U8("graphics/items/icons/petaya_berry.4bpp.lz"); -const u16 gItemIconPalette_PetayaBerry[] = INCBIN_U16("graphics/items/icon_palettes/petaya_berry.gbapal.lz"); - -const u8 gItemIcon_ApicotBerry[] = INCBIN_U8("graphics/items/icons/apicot_berry.4bpp.lz"); -const u16 gItemIconPalette_ApicotBerry[] = INCBIN_U16("graphics/items/icon_palettes/apicot_berry.gbapal.lz"); - -const u8 gItemIcon_LansatBerry[] = INCBIN_U8("graphics/items/icons/lansat_berry.4bpp.lz"); -const u16 gItemIconPalette_LansatBerry[] = INCBIN_U16("graphics/items/icon_palettes/lansat_berry.gbapal.lz"); - -const u8 gItemIcon_StarfBerry[] = INCBIN_U8("graphics/items/icons/starf_berry.4bpp.lz"); -const u16 gItemIconPalette_StarfBerry[] = INCBIN_U16("graphics/items/icon_palettes/starf_berry.gbapal.lz"); - -const u8 gItemIcon_EnigmaBerry[] = INCBIN_U8("graphics/items/icons/enigma_berry.4bpp.lz"); -const u16 gItemIconPalette_EnigmaBerry[] = INCBIN_U16("graphics/items/icon_palettes/enigma_berry.gbapal.lz"); - -// Hold items - -const u8 gItemIcon_BrightPowder[] = INCBIN_U8("graphics/items/icons/bright_powder.4bpp.lz"); -const u16 gItemIconPalette_BrightPowder[] = INCBIN_U16("graphics/items/icon_palettes/bright_powder.gbapal.lz"); - -const u8 gItemIcon_InBattleHerb[] = INCBIN_U8("graphics/items/icons/in_battle_herb.4bpp.lz"); -const u16 gItemIconPalette_WhiteHerb[] = INCBIN_U16("graphics/items/icon_palettes/white_herb.gbapal.lz"); - -const u8 gItemIcon_MachoBrace[] = INCBIN_U8("graphics/items/icons/macho_brace.4bpp.lz"); -const u16 gItemIconPalette_MachoBrace[] = INCBIN_U16("graphics/items/icon_palettes/macho_brace.gbapal.lz"); - -const u8 gItemIcon_ExpShare[] = INCBIN_U8("graphics/items/icons/exp_share.4bpp.lz"); -const u16 gItemIconPalette_ExpShare[] = INCBIN_U16("graphics/items/icon_palettes/exp_share.gbapal.lz"); - -const u8 gItemIcon_QuickClaw[] = INCBIN_U8("graphics/items/icons/quick_claw.4bpp.lz"); -const u16 gItemIconPalette_QuickClaw[] = INCBIN_U16("graphics/items/icon_palettes/quick_claw.gbapal.lz"); - -const u8 gItemIcon_SootheBell[] = INCBIN_U8("graphics/items/icons/soothe_bell.4bpp.lz"); -const u16 gItemIconPalette_SootheBell[] = INCBIN_U16("graphics/items/icon_palettes/soothe_bell.gbapal.lz"); - -const u16 gItemIconPalette_MentalHerb[] = INCBIN_U16("graphics/items/icon_palettes/mental_herb.gbapal.lz"); - -const u8 gItemIcon_ChoiceBand[] = INCBIN_U8("graphics/items/icons/choice_band.4bpp.lz"); -const u16 gItemIconPalette_ChoiceBand[] = INCBIN_U16("graphics/items/icon_palettes/choice_band.gbapal.lz"); - -const u8 gItemIcon_KingsRock[] = INCBIN_U8("graphics/items/icons/kings_rock.4bpp.lz"); -const u16 gItemIconPalette_KingsRock[] = INCBIN_U16("graphics/items/icon_palettes/kings_rock.gbapal.lz"); - -const u8 gItemIcon_SilverPowder[] = INCBIN_U8("graphics/items/icons/silver_powder.4bpp.lz"); -const u16 gItemIconPalette_SilverPowder[] = INCBIN_U16("graphics/items/icon_palettes/silver_powder.gbapal.lz"); - -const u8 gItemIcon_AmuletCoin[] = INCBIN_U8("graphics/items/icons/amulet_coin.4bpp.lz"); -const u16 gItemIconPalette_AmuletCoin[] = INCBIN_U16("graphics/items/icon_palettes/amulet_coin.gbapal.lz"); - -const u8 gItemIcon_CleanseTag[] = INCBIN_U8("graphics/items/icons/cleanse_tag.4bpp.lz"); -const u16 gItemIconPalette_CleanseTag[] = INCBIN_U16("graphics/items/icon_palettes/cleanse_tag.gbapal.lz"); - -const u8 gItemIcon_SoulDew[] = INCBIN_U8("graphics/items/icons/soul_dew.4bpp.lz"); -const u16 gItemIconPalette_SoulDew[] = INCBIN_U16("graphics/items/icon_palettes/soul_dew.gbapal.lz"); - -const u8 gItemIcon_DeepSeaTooth[] = INCBIN_U8("graphics/items/icons/deep_sea_tooth.4bpp.lz"); -const u16 gItemIconPalette_DeepSeaTooth[] = INCBIN_U16("graphics/items/icon_palettes/deep_sea_tooth.gbapal.lz"); - -const u8 gItemIcon_DeepSeaScale[] = INCBIN_U8("graphics/items/icons/deep_sea_scale.4bpp.lz"); -const u16 gItemIconPalette_DeepSeaScale[] = INCBIN_U16("graphics/items/icon_palettes/deep_sea_scale.gbapal.lz"); - -const u8 gItemIcon_SmokeBall[] = INCBIN_U8("graphics/items/icons/smoke_ball.4bpp.lz"); -const u16 gItemIconPalette_SmokeBall[] = INCBIN_U16("graphics/items/icon_palettes/smoke_ball.gbapal.lz"); - -const u8 gItemIcon_Everstone[] = INCBIN_U8("graphics/items/icons/everstone.4bpp.lz"); -const u16 gItemIconPalette_Everstone[] = INCBIN_U16("graphics/items/icon_palettes/everstone.gbapal.lz"); - -const u8 gItemIcon_FocusBand[] = INCBIN_U8("graphics/items/icons/focus_band.4bpp.lz"); -const u16 gItemIconPalette_FocusBand[] = INCBIN_U16("graphics/items/icon_palettes/focus_band.gbapal.lz"); - -const u8 gItemIcon_LuckyEgg[] = INCBIN_U8("graphics/items/icons/lucky_egg.4bpp.lz"); -const u16 gItemIconPalette_LuckyEgg[] = INCBIN_U16("graphics/items/icon_palettes/lucky_egg.gbapal.lz"); - -const u8 gItemIcon_ScopeLens[] = INCBIN_U8("graphics/items/icons/scope_lens.4bpp.lz"); -const u16 gItemIconPalette_ScopeLens[] = INCBIN_U16("graphics/items/icon_palettes/scope_lens.gbapal.lz"); - -const u8 gItemIcon_MetalCoat[] = INCBIN_U8("graphics/items/icons/metal_coat.4bpp.lz"); -const u16 gItemIconPalette_MetalCoat[] = INCBIN_U16("graphics/items/icon_palettes/metal_coat.gbapal.lz"); - -const u8 gItemIcon_Leftovers[] = INCBIN_U8("graphics/items/icons/leftovers.4bpp.lz"); -const u16 gItemIconPalette_Leftovers[] = INCBIN_U16("graphics/items/icon_palettes/leftovers.gbapal.lz"); - -const u8 gItemIcon_DragonScale[] = INCBIN_U8("graphics/items/icons/dragon_scale.4bpp.lz"); -const u16 gItemIconPalette_DragonScale[] = INCBIN_U16("graphics/items/icon_palettes/dragon_scale.gbapal.lz"); - -const u8 gItemIcon_LightBall[] = INCBIN_U8("graphics/items/icons/light_ball.4bpp.lz"); -const u16 gItemIconPalette_LightBall[] = INCBIN_U16("graphics/items/icon_palettes/light_ball.gbapal.lz"); - -const u8 gItemIcon_SoftSand[] = INCBIN_U8("graphics/items/icons/soft_sand.4bpp.lz"); -const u16 gItemIconPalette_SoftSand[] = INCBIN_U16("graphics/items/icon_palettes/soft_sand.gbapal.lz"); - -const u8 gItemIcon_HardStone[] = INCBIN_U8("graphics/items/icons/hard_stone.4bpp.lz"); -const u16 gItemIconPalette_HardStone[] = INCBIN_U16("graphics/items/icon_palettes/hard_stone.gbapal.lz"); - -const u8 gItemIcon_MiracleSeed[] = INCBIN_U8("graphics/items/icons/miracle_seed.4bpp.lz"); -const u16 gItemIconPalette_MiracleSeed[] = INCBIN_U16("graphics/items/icon_palettes/miracle_seed.gbapal.lz"); - -const u8 gItemIcon_BlackGlasses[] = INCBIN_U8("graphics/items/icons/black_glasses.4bpp.lz"); -const u16 gItemIconPalette_BlackTypeEnhancingItem[] = INCBIN_U16("graphics/items/icon_palettes/black_type_enhancing_item.gbapal.lz"); - -const u8 gItemIcon_BlackBelt[] = INCBIN_U8("graphics/items/icons/black_belt.4bpp.lz"); - -const u8 gItemIcon_Magnet[] = INCBIN_U8("graphics/items/icons/magnet.4bpp.lz"); -const u16 gItemIconPalette_Magnet[] = INCBIN_U16("graphics/items/icon_palettes/magnet.gbapal.lz"); - -const u8 gItemIcon_MysticWater[] = INCBIN_U8("graphics/items/icons/mystic_water.4bpp.lz"); -const u16 gItemIconPalette_MysticWater[] = INCBIN_U16("graphics/items/icon_palettes/mystic_water.gbapal.lz"); - -const u8 gItemIcon_SharpBeak[] = INCBIN_U8("graphics/items/icons/sharp_beak.4bpp.lz"); -const u16 gItemIconPalette_SharpBeak[] = INCBIN_U16("graphics/items/icon_palettes/sharp_beak.gbapal.lz"); - -const u8 gItemIcon_PoisonBarb[] = INCBIN_U8("graphics/items/icons/poison_barb.4bpp.lz"); -const u16 gItemIconPalette_PoisonBarb[] = INCBIN_U16("graphics/items/icon_palettes/poison_barb.gbapal.lz"); - -const u8 gItemIcon_NeverMeltIce[] = INCBIN_U8("graphics/items/icons/never_melt_ice.4bpp.lz"); -const u16 gItemIconPalette_NeverMeltIce[] = INCBIN_U16("graphics/items/icon_palettes/never_melt_ice.gbapal.lz"); - -const u8 gItemIcon_SpellTag[] = INCBIN_U8("graphics/items/icons/spell_tag.4bpp.lz"); -const u16 gItemIconPalette_SpellTag[] = INCBIN_U16("graphics/items/icon_palettes/spell_tag.gbapal.lz"); - -const u8 gItemIcon_TwistedSpoon[] = INCBIN_U8("graphics/items/icons/twisted_spoon.4bpp.lz"); -const u16 gItemIconPalette_TwistedSpoon[] = INCBIN_U16("graphics/items/icon_palettes/twisted_spoon.gbapal.lz"); - -const u8 gItemIcon_Charcoal[] = INCBIN_U8("graphics/items/icons/charcoal.4bpp.lz"); -const u16 gItemIconPalette_Charcoal[] = INCBIN_U16("graphics/items/icon_palettes/charcoal.gbapal.lz"); - -const u8 gItemIcon_DragonFang[] = INCBIN_U8("graphics/items/icons/dragon_fang.4bpp.lz"); -const u16 gItemIconPalette_DragonFang[] = INCBIN_U16("graphics/items/icon_palettes/dragon_fang.gbapal.lz"); - -const u8 gItemIcon_SilkScarf[] = INCBIN_U8("graphics/items/icons/silk_scarf.4bpp.lz"); -const u16 gItemIconPalette_SilkScarf[] = INCBIN_U16("graphics/items/icon_palettes/silk_scarf.gbapal.lz"); - -const u8 gItemIcon_UpGrade[] = INCBIN_U8("graphics/items/icons/up_grade.4bpp.lz"); -const u16 gItemIconPalette_UpGrade[] = INCBIN_U16("graphics/items/icon_palettes/up_grade.gbapal.lz"); - -const u8 gItemIcon_ShellBell[] = INCBIN_U8("graphics/items/icons/shell_bell.4bpp.lz"); - -const u8 gItemIcon_SeaIncense[] = INCBIN_U8("graphics/items/icons/sea_incense.4bpp.lz"); -const u16 gItemIconPalette_SeaIncense[] = INCBIN_U16("graphics/items/icon_palettes/sea_incense.gbapal.lz"); - -const u8 gItemIcon_LaxIncense[] = INCBIN_U8("graphics/items/icons/lax_incense.4bpp.lz"); -const u16 gItemIconPalette_LaxIncense[] = INCBIN_U16("graphics/items/icon_palettes/lax_incense.gbapal.lz"); - -const u8 gItemIcon_LuckyPunch[] = INCBIN_U8("graphics/items/icons/lucky_punch.4bpp.lz"); -const u16 gItemIconPalette_LuckyPunch[] = INCBIN_U16("graphics/items/icon_palettes/lucky_punch.gbapal.lz"); - -const u8 gItemIcon_MetalPowder[] = INCBIN_U8("graphics/items/icons/metal_powder.4bpp.lz"); -const u16 gItemIconPalette_MetalPowder[] = INCBIN_U16("graphics/items/icon_palettes/metal_powder.gbapal.lz"); - -const u8 gItemIcon_ThickClub[] = INCBIN_U8("graphics/items/icons/thick_club.4bpp.lz"); -const u16 gItemIconPalette_ThickClub[] = INCBIN_U16("graphics/items/icon_palettes/thick_club.gbapal.lz"); - -const u8 gItemIcon_Stick[] = INCBIN_U8("graphics/items/icons/stick.4bpp.lz"); -const u16 gItemIconPalette_Stick[] = INCBIN_U16("graphics/items/icon_palettes/stick.gbapal.lz"); - -const u8 gItemIcon_Scarf[] = INCBIN_U8("graphics/items/icons/scarf.4bpp.lz"); -const u16 gItemIconPalette_RedScarf[] = INCBIN_U16("graphics/items/icon_palettes/red_scarf.gbapal.lz"); -const u16 gItemIconPalette_BlueScarf[] = INCBIN_U16("graphics/items/icon_palettes/blue_scarf.gbapal.lz"); -const u16 gItemIconPalette_PinkScarf[] = INCBIN_U16("graphics/items/icon_palettes/pink_scarf.gbapal.lz"); -const u16 gItemIconPalette_GreenScarf[] = INCBIN_U16("graphics/items/icon_palettes/green_scarf.gbapal.lz"); -const u16 gItemIconPalette_YellowScarf[] = INCBIN_U16("graphics/items/icon_palettes/yellow_scarf.gbapal.lz"); - -// Key items - -const u8 gItemIcon_MachBike[] = INCBIN_U8("graphics/items/icons/mach_bike.4bpp.lz"); -const u16 gItemIconPalette_MachBike[] = INCBIN_U16("graphics/items/icon_palettes/mach_bike.gbapal.lz"); - -const u8 gItemIcon_CoinCase[] = INCBIN_U8("graphics/items/icons/coin_case.4bpp.lz"); -const u16 gItemIconPalette_CoinCase[] = INCBIN_U16("graphics/items/icon_palettes/coin_case.gbapal.lz"); - -const u8 gItemIcon_Itemfinder[] = INCBIN_U8("graphics/items/icons/itemfinder.4bpp.lz"); -const u16 gItemIconPalette_Itemfinder[] = INCBIN_U16("graphics/items/icon_palettes/itemfinder.gbapal.lz"); - -const u8 gItemIcon_OldRod[] = INCBIN_U8("graphics/items/icons/old_rod.4bpp.lz"); -const u16 gItemIconPalette_OldRod[] = INCBIN_U16("graphics/items/icon_palettes/old_rod.gbapal.lz"); - -const u8 gItemIcon_GoodRod[] = INCBIN_U8("graphics/items/icons/good_rod.4bpp.lz"); -const u16 gItemIconPalette_GoodRod[] = INCBIN_U16("graphics/items/icon_palettes/good_rod.gbapal.lz"); - -const u8 gItemIcon_SuperRod[] = INCBIN_U8("graphics/items/icons/super_rod.4bpp.lz"); -const u16 gItemIconPalette_SuperRod[] = INCBIN_U16("graphics/items/icon_palettes/super_rod.gbapal.lz"); - -const u8 gItemIcon_SSTicket[] = INCBIN_U8("graphics/items/icons/ss_ticket.4bpp.lz"); -const u16 gItemIconPalette_SSTicket[] = INCBIN_U16("graphics/items/icon_palettes/ss_ticket.gbapal.lz"); - -const u8 gItemIcon_ContestPass[] = INCBIN_U8("graphics/items/icons/contest_pass.4bpp.lz"); -const u16 gItemIconPalette_ContestPass[] = INCBIN_U16("graphics/items/icon_palettes/contest_pass.gbapal.lz"); - -const u8 gItemIcon_WailmerPail[] = INCBIN_U8("graphics/items/icons/wailmer_pail.4bpp.lz"); -const u16 gItemIconPalette_WailmerPail[] = INCBIN_U16("graphics/items/icon_palettes/wailmer_pail.gbapal.lz"); - -const u8 gItemIcon_DevonGoods[] = INCBIN_U8("graphics/items/icons/devon_goods.4bpp.lz"); -const u16 gItemIconPalette_DevonGoods[] = INCBIN_U16("graphics/items/icon_palettes/devon_goods.gbapal.lz"); - -const u8 gItemIcon_SootSack[] = INCBIN_U8("graphics/items/icons/soot_sack.4bpp.lz"); -const u16 gItemIconPalette_SootSack[] = INCBIN_U16("graphics/items/icon_palettes/soot_sack.gbapal.lz"); - -const u8 gItemIcon_BasementKey[] = INCBIN_U8("graphics/items/icons/basement_key.4bpp.lz"); -const u16 gItemIconPalette_OldKey[] = INCBIN_U16("graphics/items/icon_palettes/old_key.gbapal.lz"); - -const u8 gItemIcon_AcroBike[] = INCBIN_U8("graphics/items/icons/acro_bike.4bpp.lz"); -const u16 gItemIconPalette_AcroBike[] = INCBIN_U16("graphics/items/icon_palettes/acro_bike.gbapal.lz"); - -const u8 gItemIcon_PokeblockCase[] = INCBIN_U8("graphics/items/icons/pokeblock_case.4bpp.lz"); -const u16 gItemIconPalette_PokeblockCase[] = INCBIN_U16("graphics/items/icon_palettes/pokeblock_case.gbapal.lz"); - -const u8 gItemIcon_Letter[] = INCBIN_U8("graphics/items/icons/letter.4bpp.lz"); -const u8 gItemIcon_EonTicket[] = INCBIN_U8("graphics/items/icons/eon_ticket.4bpp.lz"); - -const u16 gItemIconPalette_EonTicket[] = INCBIN_U16("graphics/items/icon_palettes/eon_ticket.gbapal.lz"); - -const u8 gItemIcon_Orb[] = INCBIN_U8("graphics/items/icons/orb.4bpp.lz"); -const u16 gItemIconPalette_RedOrb[] = INCBIN_U16("graphics/items/icon_palettes/red_orb.gbapal.lz"); -const u16 gItemIconPalette_BlueOrb[] = INCBIN_U16("graphics/items/icon_palettes/blue_orb.gbapal.lz"); - -const u8 gItemIcon_Scanner[] = INCBIN_U8("graphics/items/icons/scanner.4bpp.lz"); -const u16 gItemIconPalette_Scanner[] = INCBIN_U16("graphics/items/icon_palettes/scanner.gbapal.lz"); - -const u8 gItemIcon_GoGoggles[] = INCBIN_U8("graphics/items/icons/go_goggles.4bpp.lz"); -const u16 gItemIconPalette_GoGoggles[] = INCBIN_U16("graphics/items/icon_palettes/go_goggles.gbapal.lz"); - -const u8 gItemIcon_Meteorite[] = INCBIN_U8("graphics/items/icons/meteorite.4bpp.lz"); -const u16 gItemIconPalette_Meteorite[] = INCBIN_U16("graphics/items/icon_palettes/meteorite.gbapal.lz"); - -const u8 gItemIcon_Room1Key[] = INCBIN_U8("graphics/items/icons/room1_key.4bpp.lz"); - -const u8 gItemIcon_Room2Key[] = INCBIN_U8("graphics/items/icons/room2_key.4bpp.lz"); - -const u8 gItemIcon_Room4Key[] = INCBIN_U8("graphics/items/icons/room4_key.4bpp.lz"); - -const u8 gItemIcon_Room6Key[] = INCBIN_U8("graphics/items/icons/room6_key.4bpp.lz"); - -const u8 gItemIcon_StorageKey[] = INCBIN_U8("graphics/items/icons/storage_key.4bpp.lz"); - -const u8 gItemIcon_RootFossil[] = INCBIN_U8("graphics/items/icons/root_fossil.4bpp.lz"); -const u16 gItemIconPalette_HoennFossil[] = INCBIN_U16("graphics/items/icon_palettes/hoenn_fossil.gbapal.lz"); -const u8 gItemIcon_ClawFossil[] = INCBIN_U8("graphics/items/icons/claw_fossil.4bpp.lz"); - -const u8 gItemIcon_DevonScope[] = INCBIN_U8("graphics/items/icons/devon_scope.4bpp.lz"); -const u16 gItemIconPalette_DevonScope[] = INCBIN_U16("graphics/items/icon_palettes/devon_scope.gbapal.lz"); - -// TMs/HMs - -const u8 gItemIcon_TM[] = INCBIN_U8("graphics/items/icons/tm.4bpp.lz"); - -const u16 gItemIconPalette_FightingTMHM[] = INCBIN_U16("graphics/items/icon_palettes/fighting_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_DragonTMHM[] = INCBIN_U16("graphics/items/icon_palettes/dragon_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_WaterTMHM[] = INCBIN_U16("graphics/items/icon_palettes/water_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_PsychicTMHM[] = INCBIN_U16("graphics/items/icon_palettes/psychic_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_NormalTMHM[] = INCBIN_U16("graphics/items/icon_palettes/normal_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_PoisonTMHM[] = INCBIN_U16("graphics/items/icon_palettes/poison_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_IceTMHM[] = INCBIN_U16("graphics/items/icon_palettes/ice_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_GrassTMHM[] = INCBIN_U16("graphics/items/icon_palettes/grass_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_FireTMHM[] = INCBIN_U16("graphics/items/icon_palettes/fire_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_DarkTMHM[] = INCBIN_U16("graphics/items/icon_palettes/dark_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_SteelTMHM[] = INCBIN_U16("graphics/items/icon_palettes/steel_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_ElectricTMHM[] = INCBIN_U16("graphics/items/icon_palettes/electric_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_GroundTMHM[] = INCBIN_U16("graphics/items/icon_palettes/ground_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_GhostTMHM[] = INCBIN_U16("graphics/items/icon_palettes/ghost_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_RockTMHM[] = INCBIN_U16("graphics/items/icon_palettes/rock_tm_hm.gbapal.lz"); - -const u16 gItemIconPalette_FlyingTMHM[] = INCBIN_U16("graphics/items/icon_palettes/flying_tm_hm.gbapal.lz"); - -const u8 gItemIcon_HM[] = INCBIN_U8("graphics/items/icons/hm.4bpp.lz"); - -// FireRed/LeafGreen key items - -const u8 gItemIcon_OaksParcel[] = INCBIN_U8("graphics/items/icons/oaks_parcel.4bpp.lz"); -const u16 gItemIconPalette_OaksParcel[] = INCBIN_U16("graphics/items/icon_palettes/oaks_parcel.gbapal.lz"); - -const u8 gItemIcon_PokeFlute[] = INCBIN_U8("graphics/items/icons/poke_flute.4bpp.lz"); -const u16 gItemIconPalette_PokeFlute[] = INCBIN_U16("graphics/items/icon_palettes/poke_flute.gbapal.lz"); - -const u8 gItemIcon_SecretKey[] = INCBIN_U8("graphics/items/icons/secret_key.4bpp.lz"); -const u16 gItemIconPalette_SecretKey[] = INCBIN_U16("graphics/items/icon_palettes/secret_key.gbapal.lz"); - -const u8 gItemIcon_BikeVoucher[] = INCBIN_U8("graphics/items/icons/bike_voucher.4bpp.lz"); -const u16 gItemIconPalette_BikeVoucher[] = INCBIN_U16("graphics/items/icon_palettes/bike_voucher.gbapal.lz"); - -const u8 gItemIcon_GoldTeeth[] = INCBIN_U8("graphics/items/icons/gold_teeth.4bpp.lz"); -const u16 gItemIconPalette_GoldTeeth[] = INCBIN_U16("graphics/items/icon_palettes/gold_teeth.gbapal.lz"); - -const u8 gItemIcon_OldAmber[] = INCBIN_U8("graphics/items/icons/old_amber.4bpp.lz"); -const u16 gItemIconPalette_OldAmber[] = INCBIN_U16("graphics/items/icon_palettes/old_amber.gbapal.lz"); - -const u8 gItemIcon_CardKey[] = INCBIN_U8("graphics/items/icons/card_key.4bpp.lz"); -const u16 gItemIconPalette_CardKey[] = INCBIN_U16("graphics/items/icon_palettes/card_key.gbapal.lz"); - -const u8 gItemIcon_LiftKey[] = INCBIN_U8("graphics/items/icons/lift_key.4bpp.lz"); -const u16 gItemIconPalette_Key[] = INCBIN_U16("graphics/items/icon_palettes/key.gbapal.lz"); - -const u8 gItemIcon_HelixFossil[] = INCBIN_U8("graphics/items/icons/helix_fossil.4bpp.lz"); -const u16 gItemIconPalette_KantoFossil[] = INCBIN_U16("graphics/items/icon_palettes/kanto_fossil.gbapal.lz"); -const u8 gItemIcon_DomeFossil[] = INCBIN_U8("graphics/items/icons/dome_fossil.4bpp.lz"); - -const u8 gItemIcon_SilphScope[] = INCBIN_U8("graphics/items/icons/silph_scope.4bpp.lz"); -const u16 gItemIconPalette_SilphScope[] = INCBIN_U16("graphics/items/icon_palettes/silph_scope.gbapal.lz"); - -const u8 gItemIcon_Bicycle[] = INCBIN_U8("graphics/items/icons/bicycle.4bpp.lz"); -const u16 gItemIconPalette_Bicycle[] = INCBIN_U16("graphics/items/icon_palettes/bicycle.gbapal.lz"); - -const u8 gItemIcon_TownMap[] = INCBIN_U8("graphics/items/icons/town_map.4bpp.lz"); -const u16 gItemIconPalette_TownMap[] = INCBIN_U16("graphics/items/icon_palettes/town_map.gbapal.lz"); - -const u8 gItemIcon_VSSeeker[] = INCBIN_U8("graphics/items/icons/vs_seeker.4bpp.lz"); -const u16 gItemIconPalette_VSSeeker[] = INCBIN_U16("graphics/items/icon_palettes/vs_seeker.gbapal.lz"); - -const u8 gItemIcon_FameChecker[] = INCBIN_U8("graphics/items/icons/fame_checker.4bpp.lz"); -const u16 gItemIconPalette_FameChecker[] = INCBIN_U16("graphics/items/icon_palettes/fame_checker.gbapal.lz"); - -const u8 gItemIcon_TMCase[] = INCBIN_U8("graphics/items/icons/tm_case.4bpp.lz"); -const u16 gItemIconPalette_TMCase[] = INCBIN_U16("graphics/items/icon_palettes/tm_case.gbapal.lz"); - -const u8 gItemIcon_BerryPouch[] = INCBIN_U8("graphics/items/icons/berry_pouch.4bpp.lz"); -const u16 gItemIconPalette_BerryPouch[] = INCBIN_U16("graphics/items/icon_palettes/berry_pouch.gbapal.lz"); - -const u8 gItemIcon_TeachyTV[] = INCBIN_U8("graphics/items/icons/teachy_tv.4bpp.lz"); -const u16 gItemIconPalette_TeachyTV[] = INCBIN_U16("graphics/items/icon_palettes/teachy_tv.gbapal.lz"); - -const u8 gItemIcon_TriPass[] = INCBIN_U8("graphics/items/icons/tri_pass.4bpp.lz"); -const u16 gItemIconPalette_TriPass[] = INCBIN_U16("graphics/items/icon_palettes/tri_pass.gbapal.lz"); - -const u8 gItemIcon_RainbowPass[] = INCBIN_U8("graphics/items/icons/rainbow_pass.4bpp.lz"); -const u16 gItemIconPalette_RainbowPass[] = INCBIN_U16("graphics/items/icon_palettes/rainbow_pass.gbapal.lz"); - -const u8 gItemIcon_Tea[] = INCBIN_U8("graphics/items/icons/tea.4bpp.lz"); -const u16 gItemIconPalette_Tea[] = INCBIN_U16("graphics/items/icon_palettes/tea.gbapal.lz"); - -const u8 gItemIcon_MysticTicket[] = INCBIN_U8("graphics/items/icons/mystic_ticket.4bpp.lz"); -const u16 gItemIconPalette_MysticTicket[] = INCBIN_U16("graphics/items/icon_palettes/mystic_ticket.gbapal.lz"); - -const u8 gItemIcon_AuroraTicket[] = INCBIN_U8("graphics/items/icons/aurora_ticket.4bpp.lz"); -const u16 gItemIconPalette_AuroraTicket[] = INCBIN_U16("graphics/items/icon_palettes/aurora_ticket.gbapal.lz"); - -const u8 gItemIcon_PowderJar[] = INCBIN_U8("graphics/items/icons/powder_jar.4bpp.lz"); -const u16 gItemIconPalette_PowderJar[] = INCBIN_U16("graphics/items/icon_palettes/powder_jar.gbapal.lz"); - -const u16 gItemIconPalette_Ruby[] = INCBIN_U16("graphics/items/icon_palettes/ruby.gbapal.lz"); -const u8 gItemIcon_Gem[] = INCBIN_U8("graphics/items/icons/gem.4bpp.lz"); -const u16 gItemIconPalette_Sapphire[] = INCBIN_U16("graphics/items/icon_palettes/sapphire.gbapal.lz"); - -// Emerald-only key items - -const u8 gItemIcon_MagmaEmblem[] = INCBIN_U8("graphics/items/icons/magma_emblem.4bpp.lz"); -const u16 gItemIconPalette_MagmaEmblem[] = INCBIN_U16("graphics/items/icon_palettes/magma_emblem.gbapal.lz"); - -const u8 gItemIcon_OldSeaMap[] = INCBIN_U8("graphics/items/icons/old_sea_map.4bpp.lz"); -const u16 gItemIconPalette_OldSeaMap[] = INCBIN_U16("graphics/items/icon_palettes/old_sea_map.gbapal.lz"); -- cgit v1.2.3 From 279a6e1ddcab8b0430d6fe6f3763a1ac6821daf4 Mon Sep 17 00:00:00 2001 From: Slawter666 <38655737+Slawter666@users.noreply.github.com> Date: Sun, 6 May 2018 13:37:28 +0100 Subject: Convert item_icon_table.inc to C --- src/item_icon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/item_icon.c b/src/item_icon.c index 4aaad9c31..d6fedf892 100644 --- a/src/item_icon.c +++ b/src/item_icon.c @@ -4,13 +4,13 @@ #include "sprite.h" #include "decompress.h" #include "constants/items.h" +#include "data/item_icon_table.h" // EWRAM vars EWRAM_DATA void *gItemIconDecompressionBuffer = NULL; EWRAM_DATA void *gItemIcon4x4Buffer = NULL; // const rom data -extern const void *const gItemIconTable[][2]; // todo: move to C file static const struct OamData sOamData_ItemIcon = { -- cgit v1.2.3 From 0231ed13ee72e0ccb06319a439c04381ace4b1ef Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Mon, 7 May 2018 16:35:29 -0400 Subject: Remaining functions in mauville_old_man --- src/mauville_old_man.c | 112 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) (limited to 'src') diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index 4f85d4577..a21af6f95 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -20,6 +20,7 @@ #include "strings.h" #include "overworld.h" #include "field_message_box.h" +#include "script_menu.h" #define CHAR_SONG_WORD_SEPARATOR 0x37 @@ -1140,3 +1141,114 @@ void sub_8121178(u32 player) // StorytellerDisplayStory ConvertInternationalString(gStringVar3, gUnknown_0203A12C->unk34[player]); ShowFieldMessage(sub_8120EC0(stat)); } + +void sub_81211EC(void) // PrintStoryList +{ + s32 i; + s32 width = GetStringWidth(1, gText_Exit, 0); + u8 tileWidth; + for (i = 0; i < 4; i++) + { + s32 curWidth; + u16 gameStatID = gUnknown_0203A12C->gameStatIDs[i]; + + if (gameStatID == 0) + break; + curWidth = GetStringWidth(1, sub_8120EB4(gameStatID), 0); + if (curWidth > width) + width = curWidth; + } + gUnknown_0203A130 = CreateWindowFromRect(0, 0, convert_pixel_width_to_tile_width(width), sub_8120ED8() * 2 + 2); + SetStandardWindowBorderStyle(gUnknown_0203A130, 0); + for (i = 0; i < 4; i++) + { + u16 gameStatID = gUnknown_0203A12C->gameStatIDs[i]; + if (gameStatID == 0) + break; + PrintTextOnWindow(gUnknown_0203A130, 1, sub_8120EB4(gameStatID), 8, 16 * i + 1, 0xFF, NULL); + } + PrintTextOnWindow(gUnknown_0203A130, 1, gText_Exit, 8, 16 * i + 1, 0xFF, NULL); + InitMenuInUpperLeftCornerPlaySoundWhenAPressed(gUnknown_0203A130, sub_8120ED8() + 1, 0); + CopyWindowToVram(gUnknown_0203A130, 3); +} + +void sub_81212FC(u8 taskId) // Task_StoryListMenu +{ + struct Task *task = &gTasks[taskId]; + s32 selection; + + switch (task->data[0]) + { + case 0: + sub_81211EC(); + task->data[0]++; + break; + case 1: + selection = ProcessMenuInput(); + if (selection == -2) + break; + if (selection == -1 || selection == sub_8120ED8()) + { + gSpecialVar_Result = 0; + } + else + { + gSpecialVar_Result = 1; + gUnknown_03001178 = selection; + } + sub_80E2A78(gUnknown_0203A130); + DestroyTask(taskId); + EnableBothScriptContexts(); + break; + } +} + +// Sets gSpecialVar_Result to TRUE if player selected a story +void sub_8121388(void) // ScrSpecial_StorytellerStoryListMenu +{ + CreateTask(sub_81212FC, 80); +} + +void sub_812139C(void) // ScrSpecial_StorytellerDisplayStory +{ + sub_8121178(gUnknown_03001178); +} + +u8 sub_81213B0(void) // ScrSpecial_StorytellerDisplayStory +{ + gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + return sub_8120ED8(); +} + +// Returns TRUE if stat has increased +bool8 sub_81213D8(void) // ScrSpecial_StorytellerUpdateStat +{ + u8 r4; + gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + r4 = gUnknown_0203A12C->gameStatIDs[gUnknown_03001178]; + + if (sub_8120F4C(gUnknown_03001178) == TRUE) + { + sub_8120FDC(gUnknown_03001178, r4); + return TRUE; + } + return FALSE; +} + + +bool8 sub_8121424(void) // ScrSpecial_HasStorytellerAlreadyRecorded +{ + gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + + if (gUnknown_0203A12C->alreadyRecorded == FALSE) + return FALSE; + else + return TRUE; +} + +bool8 sub_8121450(void) // ScrSpecial_StorytellerInitializeRandomStat +{ + gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + return sub_81210B8(); +} + -- cgit v1.2.3 From 61cc1d55743715a64e793187f63d0f1f7a80b0e0 Mon Sep 17 00:00:00 2001 From: PikalaxALT Date: Mon, 7 May 2018 18:11:20 -0400 Subject: Rename symbols using Ruby as a reference --- src/field_map_obj.c | 2 +- src/mauville_old_man.c | 365 ++++++++++++++++++++++++------------------------- 2 files changed, 180 insertions(+), 187 deletions(-) (limited to 'src') diff --git a/src/field_map_obj.c b/src/field_map_obj.c index a5be62442..81cbe5210 100644 --- a/src/field_map_obj.c +++ b/src/field_map_obj.c @@ -1146,7 +1146,7 @@ const struct MapObjectGraphicsInfo *GetFieldObjectGraphicsInfo(u8 graphicsId) } if (graphicsId == 0x45) { - bard = sub_81201C8(); + bard = GetCurrentMauvilleOldMan(); return gMauvilleOldManGraphicsInfoPointers[bard]; } if (graphicsId >= NUM_OBJECT_GRAPHICS_INFO) diff --git a/src/mauville_old_man.c b/src/mauville_old_man.c index a21af6f95..4da9079ff 100644 --- a/src/mauville_old_man.c +++ b/src/mauville_old_man.c @@ -21,27 +21,25 @@ #include "overworld.h" #include "field_message_box.h" #include "script_menu.h" +#include "trader.h" #define CHAR_SONG_WORD_SEPARATOR 0x37 extern struct MusicPlayerInfo gMPlayInfo_SE2; -void sub_81204DC(void); -void sub_81206C0(bool8 useTemporaryLyrics); // StartBardSong -void sub_8120944(u8 taskId); -void sub_8120B5C(void); -void sub_8120E08(void); // StorytellerSetup -void sub_8120E50(void); -void sub_81339F8(void); // TraderSetup -void sub_8133A60(void); +static void InitGiddyTaleList(void); +static void StartBardSong(bool8 useTemporaryLyrics); +static void Task_BardSong(u8 taskId); +static void StorytellerSetup(void); +static void Storyteller_ResetFlag(void); -IWRAM_DATA u8 gUnknown_03001178; +IWRAM_DATA u8 sSelectedStory; -struct BardSong gUnknown_03006130; +struct BardSong gBardSong; -EWRAM_DATA u16 gUnknown_0203A128 = 0; -EWRAM_DATA struct MauvilleManStoryteller * gUnknown_0203A12C = NULL; -EWRAM_DATA u8 gUnknown_0203A130 = 0; +static EWRAM_DATA u16 sUnknownBardRelated = 0; +static EWRAM_DATA struct MauvilleManStoryteller * sStorytellerPtr = NULL; +static EWRAM_DATA u8 sStorytellerWindowId = 0; static const u16 sDefaultBardSongLyrics[6] = { EC_WORD_SHAKE, @@ -97,7 +95,7 @@ static void SetupHipster(void) static void SetupStoryteller(void) { - sub_8120E08(); + StorytellerSetup(); } static void SetupGiddy(void) @@ -138,22 +136,22 @@ void SetMauvilleOldMan(void) SetupGiddy(); break; } - sub_8120B5C(); + ScrSpecial_SetMauvilleOldManMapObjGfx(); } -u8 sub_81201C8(void) // GetCurrentMauvilleOldMan +u8 GetCurrentMauvilleOldMan(void) { struct MauvilleManCommon *common = &gSaveBlock1Ptr->oldMan.common; return common->id; } -void sub_81201DC(void) // ScrSpecial_GetCurrentMauvilleMan +void ScrSpecial_GetCurrentMauvilleMan(void) { - gSpecialVar_Result = sub_81201C8(); + gSpecialVar_Result = GetCurrentMauvilleOldMan(); } -void sub_81201F4(void) // ScrSpecial_HasBardSongBeenChanged +void ScrSpecial_HasBardSongBeenChanged(void) { u16 *scriptResult = &gSpecialVar_Result; // why?? struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; @@ -161,7 +159,7 @@ void sub_81201F4(void) // ScrSpecial_HasBardSongBeenChanged *scriptResult = bard->hasChangedSong; } -void sub_8120210(void) // ScrSpecial_SaveBardSongLyrics +void ScrSpecial_SaveBardSongLyrics(void) { u16 i; struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; @@ -178,20 +176,14 @@ void sub_8120210(void) // ScrSpecial_SaveBardSongLyrics } // Copies lyrics into gStringVar4 -void sub_8120280(void) +static void PrepareSongText(void) { struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; - u16 specialVar = gSpecialVar_0x8004; // It's a bit odd to use this temp variable, but it seems needed to match. - u16 *lyrics; + u16 * lyrics = gSpecialVar_0x8004 == 0 ? bard->songLyrics : bard->temporaryLyrics; + u8 * wordEnd = gStringVar4; + u8 * str = wordEnd; u16 lineNum; - u8 *wordEnd; - u8 *str; - - lyrics = bard->temporaryLyrics; - if (specialVar == 0) - lyrics = bard->songLyrics; - wordEnd = gStringVar4; - str = wordEnd; + // Put three words on each line for (lineNum = 0; lineNum < 2; lineNum++) { @@ -233,13 +225,13 @@ void sub_8120280(void) } } -void sub_8120340(void) // ScrSpecial_PlayBardSong +void ScrSpecial_PlayBardSong(void) { - sub_81206C0(gSpecialVar_0x8004); + StartBardSong(gSpecialVar_0x8004); ScriptContext1_Stop(); } -void sub_8120358(void) // ScrSpecial_GetHipsterSpokenFlag +void ScrSpecial_GetHipsterSpokenFlag(void) { u16 *scriptResult = &gSpecialVar_Result; // again?? struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; @@ -247,14 +239,14 @@ void sub_8120358(void) // ScrSpecial_GetHipsterSpokenFlag *scriptResult = hipster->alreadySpoken; } -void sub_8120374(void) // ScrSpecial_SetHipsterSpokenFlag +void ScrSpecial_SetHipsterSpokenFlag(void) { struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; hipster->alreadySpoken = TRUE; } -void sub_812038C(void) // ScrSpecial_HipsterTeachWord +void ScrSpecial_HipsterTeachWord(void) { u16 var = sub_811F01C(); @@ -269,7 +261,7 @@ void sub_812038C(void) // ScrSpecial_HipsterTeachWord } } -void sub_81203C4(void) // ScrSpecial_GiddyShouldTellAnotherTale +void ScrSpecial_GiddyShouldTellAnotherTale(void) { struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; @@ -284,12 +276,12 @@ void sub_81203C4(void) // ScrSpecial_GiddyShouldTellAnotherTale } } -void sub_81203FC(void) // ScrSpecial_GenerateGiddyLine +void ScrSpecial_GenerateGiddyLine(void) { struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; if (giddy->taleCounter == 0) - sub_81204DC(); + InitGiddyTaleList(); if (giddy->randomWords[giddy->taleCounter] != 0xFFFF) // is not the last element of the array? { @@ -315,7 +307,7 @@ void sub_81203FC(void) // ScrSpecial_GenerateGiddyLine gSpecialVar_Result = TRUE; } -void sub_81204DC(void) +static void InitGiddyTaleList(void) { struct MauvilleManGiddy *giddy = &gSaveBlock1Ptr->oldMan.giddy; u16 arr[][2] = { @@ -371,50 +363,50 @@ void sub_81204DC(void) } } } -void sub_8120628(void) +static void ResetBardFlag(void) { struct MauvilleManBard *bard = &gSaveBlock1Ptr->oldMan.bard; bard->hasChangedSong = FALSE; } -void sub_8120640(void) +static void ResetHipsterFlag(void) { struct MauvilleManHipster *hipster = &gSaveBlock1Ptr->oldMan.hipster; hipster->alreadySpoken = FALSE; } -void sub_8120658(void) +static void ResetTraderFlag(void) { - sub_8133A60(); + Trader_ResetFlag(); } -void sub_8120664(void) +static void ResetStorytellerFlag(void) { - sub_8120E50(); + Storyteller_ResetFlag(); } -void sub_8120670(void) // ResetMauvilleOldManFlag +void ResetMauvilleOldManFlag(void) // ResetMauvilleOldManFlag { - switch (sub_81201C8()) + switch (GetCurrentMauvilleOldMan()) { case MAUVILLE_MAN_BARD: - sub_8120628(); + ResetBardFlag(); break; case MAUVILLE_MAN_HIPSTER: - sub_8120640(); + ResetHipsterFlag(); break; case MAUVILLE_MAN_STORYTELLER: - sub_8120664(); + ResetStorytellerFlag(); break; case MAUVILLE_MAN_TRADER: - sub_8120658(); + ResetTraderFlag(); break; case MAUVILLE_MAN_GIDDY: break; } - sub_8120B5C(); + ScrSpecial_SetMauvilleOldManMapObjGfx(); } @@ -426,32 +418,32 @@ void sub_8120670(void) // ResetMauvilleOldManFlag #define MACRO1(a) (((a) & 3) + (((a) / 8) & 1)) #define MACRO2(a) (((a) % 4) + (((a) / 8) & 1)) -void sub_81206C0(bool8 useTemporaryLyrics) +static void StartBardSong(bool8 useTemporaryLyrics) { - u8 taskId = CreateTask(sub_8120944, 80); + u8 taskId = CreateTask(Task_BardSong, 80); gTasks[taskId].tUseTemporaryLyrics = useTemporaryLyrics; } -void sub_81206F0(void) +static void sub_81206F0(void) { gUnknown_03002F84 = FALSE; } -void sub_81206FC(struct TextSubPrinter * printer, u16 a1) +static void BardSong_TextSubPrinter(struct TextSubPrinter * printer, u16 a1) { gUnknown_03002F84 = TRUE; } -void sub_8120708(const u8 * src) +static void sub_8120708(const u8 * src) { NewMenuHelpers_DrawDialogueFrame(0, 0); - PrintTextOnWindow(0, 1, src, 0, 1, 1, sub_81206FC); + PrintTextOnWindow(0, 1, src, 0, 1, 1, BardSong_TextSubPrinter); gUnknown_03002F84 = TRUE; CopyWindowToVram(0, 3); } -void sub_8120748(struct Task *task, struct BardSong *song) // BardSing +static void BardSing(struct Task *task, struct BardSong *song) { switch (task->tState) { @@ -554,15 +546,15 @@ void sub_8120748(struct Task *task, struct BardSong *song) // BardSing } } -void sub_8120944(u8 taskId) +static void Task_BardSong(u8 taskId) { struct Task *task = &gTasks[taskId]; // r5 - sub_8120748(task, &gUnknown_03006130); + BardSing(task, &gBardSong); switch (task->tState) { case 0: // Initialize song - sub_8120280(); + PrepareSongText(); sub_8120708(gStringVar4); task->data[1] = 0; task->data[2] = 0; @@ -593,14 +585,14 @@ void sub_8120944(u8 taskId) wordLen++; } if (!task->tUseTemporaryLyrics) - gUnknown_0203A128 = MACRO2(bard->songLyrics[task->tCurrWord]); + sUnknownBardRelated = MACRO2(bard->songLyrics[task->tCurrWord]); else - gUnknown_0203A128 = MACRO2(bard->temporaryLyrics[task->tCurrWord]); - temp = gUnknown_03006130.length / wordLen; + sUnknownBardRelated = MACRO2(bard->temporaryLyrics[task->tCurrWord]); + temp = gBardSong.length / wordLen; zero = 0; - gUnknown_03006130.length = temp; - if (gUnknown_03006130.length <= 0) - gUnknown_03006130.length = 1; + gBardSong.length = temp; + if (gBardSong.length <= 0) + gBardSong.length = 1; task->tCurrWord++; if (task->data[2] == 0) task->tState = 3; @@ -664,7 +656,7 @@ void sub_8120944(u8 taskId) case 2: task->tCharIndex++; task->data[1] = 0; - task->data[2] = gUnknown_03006130.length; + task->data[2] = gBardSong.length; task->tState = 4; break; } @@ -679,11 +671,13 @@ void sub_8120944(u8 taskId) sub_8197224(); } -void sub_8120B5C(void) +void ScrSpecial_SetMauvilleOldManMapObjGfx(void) { VarSet(VAR_0x4010, MAP_OBJ_GFX_BARD); } +// Language fixers? + void sub_8120B70(union OldMan * oldMan) { s32 i; @@ -696,9 +690,9 @@ void sub_8120B70(union OldMan * oldMan) struct MauvilleOldManTrader * trader = &oldMan->trader; for (i = 0; i < 4; i++) { - if (trader->unk32[i] == LANGUAGE_JAPANESE) + if (trader->language[i] == LANGUAGE_JAPANESE) { - ConvertInternationalString(trader->unk5[i], LANGUAGE_JAPANESE); + ConvertInternationalString(trader->playerNames[i], LANGUAGE_JAPANESE); } } } @@ -717,7 +711,7 @@ void sub_8120B70(union OldMan * oldMan) memset(sp00, CHAR_SPACE, 8); StringCopy(sp00, gText_Friend); memcpy(storyteller->trainerNames[i], sp00, 7); - storyteller->unk34[i] = GAME_LANGUAGE; + storyteller->language[i] = GAME_LANGUAGE; } } } @@ -738,13 +732,13 @@ void sub_8120C0C(union OldMan * oldMan, u32 r8, u32 r7, u32 r3) for (i = 0; i < 4; i++) { - if (IsStringJapanese(trader->unk5[i])) + if (IsStringJapanese(trader->playerNames[i])) { - trader->unk32[i] = r8; + trader->language[i] = r8; } else { - trader->unk32[i] = r7; + trader->language[i] = r7; } } } @@ -757,11 +751,11 @@ void sub_8120C0C(union OldMan * oldMan, u32 r8, u32 r7, u32 r3) { if (IsStringJapanese(storyteller->trainerNames[i])) { - storyteller->unk34[i] = r8; + storyteller->language[i] = r8; } else { - storyteller->unk34[i] = r7; + storyteller->language[i] = r7; } } } @@ -814,9 +808,9 @@ void sub_8120CD0(union OldMan * oldMan, u32 unused, u32 a2) memcpy(sp00, storyteller->trainerNames[i], 7); sp00[7] = EOS; if (IsStringJapanese(sp00)) - storyteller->unk34[i] = LANGUAGE_JAPANESE; + storyteller->language[i] = LANGUAGE_JAPANESE; else - storyteller->unk34[i] = GAME_LANGUAGE; + storyteller->language[i] = GAME_LANGUAGE; } } } @@ -836,23 +830,23 @@ void sub_8120D34(union OldMan * oldMan, u32 r1, u32 r6) { for (i = 0; i < 4; i++) { - u8 * str = trader->unk5[i]; + u8 * str = trader->playerNames[i]; if (str[0] == EXT_CTRL_CODE_BEGIN && str[1] == EXT_CTRL_CODE_JPN) { StripExtCtrlCodes(str); - trader->unk32[i] = LANGUAGE_JAPANESE; + trader->language[i] = LANGUAGE_JAPANESE; } else - trader->unk32[i] = r6; + trader->language[i] = r6; } } else { for (i = 0; i < 4; i++) { - if (trader->unk32[i] == LANGUAGE_JAPANESE) + if (trader->language[i] == LANGUAGE_JAPANESE) { - StripExtCtrlCodes(trader->unk5[i]); + StripExtCtrlCodes(trader->playerNames[i]); } } } @@ -869,7 +863,7 @@ void sub_8120D34(union OldMan * oldMan, u32 r1, u32 r6) for (i = 0; i < 4; i++) { if (storyteller->gameStatIDs[i] != 0) - storyteller->unk34[i] = r6; + storyteller->language[i] = r6; } } } @@ -916,7 +910,7 @@ struct Story const u8 *fullText; }; -const struct Story gUnknown_0859F048[] = { +static const struct Story sStorytellerStories[] = { {GAME_STAT_50, 1, MauvilleCity_PokemonCenter_1F_Text_28E930, MauvilleCity_PokemonCenter_1F_Text_28E947, MauvilleCity_PokemonCenter_1F_Text_28E956}, {GAME_STAT_STARTED_TRENDS, 1, MauvilleCity_PokemonCenter_1F_Text_28E9D7, MauvilleCity_PokemonCenter_1F_Text_28E9EF, MauvilleCity_PokemonCenter_1F_Text_28E9FE}, {GAME_STAT_PLANTED_BERRIES, 1, MauvilleCity_PokemonCenter_1F_Text_28EA7D, MauvilleCity_PokemonCenter_1F_Text_28EA98, MauvilleCity_PokemonCenter_1F_Text_28EAA8}, @@ -955,84 +949,84 @@ const struct Story gUnknown_0859F048[] = { {GAME_STAT_ENTERED_HOT_SPRINGS, 1, MauvilleCity_PokemonCenter_1F_Text_290097, MauvilleCity_PokemonCenter_1F_Text_2900B5, MauvilleCity_PokemonCenter_1F_Text_2900CB} }; -void sub_8120E08(void) // StorytellerSetup +static void StorytellerSetup(void) { s32 i; - gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + sStorytellerPtr = &gSaveBlock1Ptr->oldMan.storyteller; - gUnknown_0203A12C->id = MAUVILLE_MAN_STORYTELLER; - gUnknown_0203A12C->alreadyRecorded = FALSE; + sStorytellerPtr->id = MAUVILLE_MAN_STORYTELLER; + sStorytellerPtr->alreadyRecorded = FALSE; for (i = 0; i < 4; i++) { - gUnknown_0203A12C->gameStatIDs[i] = 0; - gUnknown_0203A12C->trainerNames[0][i] = EOS; // Maybe they meant storyteller->trainerNames[i][0] instead? + sStorytellerPtr->gameStatIDs[i] = 0; + sStorytellerPtr->trainerNames[0][i] = EOS; // Maybe they meant storyteller->trainerNames[i][0] instead? } } -void sub_8120E50(void) +static void Storyteller_ResetFlag(void) { - gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + sStorytellerPtr = &gSaveBlock1Ptr->oldMan.storyteller; - gUnknown_0203A12C->id = MAUVILLE_MAN_STORYTELLER; - gUnknown_0203A12C->alreadyRecorded = FALSE; + sStorytellerPtr->id = MAUVILLE_MAN_STORYTELLER; + sStorytellerPtr->alreadyRecorded = FALSE; } -u32 sub_8120E74(u8 stat) // StorytellerGetGameStat +static u32 StorytellerGetGameStat(u8 stat) { if (stat == 50) stat = 0; return GetGameStat(stat); } -const struct Story *sub_8120E88(u32 stat) // GetStoryByStat +static const struct Story *GetStoryByStat(u32 stat) { s32 i; for (i = 0; i < 36; i++) { - if (gUnknown_0859F048[i].stat == stat) - return &gUnknown_0859F048[i]; + if (sStorytellerStories[i].stat == stat) + return &sStorytellerStories[i]; } - return &gUnknown_0859F048[35]; + return &sStorytellerStories[35]; } -const u8 *sub_8120EB4(u32 stat) // GetStoryTitleByStat +static const u8 *GetStoryTitleByStat(u32 stat) { - return sub_8120E88(stat)->title; + return GetStoryByStat(stat)->title; } -const u8 *sub_8120EC0(u32 stat) // GetStoryTextByStat +static const u8 *GetStoryTextByStat(u32 stat) { - return sub_8120E88(stat)->fullText; + return GetStoryByStat(stat)->fullText; } -const u8 *sub_8120ECC(u32 stat) // GetStoryActionByStat +static const u8 *GetStoryActionByStat(u32 stat) { - return sub_8120E88(stat)->action; + return GetStoryByStat(stat)->action; } -u8 sub_8120ED8(void) // GetFreeStorySlot +static u8 GetFreeStorySlot(void) { u8 i; for (i = 0; i < 4; i++) { - if (gUnknown_0203A12C->gameStatIDs[i] == 0) + if (sStorytellerPtr->gameStatIDs[i] == 0) break; } return i; } -u32 sub_8120F08(u32 trainer) // StorytellerGetRecordedTrainerStat +static u32 StorytellerGetRecordedTrainerStat(u32 trainer) { - u8 *ptr = gUnknown_0203A12C->statValues[trainer]; + u8 *ptr = sStorytellerPtr->statValues[trainer]; return ptr[0] | (ptr[1] << 8) | (ptr[2] << 16) | (ptr[3] << 24); } -void sub_8120F2C(u32 trainer, u32 val) // StorytellerSetRecordedTrainerStat +static void StorytellerSetRecordedTrainerStat(u32 trainer, u32 val) { - u8 *ptr = gUnknown_0203A12C->statValues[trainer]; + u8 *ptr = sStorytellerPtr->statValues[trainer]; ptr[0] = val; ptr[1] = val >> 8; @@ -1040,41 +1034,41 @@ void sub_8120F2C(u32 trainer, u32 val) // StorytellerSetRecordedTrainerStat ptr[3] = val >> 24; } -bool32 sub_8120F4C(u32 trainer) // HasTrainerStatIncreased +static bool32 HasTrainerStatIncreased(u32 trainer) { - if (sub_8120E74(gUnknown_0203A12C->gameStatIDs[trainer]) > sub_8120F08(trainer)) + if (StorytellerGetGameStat(sStorytellerPtr->gameStatIDs[trainer]) > StorytellerGetRecordedTrainerStat(trainer)) return TRUE; else return FALSE; } -void sub_8120F7C(u32 player, void *dst) // GetStoryByStattellerPlayerName +static void GetStoryByStattellerPlayerName(u32 player, void *dst) { - u8 *name = gUnknown_0203A12C->trainerNames[player]; + u8 *name = sStorytellerPtr->trainerNames[player]; memset(dst, EOS, 8); memcpy(dst, name, 7); } -void sub_8120FAC(u32 player, const u8 * src) // StorytellerSetPlayerName +static void StorytellerSetPlayerName(u32 player, const u8 * src) { - u8 * name = gUnknown_0203A12C->trainerNames[player]; + u8 * name = sStorytellerPtr->trainerNames[player]; memset(name, EOS, 7); memcpy(name, src, 7); } -void sub_8120FDC(u32 player, u32 stat) // StorytellerRecordNewStat +static void StorytellerRecordNewStat(u32 player, u32 stat) { - gUnknown_0203A12C->gameStatIDs[player] = stat; - sub_8120FAC(player, gSaveBlock2Ptr->playerName); - sub_8120F2C(player, sub_8120E74(stat)); - ConvertIntToDecimalStringN(gStringVar1, sub_8120E74(stat), STR_CONV_MODE_LEFT_ALIGN, 10); - StringCopy(gStringVar2, sub_8120ECC(stat)); - gUnknown_0203A12C->unk34[player] = gGameLanguage; + sStorytellerPtr->gameStatIDs[player] = stat; + StorytellerSetPlayerName(player, gSaveBlock2Ptr->playerName); + StorytellerSetRecordedTrainerStat(player, StorytellerGetGameStat(stat)); + ConvertIntToDecimalStringN(gStringVar1, StorytellerGetGameStat(stat), STR_CONV_MODE_LEFT_ALIGN, 10); + StringCopy(gStringVar2, GetStoryActionByStat(stat)); + sStorytellerPtr->language[player] = gGameLanguage; } -void sub_8121064(u8 * arr, s32 count) // ScrambleStatList +static void ScrambleStatList(u8 * arr, s32 count) { s32 i; @@ -1092,57 +1086,57 @@ void sub_8121064(u8 * arr, s32 count) // ScrambleStatList struct UnknownStruct_0859F288 { - u32 length; + s32 length; u32 unused2; }; -const struct UnknownStruct_0859F288 gUnknown_0859F288 = { - 36, - 8 +static const struct UnknownStruct_0859F288 sStorytellerStuff = { + ARRAY_COUNT(sStorytellerStories), + sizeof(sStorytellerStuff) }; -bool8 sub_81210B8(void) // StorytellerInitializeRandomStat +static bool8 StorytellerInitializeRandomStat(void) { - u8 arr[gUnknown_0859F288.length]; + u8 arr[sStorytellerStuff.length]; s32 i; s32 j; - sub_8121064(arr, 36); - for (i = 0; i < 36; i++) + ScrambleStatList(arr, ARRAY_COUNT(sStorytellerStories)); + for (i = 0; i < (s32)ARRAY_COUNT(sStorytellerStories); i++) { - u8 stat = gUnknown_0859F048[arr[i]].stat; - u8 minVal = gUnknown_0859F048[arr[i]].minVal; + u8 stat = sStorytellerStories[arr[i]].stat; + u8 minVal = sStorytellerStories[arr[i]].minVal; for (j = 0; j < 4; j++) { - if (gUnknown_0203A12C->gameStatIDs[j] == stat) + if (sStorytellerPtr->gameStatIDs[j] == stat) break; } - if (j == 4 && sub_8120E74(stat) >= minVal) + if (j == 4 && StorytellerGetGameStat(stat) >= minVal) { - gUnknown_0203A12C->alreadyRecorded = TRUE; - if (sub_8120ED8() == 4) - sub_8120FDC(gUnknown_03001178, stat); + sStorytellerPtr->alreadyRecorded = TRUE; + if (GetFreeStorySlot() == 4) + StorytellerRecordNewStat(sSelectedStory, stat); else - sub_8120FDC(sub_8120ED8(), stat); + StorytellerRecordNewStat(GetFreeStorySlot(), stat); return TRUE; } } return FALSE; } -void sub_8121178(u32 player) // StorytellerDisplayStory +static void StorytellerDisplayStory(u32 player) { - u8 stat = gUnknown_0203A12C->gameStatIDs[player]; + u8 stat = sStorytellerPtr->gameStatIDs[player]; - ConvertIntToDecimalStringN(gStringVar1, sub_8120F08(player), 0, 10); - StringCopy(gStringVar2, sub_8120ECC(stat)); - sub_8120F7C(player, gStringVar3); - ConvertInternationalString(gStringVar3, gUnknown_0203A12C->unk34[player]); - ShowFieldMessage(sub_8120EC0(stat)); + ConvertIntToDecimalStringN(gStringVar1, StorytellerGetRecordedTrainerStat(player), 0, 10); + StringCopy(gStringVar2, GetStoryActionByStat(stat)); + GetStoryByStattellerPlayerName(player, gStringVar3); + ConvertInternationalString(gStringVar3, sStorytellerPtr->language[player]); + ShowFieldMessage(GetStoryTextByStat(stat)); } -void sub_81211EC(void) // PrintStoryList +static void PrintStoryList(void) { s32 i; s32 width = GetStringWidth(1, gText_Exit, 0); @@ -1150,29 +1144,29 @@ void sub_81211EC(void) // PrintStoryList for (i = 0; i < 4; i++) { s32 curWidth; - u16 gameStatID = gUnknown_0203A12C->gameStatIDs[i]; + u16 gameStatID = sStorytellerPtr->gameStatIDs[i]; if (gameStatID == 0) break; - curWidth = GetStringWidth(1, sub_8120EB4(gameStatID), 0); + curWidth = GetStringWidth(1, GetStoryTitleByStat(gameStatID), 0); if (curWidth > width) width = curWidth; } - gUnknown_0203A130 = CreateWindowFromRect(0, 0, convert_pixel_width_to_tile_width(width), sub_8120ED8() * 2 + 2); - SetStandardWindowBorderStyle(gUnknown_0203A130, 0); + sStorytellerWindowId = CreateWindowFromRect(0, 0, convert_pixel_width_to_tile_width(width), GetFreeStorySlot() * 2 + 2); + SetStandardWindowBorderStyle(sStorytellerWindowId, 0); for (i = 0; i < 4; i++) { - u16 gameStatID = gUnknown_0203A12C->gameStatIDs[i]; + u16 gameStatID = sStorytellerPtr->gameStatIDs[i]; if (gameStatID == 0) break; - PrintTextOnWindow(gUnknown_0203A130, 1, sub_8120EB4(gameStatID), 8, 16 * i + 1, 0xFF, NULL); + PrintTextOnWindow(sStorytellerWindowId, 1, GetStoryTitleByStat(gameStatID), 8, 16 * i + 1, 0xFF, NULL); } - PrintTextOnWindow(gUnknown_0203A130, 1, gText_Exit, 8, 16 * i + 1, 0xFF, NULL); - InitMenuInUpperLeftCornerPlaySoundWhenAPressed(gUnknown_0203A130, sub_8120ED8() + 1, 0); - CopyWindowToVram(gUnknown_0203A130, 3); + PrintTextOnWindow(sStorytellerWindowId, 1, gText_Exit, 8, 16 * i + 1, 0xFF, NULL); + InitMenuInUpperLeftCornerPlaySoundWhenAPressed(sStorytellerWindowId, GetFreeStorySlot() + 1, 0); + CopyWindowToVram(sStorytellerWindowId, 3); } -void sub_81212FC(u8 taskId) // Task_StoryListMenu +static void Task_StoryListMenu(u8 taskId) // Task_StoryListMenu { struct Task *task = &gTasks[taskId]; s32 selection; @@ -1180,23 +1174,23 @@ void sub_81212FC(u8 taskId) // Task_StoryListMenu switch (task->data[0]) { case 0: - sub_81211EC(); + PrintStoryList(); task->data[0]++; break; case 1: selection = ProcessMenuInput(); if (selection == -2) break; - if (selection == -1 || selection == sub_8120ED8()) + if (selection == -1 || selection == GetFreeStorySlot()) { gSpecialVar_Result = 0; } else { gSpecialVar_Result = 1; - gUnknown_03001178 = selection; + sSelectedStory = selection; } - sub_80E2A78(gUnknown_0203A130); + sub_80E2A78(sStorytellerWindowId); DestroyTask(taskId); EnableBothScriptContexts(); break; @@ -1204,51 +1198,50 @@ void sub_81212FC(u8 taskId) // Task_StoryListMenu } // Sets gSpecialVar_Result to TRUE if player selected a story -void sub_8121388(void) // ScrSpecial_StorytellerStoryListMenu +void ScrSpecial_StorytellerStoryListMenu(void) { - CreateTask(sub_81212FC, 80); + CreateTask(Task_StoryListMenu, 80); } -void sub_812139C(void) // ScrSpecial_StorytellerDisplayStory +void ScrSpecial_StorytellerDisplayStory(void) { - sub_8121178(gUnknown_03001178); + StorytellerDisplayStory(sSelectedStory); } -u8 sub_81213B0(void) // ScrSpecial_StorytellerDisplayStory +u8 ScrSpecial_StorytellerGetFreeStorySlot(void) { - gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; - return sub_8120ED8(); + sStorytellerPtr = &gSaveBlock1Ptr->oldMan.storyteller; + return GetFreeStorySlot(); } // Returns TRUE if stat has increased -bool8 sub_81213D8(void) // ScrSpecial_StorytellerUpdateStat +bool8 ScrSpecial_StorytellerUpdateStat(void) { u8 r4; - gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; - r4 = gUnknown_0203A12C->gameStatIDs[gUnknown_03001178]; + sStorytellerPtr = &gSaveBlock1Ptr->oldMan.storyteller; + r4 = sStorytellerPtr->gameStatIDs[sSelectedStory]; - if (sub_8120F4C(gUnknown_03001178) == TRUE) + if (HasTrainerStatIncreased(sSelectedStory) == TRUE) { - sub_8120FDC(gUnknown_03001178, r4); + StorytellerRecordNewStat(sSelectedStory, r4); return TRUE; } return FALSE; } - -bool8 sub_8121424(void) // ScrSpecial_HasStorytellerAlreadyRecorded +bool8 ScrSpecial_HasStorytellerAlreadyRecorded(void) { - gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; + sStorytellerPtr = &gSaveBlock1Ptr->oldMan.storyteller; - if (gUnknown_0203A12C->alreadyRecorded == FALSE) + if (sStorytellerPtr->alreadyRecorded == FALSE) return FALSE; else return TRUE; } -bool8 sub_8121450(void) // ScrSpecial_StorytellerInitializeRandomStat +bool8 ScrSpecial_StorytellerInitializeRandomStat(void) { - gUnknown_0203A12C = &gSaveBlock1Ptr->oldMan.storyteller; - return sub_81210B8(); + sStorytellerPtr = &gSaveBlock1Ptr->oldMan.storyteller; + return StorytellerInitializeRandomStat(); } -- cgit v1.2.3 From d66c1c642c60191887fc4dda6d33bb5b8e9ff69c Mon Sep 17 00:00:00 2001 From: Diegoisawesome Date: Wed, 9 May 2018 05:07:56 -0500 Subject: Port/decompile fieldmap.c --- src/field_camera.c | 6 + src/fieldmap.c | 1034 ++++++++++++++++++++++++++++++++++++++++++++++++++++ src/overworld.c | 5 +- src/secret_base.c | 2 +- 4 files changed, 1043 insertions(+), 4 deletions(-) create mode 100644 src/fieldmap.c (limited to 'src') diff --git a/src/field_camera.c b/src/field_camera.c index f653e0bf1..95167ee10 100644 --- a/src/field_camera.c +++ b/src/field_camera.c @@ -12,6 +12,8 @@ #include "sprite.h" #include "text.h" +EWRAM_DATA bool8 gUnusedBikeCameraAheadPanback = FALSE; + // Static type declarations struct FieldCameraUnknownStruct { @@ -40,6 +42,10 @@ static IWRAM_DATA s16 gUnknown_03000E2A; static IWRAM_DATA u8 gUnknown_03000E2C; static IWRAM_DATA void (*gUnknown_03000E30)(void); +struct CameraObject gUnknown_03005DD0; +u16 gUnknown_03005DE8; +u16 gUnknown_03005DEC; + // text static void move_tilemap_camera_to_upper_left_corner_(struct FieldCameraUnknownStruct *a) { diff --git a/src/fieldmap.c b/src/fieldmap.c new file mode 100644 index 000000000..87e493e95 --- /dev/null +++ b/src/fieldmap.c @@ -0,0 +1,1034 @@ +#include "global.h" +#include "overworld.h" +#include "bg.h" +#include "battle_frontier_2.h" +#include "constants/RGB.h" +#include "fieldmap.h" +#include "fldeff_80F9BCC.h" +#include "fldeff_cut.h" +#include "fldeff_groundshake.h" +#include "menu.h" +#include "palette.h" +#include "pokenav.h" +#include "script.h" +#include "secret_base.h" +#include "tv.h" + +struct ConnectionFlags +{ + u8 south:1; + u8 north:1; + u8 west:1; + u8 east:1; +}; + +EWRAM_DATA static u16 gUnknown_02032318[0x2800] = {0}; +EWRAM_DATA struct MapHeader gMapHeader = {0}; +EWRAM_DATA struct Camera gCamera = {0}; +EWRAM_DATA static struct ConnectionFlags gUnknown_02037340 = {0}; +EWRAM_DATA static u32 sFiller_02037344 = 0; // without this, the next file won't align properly + +struct BackupMapData gUnknown_03005DC0; + +static const struct ConnectionFlags sDummyConnectionFlags = {0}; + +struct MapHeader const *const mapconnection_get_mapheader(struct MapConnection *connection) +{ + return Overworld_GetMapHeaderByGroupAndId(connection->mapGroup, connection->mapNum); +} + +void not_trainer_hill_battle_pyramid(void) +{ + mapheader_copy_mapdata_with_padding(&gMapHeader); + sub_80E8EE0(gMapHeader.events); + mapheader_run_script_with_tag_x1(); +} + +void sub_8087D74(void) +{ + mapheader_copy_mapdata_with_padding(&gMapHeader); + sub_80E9238(0); + sub_80E8EE0(gMapHeader.events); + mapdata_from_sav2(); + mapheader_run_script_with_tag_x1(); + UpdateTVScreensOnMap(gUnknown_03005DC0.width, gUnknown_03005DC0.height); +} + +void battle_pyramid_map_load_related(u8 a0) +{ + CpuFastFill(0x03ff03ff, gUnknown_02032318, sizeof(gUnknown_02032318)); + sub_81AA078(gUnknown_02032318, a0); +} + +void trainer_hill_map_load_related(void) +{ + CpuFastFill(0x03ff03ff, gUnknown_02032318, sizeof(gUnknown_02032318)); + sub_81D5FB4(gUnknown_02032318); +} + +void mapheader_copy_mapdata_with_padding(struct MapHeader *mapHeader) +{ + struct MapData const *mapData; + int width; + int height; + mapData = mapHeader->mapData; + CpuFastFill16(0x03ff, gUnknown_02032318, sizeof(gUnknown_02032318)); + gUnknown_03005DC0.map = gUnknown_02032318; + width = mapData->width + 15; + gUnknown_03005DC0.width = width; + height = mapData->height + 14; + gUnknown_03005DC0.height = height; + if (width * height <= 0x2800) + { + map_copy_with_padding(mapData->map, mapData->width, mapData->height); + mapheader_copy_mapdata_of_adjacent_maps(mapHeader); + } +} + +void map_copy_with_padding(u16 *map, u16 width, u16 height) +{ + u16 *dest; + int y; + dest = gUnknown_03005DC0.map; + dest += gUnknown_03005DC0.width * 7 + 7; + for (y = 0; y < height; y++) + { + CpuCopy16(map, dest, width * 2); + dest += width + 0xf; + map += width; + } +} + +void mapheader_copy_mapdata_of_adjacent_maps(struct MapHeader *mapHeader) +{ + int count; + struct MapConnection *connection; + int i; + + if (mapHeader->connections) + { + count = mapHeader->connections->count; + connection = mapHeader->connections->connections; + + gUnknown_02037340 = sDummyConnectionFlags; + for (i = 0; i < count; i++, connection++) + { + struct MapHeader const *cMap = mapconnection_get_mapheader(connection); + u32 offset = connection->offset; + + switch (connection->direction) + { + case CONNECTION_SOUTH: + fillSouthConnection(mapHeader, cMap, offset); + gUnknown_02037340.south = 1; + break; + case CONNECTION_NORTH: + fillNorthConnection(mapHeader, cMap, offset); + gUnknown_02037340.north = 1; + break; + case CONNECTION_WEST: + fillWestConnection(mapHeader, cMap, offset); + gUnknown_02037340.west = 1; + break; + case CONNECTION_EAST: + fillEastConnection(mapHeader, cMap, offset); + gUnknown_02037340.east = 1; + break; + } + } + } +} + +void sub_8087F54(int x, int y, struct MapHeader const *mapHeader, int x2, int y2, int width, int height) +{ + int i; + u16 *src; + u16 *dest; + int mapWidth; + + mapWidth = mapHeader->mapData->width; + src = &mapHeader->mapData->map[mapWidth * y2 + x2]; + dest = &gUnknown_03005DC0.map[gUnknown_03005DC0.width * y + x]; + + for (i = 0; i < height; i++) + { + CpuCopy16(src, dest, width * 2); + dest += gUnknown_03005DC0.width; + src += mapWidth; + } +} + +void fillSouthConnection(struct MapHeader const *mapHeader, struct MapHeader const *connectedMapHeader, s32 offset) +{ + int x, y; + int x2; + int width; + int cWidth; + + if (connectedMapHeader) + { + cWidth = connectedMapHeader->mapData->width; + x = offset + 7; + y = mapHeader->mapData->height + 7; + if (x < 0) + { + x2 = -x; + x += cWidth; + if (x < gUnknown_03005DC0.width) + { + width = x; + } + else + { + width = gUnknown_03005DC0.width; + } + x = 0; + } + else + { + x2 = 0; + if (x + cWidth < gUnknown_03005DC0.width) + { + width = cWidth; + } + else + { + width = gUnknown_03005DC0.width - x; + } + } + + sub_8087F54( + x, y, + connectedMapHeader, + x2, /*y2*/ 0, + width, /*height*/ 7); + } +} + +void fillNorthConnection(struct MapHeader const *mapHeader, struct MapHeader const *connectedMapHeader, s32 offset) +{ + int x; + int x2, y2; + int width; + int cWidth, cHeight; + + if (connectedMapHeader) + { + cWidth = connectedMapHeader->mapData->width; + cHeight = connectedMapHeader->mapData->height; + x = offset + 7; + y2 = cHeight - 7; + if (x < 0) + { + x2 = -x; + x += cWidth; + if (x < gUnknown_03005DC0.width) + { + width = x; + } + else + { + width = gUnknown_03005DC0.width; + } + x = 0; + } + else + { + x2 = 0; + if (x + cWidth < gUnknown_03005DC0.width) + { + width = cWidth; + } + else + { + width = gUnknown_03005DC0.width - x; + } + } + + sub_8087F54( + x, /*y*/ 0, + connectedMapHeader, + x2, y2, + width, /*height*/ 7); + + } +} + +void fillWestConnection(struct MapHeader const *mapHeader, struct MapHeader const *connectedMapHeader, s32 offset) +{ + int y; + int x2, y2; + int height; + int cWidth, cHeight; + if (connectedMapHeader) + { + cWidth = connectedMapHeader->mapData->width; + cHeight = connectedMapHeader->mapData->height; + y = offset + 7; + x2 = cWidth - 7; + if (y < 0) + { + y2 = -y; + if (y + cHeight < gUnknown_03005DC0.height) + { + height = y + cHeight; + } + else + { + height = gUnknown_03005DC0.height; + } + y = 0; + } + else + { + y2 = 0; + if (y + cHeight < gUnknown_03005DC0.height) + { + height = cHeight; + } + else + { + height = gUnknown_03005DC0.height - y; + } + } + + sub_8087F54( + /*x*/ 0, y, + connectedMapHeader, + x2, y2, + /*width*/ 7, height); + } +} + +void fillEastConnection(struct MapHeader const *mapHeader, struct MapHeader const *connectedMapHeader, s32 offset) +{ + int x, y; + int y2; + int height; + int cHeight; + if (connectedMapHeader) + { + cHeight = connectedMapHeader->mapData->height; + x = mapHeader->mapData->width + 7; + y = offset + 7; + if (y < 0) + { + y2 = -y; + if (y + cHeight < gUnknown_03005DC0.height) + { + height = y + cHeight; + } + else + { + height = gUnknown_03005DC0.height; + } + y = 0; + } + else + { + y2 = 0; + if (y + cHeight < gUnknown_03005DC0.height) + { + height = cHeight; + } + else + { + height = gUnknown_03005DC0.height - y; + } + } + + sub_8087F54( + x, y, + connectedMapHeader, + /*x2*/ 0, y2, + /*width*/ 8, height); + } +} + +union Block +{ + struct + { + u16 block:10; + u16 collision:2; + u16 elevation:4; + } block; + u16 value; +}; + +u8 MapGridGetZCoordAt(int x, int y) +{ + u16 block; + int i; + u16 *border; + + if (x >= 0 && x < gUnknown_03005DC0.width + && y >= 0 && y < gUnknown_03005DC0.height) + { + block = gUnknown_03005DC0.map[x + gUnknown_03005DC0.width * y]; + } + else + { + border = gMapHeader.mapData->border; + i = (x + 1) & 1; + i += ((y + 1) & 1) * 2; + block = gMapHeader.mapData->border[i]; + block |= 0xc00; + } + + if (block == 0x3ff) + { + return 0; + } + + return block >> 12; +} + +u8 MapGridIsImpassableAt(int x, int y) +{ + u16 block; + int i; + u16 *border; + + if (x >= 0 && x < gUnknown_03005DC0.width + && y >= 0 && y < gUnknown_03005DC0.height) + { + block = gUnknown_03005DC0.map[x + gUnknown_03005DC0.width * y]; + } + else + { + border = gMapHeader.mapData->border; + i = (x + 1) & 1; + i += ((y + 1) & 1) * 2; + block = gMapHeader.mapData->border[i]; + block |= 0xc00; + } + if (block == 0x3ff) + { + return 1; + } + return (block & 0xc00) >> 10; +} + +u32 MapGridGetMetatileIdAt(int x, int y) +{ + u16 block; + int i; + int j; + struct MapData const *mapData; + u16 *border; + u16 block2; + + if (x >= 0 && x < gUnknown_03005DC0.width + && y >= 0 && y < gUnknown_03005DC0.height) + { + block = gUnknown_03005DC0.map[x + gUnknown_03005DC0.width * y]; + } + else + { + mapData = gMapHeader.mapData; + i = (x + 1) & 1; + i += ((y + 1) & 1) * 2; + block = mapData->border[i] | 0xc00; + } + if (block == 0x3ff) + { + border = gMapHeader.mapData->border; + j = (x + 1) & 1; + j += ((y + 1) & 1) * 2; + block2 = gMapHeader.mapData->border[j]; + block2 |= 0xc00; + return block2 & block; + } + return block & 0x3ff; +} + +u32 MapGridGetMetatileBehaviorAt(int x, int y) +{ + u16 metatile; + metatile = MapGridGetMetatileIdAt(x, y); + return GetBehaviorByMetatileId(metatile) & 0xff; +} + +u8 MapGridGetMetatileLayerTypeAt(int x, int y) +{ + u16 metatile; + metatile = MapGridGetMetatileIdAt(x, y); + return (GetBehaviorByMetatileId(metatile) & 0xf000) >> 12; +} + +void MapGridSetMetatileIdAt(int x, int y, u16 metatile) +{ + int i; + if (x >= 0 && x < gUnknown_03005DC0.width + && y >= 0 && y < gUnknown_03005DC0.height) + { + i = x + y * gUnknown_03005DC0.width; + gUnknown_03005DC0.map[i] = (gUnknown_03005DC0.map[i] & 0xf000) | (metatile & 0xfff); + } +} + +void MapGridSetMetatileEntryAt(int x, int y, u16 metatile) +{ + int i; + if (x >= 0 && x < gUnknown_03005DC0.width + && y >= 0 && y < gUnknown_03005DC0.height) + { + i = x + gUnknown_03005DC0.width * y; + gUnknown_03005DC0.map[i] = metatile; + } +} + +u16 GetBehaviorByMetatileId(u16 metatile) +{ + u16 *attributes; + if (metatile <= 0x1ff) + { + attributes = gMapHeader.mapData->primaryTileset->metatileAttributes; + return attributes[metatile]; + } + else if (metatile <= 0x3ff) + { + attributes = gMapHeader.mapData->secondaryTileset->metatileAttributes; + return attributes[metatile - 0x200]; + } + else + { + return 0xff; + } +} + +void save_serialize_map(void) +{ + int i, j; + int x, y; + u16 *mapView; + int width; + mapView = gSaveBlock1Ptr->mapView; + width = gUnknown_03005DC0.width; + x = gSaveBlock1Ptr->pos.x; + y = gSaveBlock1Ptr->pos.y; + for (i = y; i < y + 14; i++) + { + for (j = x; j < x + 15; j++) + { + *mapView++ = gUnknown_02032318[width * i + j]; + } + } +} + +int sub_8088438(void) +{ + u16 i; + u32 r2; + r2 = 0; + for (i = 0; i < 0x200; i++) + { + r2 |= gSaveBlock1Ptr->mapView[i]; + } + if (r2 == 0) + { + return 1; + } + return 0; +} + +void sav2_mapdata_clear(void) +{ + CpuFill16(0, gSaveBlock1Ptr->mapView, sizeof(gSaveBlock1Ptr->mapView)); +} + +void mapdata_from_sav2(void) +{ + u8 a0; + int i, j; + int x, y; + u16 *mapView; + int width; + mapView = gSaveBlock1Ptr->mapView; + if (!sub_8088438()) + { + width = gUnknown_03005DC0.width; + x = gSaveBlock1Ptr->pos.x; + y = gSaveBlock1Ptr->pos.y; + for (i = y; i < y + 14; i++) + { + if (i == y && i != 0) + a0 = 0; + else if (i == y + 13 && i != gMapHeader.mapData->height - 1) + a0 = 1; + else + a0 = -1; + + for (j = x; j < x + 15; j++) + { + if (!sub_8088BF0(&gUnknown_02032318[j + width * i], width, a0)) + gUnknown_02032318[j + width * i] = *mapView; + mapView++; + } + } + for (j = x; j < x + 15; j++) + { + if (y != 0) + sub_80D423C(j, y - 1); + if (i < gMapHeader.mapData->height - 1) + sub_80D42B8(j, y + 13); + } + sav2_mapdata_clear(); + } +} + +void sub_80885C4(u8 a1) +{ + int width; + u16 *mapView; + int x0, y0; + int x2, y2; + u16 *src, *dest; + int srci, desti; + int r9, r8; + int x, y; + int i, j; + mapView = gSaveBlock1Ptr->mapView; + width = gUnknown_03005DC0.width; + r9 = 0; + r8 = 0; + x0 = gSaveBlock1Ptr->pos.x; + y0 = gSaveBlock1Ptr->pos.y; + x2 = 15; + y2 = 14; + switch (a1) + { + case CONNECTION_NORTH: + y0 += 1; + y2 = 13; + break; + case CONNECTION_SOUTH: + r8 = 1; + y2 = 13; + break; + case CONNECTION_WEST: + x0 += 1; + x2 = 14; + break; + case CONNECTION_EAST: + r9 = 1; + x2 = 14; + break; + } + for (y = 0; y < y2; y++) + { + i = 0; + j = 0; + for (x = 0; x < x2; x++) + { + desti = width * (y + y0); + srci = (y + r8) * 15 + r9; + src = &mapView[srci + i]; + dest = &gUnknown_02032318[x0 + desti + j]; + *dest = *src; + i++; + j++; + } + } + sav2_mapdata_clear(); +} + +int GetMapBorderIdAt(int x, int y) +{ + struct MapData const *mapData; + u16 block, block2; + int i, j; + if (x >= 0 && x < gUnknown_03005DC0.width + && y >= 0 && y < gUnknown_03005DC0.height) + { + i = gUnknown_03005DC0.width; + i *= y; + block = gUnknown_03005DC0.map[x + i]; + if (block == 0x3ff) + { + goto fail; + } + } + else + { + mapData = gMapHeader.mapData; + j = (x + 1) & 1; + j += ((y + 1) & 1) * 2; + block2 = 0xc00 | mapData->border[j]; + if (block2 == 0x3ff) + { + goto fail; + } + } + goto success; +fail: + return -1; +success: + + if (x >= (gUnknown_03005DC0.width - 8)) + { + if (!gUnknown_02037340.east) + { + return -1; + } + return CONNECTION_EAST; + } + else if (x < 7) + { + if (!gUnknown_02037340.west) + { + return -1; + } + return CONNECTION_WEST; + } + else if (y >= (gUnknown_03005DC0.height - 7)) + { + if (!gUnknown_02037340.south) + { + return -1; + } + return CONNECTION_SOUTH; + } + else if (y < 7) + { + if (!gUnknown_02037340.north) + { + return -1; + } + return CONNECTION_NORTH; + } + else + { + return 0; + } +} + +int GetPostCameraMoveMapBorderId(int x, int y) +{ + return GetMapBorderIdAt(gSaveBlock1Ptr->pos.x + 7 + x, gSaveBlock1Ptr->pos.y + 7 + y); +} + +int CanCameraMoveInDirection(int direction) +{ + int x, y; + x = gSaveBlock1Ptr->pos.x + 7 + gUnknown_08339D64[direction].x; + y = gSaveBlock1Ptr->pos.y + 7 + gUnknown_08339D64[direction].y; + if (GetMapBorderIdAt(x, y) == -1) + { + return 0; + } + return 1; +} + +void sub_80887F8(struct MapConnection *connection, int direction, int x, int y) +{ + struct MapHeader const *mapHeader; + mapHeader = mapconnection_get_mapheader(connection); + switch (direction) + { + case CONNECTION_EAST: + gSaveBlock1Ptr->pos.x = -x; + gSaveBlock1Ptr->pos.y -= connection->offset; + break; + case CONNECTION_WEST: + gSaveBlock1Ptr->pos.x = mapHeader->mapData->width; + gSaveBlock1Ptr->pos.y -= connection->offset; + break; + case CONNECTION_SOUTH: + gSaveBlock1Ptr->pos.x -= connection->offset; + gSaveBlock1Ptr->pos.y = -y; + break; + case CONNECTION_NORTH: + gSaveBlock1Ptr->pos.x -= connection->offset; + gSaveBlock1Ptr->pos.y = mapHeader->mapData->height; + break; + } +} + +bool8 CameraMove(int x, int y) +{ + unsigned int direction; + struct MapConnection *connection; + int old_x, old_y; + gCamera.active = FALSE; + direction = GetPostCameraMoveMapBorderId(x, y); + if (direction + 1 <= 1) + { + gSaveBlock1Ptr->pos.x += x; + gSaveBlock1Ptr->pos.y += y; + } + else + { + save_serialize_map(); + sub_81BE72C(); + old_x = gSaveBlock1Ptr->pos.x; + old_y = gSaveBlock1Ptr->pos.y; + connection = sub_8088950(direction, gSaveBlock1Ptr->pos.x, gSaveBlock1Ptr->pos.y); + sub_80887F8(connection, direction, x, y); + mliX_load_map(connection->mapGroup, connection->mapNum); + gCamera.active = TRUE; + gCamera.x = old_x - gSaveBlock1Ptr->pos.x; + gCamera.y = old_y - gSaveBlock1Ptr->pos.y; + gSaveBlock1Ptr->pos.x += x; + gSaveBlock1Ptr->pos.y += y; + sub_80885C4(direction); + } + return gCamera.active; +} + +struct MapConnection *sub_8088950(u8 direction, int x, int y) +{ + int count; + struct MapConnection *connection; + int i; + count = gMapHeader.connections->count; + connection = gMapHeader.connections->connections; + for (i = 0; i < count; i++, connection++) + { + if (connection->direction == direction && sub_80889A8(direction, x, y, connection) == TRUE) + return connection; + } + return NULL; +} + +bool8 sub_80889A8(u8 direction, int x, int y, struct MapConnection *connection) +{ + struct MapHeader const *mapHeader; + mapHeader = mapconnection_get_mapheader(connection); + switch (direction) + { + case CONNECTION_SOUTH: + case CONNECTION_NORTH: + return sub_8088A0C(x, gMapHeader.mapData->width, mapHeader->mapData->width, connection->offset); + case CONNECTION_WEST: + case CONNECTION_EAST: + return sub_8088A0C(y, gMapHeader.mapData->height, mapHeader->mapData->height, connection->offset); + } + return FALSE; +} + +bool8 sub_8088A0C(int x, int src_width, int dest_width, int offset) +{ + int offset2; + offset2 = offset; + + if (offset2 < 0) + offset2 = 0; + + if (dest_width + offset < src_width) + src_width = dest_width + offset; + + if (offset2 <= x && x <= src_width) + return TRUE; + + return FALSE; +} + +int sub_8088A38(int x, int width) +{ + if (x >= 0 && x < width) + return TRUE; + + return FALSE; +} + +int sub_8088A4C(struct MapConnection *connection, int x, int y) +{ + struct MapHeader const *mapHeader; + mapHeader = mapconnection_get_mapheader(connection); + switch (connection->direction) + { + case CONNECTION_SOUTH: + case CONNECTION_NORTH: + return sub_8088A38(x - connection->offset, mapHeader->mapData->width); + case CONNECTION_WEST: + case CONNECTION_EAST: + return sub_8088A38(y - connection->offset, mapHeader->mapData->height); + } + return FALSE; +} + +struct MapConnection *sub_8088A8C(s16 x, s16 y) +{ + int count; + struct MapConnection *connection; + int i; + u8 direction; + if (!gMapHeader.connections) + { + return NULL; + } + else + { + count = gMapHeader.connections->count; + connection = gMapHeader.connections->connections; + for (i = 0; i < count; i++, connection++) + { + direction = connection->direction; + if ((direction == CONNECTION_DIVE || direction == CONNECTION_EMERGE) + || (direction == CONNECTION_NORTH && y > 6) + || (direction == CONNECTION_SOUTH && y < gMapHeader.mapData->height + 7) + || (direction == CONNECTION_WEST && x > 6) + || (direction == CONNECTION_EAST && x < gMapHeader.mapData->width + 7)) + { + continue; + } + if (sub_8088A4C(connection, x - 7, y - 7) == TRUE) + { + return connection; + } + } + } + return NULL; +} + +void sub_8088B3C(u16 x, u16 y) +{ + gSaveBlock1Ptr->pos.x = x - 7; + gSaveBlock1Ptr->pos.y = y - 7; +} + +void sav1_camera_get_focus_coords(u16 *x, u16 *y) +{ + *x = gSaveBlock1Ptr->pos.x + 7; + *y = gSaveBlock1Ptr->pos.y + 7; +} + +void SetCameraCoords(u16 x, u16 y) +{ + gSaveBlock1Ptr->pos.x = x; + gSaveBlock1Ptr->pos.y = y; +} + +void GetCameraCoords(u16 *x, u16 *y) +{ + *x = gSaveBlock1Ptr->pos.x; + *y = gSaveBlock1Ptr->pos.y; +} + +void sub_8088B94(int x, int y, int a2) +{ + if (x >= 0 && x < gUnknown_03005DC0.width && y >= 0 && y < gUnknown_03005DC0.height) + { + if (a2 != 0) + gUnknown_03005DC0.map[x + gUnknown_03005DC0.width * y] |= 0xC00; + else + gUnknown_03005DC0.map[x + gUnknown_03005DC0.width * y] &= 0xF3FF; + } +} + +bool8 sub_8088BF0(u16* a0, u16 a1, u8 a2) +{ + if (a2 == 0xFF) + return FALSE; + + if (a2 == 0) + a0 -= a1; + else + a0 += a1; + + if (sub_80FADE4(*a0 & 0x3FF, a2) == 1) + return TRUE; + return FALSE; +} + +void copy_tileset_patterns_to_vram(struct Tileset const *tileset, u16 numTiles, u16 offset) +{ + if (tileset) + { + if (!tileset->isCompressed) + LoadBgTiles(2, tileset->tiles, numTiles * 32, offset); + else + decompress_and_copy_tile_data_to_vram(2, tileset->tiles, numTiles * 32, offset, 0); + } +} + +void copy_tileset_patterns_to_vram2(struct Tileset const *tileset, u16 numTiles, u16 offset) +{ + if (tileset) + { + if (!tileset->isCompressed) + LoadBgTiles(2, tileset->tiles, numTiles * 32, offset); + else + copy_decompressed_tile_data_to_vram_autofree(2, tileset->tiles, numTiles * 32, offset, 0); + } +} + +void nullsub_3(u16 a0, u16 a1) +{ + +} + +void nullsub_90(void) +{ + +} + +void apply_map_tileset_palette(struct Tileset const *tileset, u16 destOffset, u16 size) +{ + u16 black = RGB_BLACK; + + if (tileset) + { + if (tileset->isSecondary == FALSE) + { + LoadPalette(&black, destOffset, 2); + LoadPalette(((u16*)tileset->palettes) + 1, destOffset + 1, size - 2); + nullsub_3(destOffset + 1, (size - 2) >> 1); + } + else if (tileset->isSecondary == TRUE) + { + LoadPalette(((u16*)tileset->palettes) + 0x60, destOffset, size); + nullsub_3(destOffset, size >> 1); + } + else + { + LoadCompressedPalette((u16*)tileset->palettes, destOffset, size); + nullsub_3(destOffset, size >> 1); + } + } +} + +void copy_map_tileset1_to_vram(struct MapData const *mapData) +{ + copy_tileset_patterns_to_vram(mapData->primaryTileset, 0x200, 0); +} + +void copy_map_tileset2_to_vram(struct MapData const *mapData) +{ + copy_tileset_patterns_to_vram(mapData->secondaryTileset, 0x200, 0x200); +} + +void copy_map_tileset2_to_vram_2(struct MapData const *mapData) +{ + copy_tileset_patterns_to_vram2(mapData->secondaryTileset, 0x200, 0x200); +} + +void apply_map_tileset1_palette(struct MapData const *mapData) +{ + apply_map_tileset_palette(mapData->primaryTileset, 0, 0xC0); +} + +void apply_map_tileset2_palette(struct MapData const *mapData) +{ + apply_map_tileset_palette(mapData->secondaryTileset, 0x60, 0xE0); +} + +void copy_map_tileset1_tileset2_to_vram(struct MapData const *mapData) +{ + if (mapData) + { + copy_tileset_patterns_to_vram2(mapData->primaryTileset, 0x200, 0); + copy_tileset_patterns_to_vram2(mapData->secondaryTileset, 0x200, 0x200); + } +} + +void apply_map_tileset1_tileset2_palette(struct MapData const *mapData) +{ + if (mapData) + { + apply_map_tileset1_palette(mapData); + apply_map_tileset2_palette(mapData); + } +} diff --git a/src/overworld.c b/src/overworld.c index 532615f27..f42f0db7f 100644 --- a/src/overworld.c +++ b/src/overworld.c @@ -137,7 +137,6 @@ extern void trainer_hill_map_load_related(void); extern void sub_8087D74(void); extern void battle_pyramid_map_load_related(u8); extern void sub_80B00E8(u8); -extern void UpdateTVScreensOnMap(u32, u32); extern void sub_80E9238(u8); extern void sub_81A3908(void); extern void sub_81AA2F8(void); @@ -614,12 +613,12 @@ bool32 warp_data_is_not_neg_1(struct WarpData *warp) return TRUE; } -const struct MapHeader *Overworld_GetMapHeaderByGroupAndId(u16 mapGroup, u16 mapNum) +struct MapHeader const *const Overworld_GetMapHeaderByGroupAndId(u16 mapGroup, u16 mapNum) { return gMapGroups[mapGroup][mapNum]; } -const struct MapHeader *warp1_get_mapheader(void) +struct MapHeader const *const warp1_get_mapheader(void) { return Overworld_GetMapHeaderByGroupAndId(sWarpDestination.mapGroup, sWarpDestination.mapNum); } diff --git a/src/secret_base.c b/src/secret_base.c index c886912f4..cd6143ed0 100644 --- a/src/secret_base.c +++ b/src/secret_base.c @@ -327,7 +327,7 @@ void sub_80E8E18(void) VarSet(VAR_SECRET_BASE_MAP, gMapHeader.regionMapSectionId); } -void sub_80E8EE0(struct MapEvents *events) +void sub_80E8EE0(struct MapEvents const *events) { u16 bgEventIndex; u16 i; -- cgit v1.2.3 From 279276c5397267468489811efc2439a1971b88cd Mon Sep 17 00:00:00 2001 From: Diegoisawesome Date: Wed, 9 May 2018 05:14:24 -0500 Subject: Fix capitalization on filename --- src/fieldmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/fieldmap.c b/src/fieldmap.c index 87e493e95..245c88327 100644 --- a/src/fieldmap.c +++ b/src/fieldmap.c @@ -2,7 +2,7 @@ #include "overworld.h" #include "bg.h" #include "battle_frontier_2.h" -#include "constants/RGB.h" +#include "constants/rgb.h" #include "fieldmap.h" #include "fldeff_80F9BCC.h" #include "fldeff_cut.h" -- cgit v1.2.3