mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 11:44:17 +01:00
Merge remote-tracking branch 'RHH_origin/master' into RHH/upcoming
This commit is contained in:
commit
6342da3b58
@ -274,6 +274,7 @@
|
||||
#define F_SUMMARY_SCREEN_FLIP_SPRITE 0x80
|
||||
|
||||
// Evolution types
|
||||
#define EVO_NONE 0xffff // Not an actual evolution, used to generate offspring that can't evolve into the specified species, like regional forms.
|
||||
#define EVO_FRIENDSHIP 1 // Pokémon levels up with friendship ≥ 220
|
||||
#define EVO_FRIENDSHIP_DAY 2 // Pokémon levels up during the day with friendship ≥ 220
|
||||
#define EVO_FRIENDSHIP_NIGHT 3 // Pokémon levels up at night with friendship ≥ 220
|
||||
@ -297,7 +298,7 @@
|
||||
#define EVO_ITEM_HOLD_DAY 21 // Pokémon levels up, holds specified item at day
|
||||
#define EVO_ITEM_HOLD_NIGHT 22 // Pokémon levels up, holds specified item at night
|
||||
#define EVO_MOVE 23 // Pokémon levels up, knows specified move
|
||||
#define EVO_MOVE_TYPE 24 // Pokémon levels up, knows move with specified type
|
||||
#define EVO_FRIENDSHIP_MOVE_TYPE 24 // Pokémon levels up with friendship ≥ 220, knows move with specified type
|
||||
#define EVO_MAPSEC 25 // Pokémon levels up on specified mapsec
|
||||
#define EVO_ITEM_MALE 26 // specified item is used on a male Pokémon
|
||||
#define EVO_ITEM_FEMALE 27 // specified item is used on a female Pokémon
|
||||
|
@ -16,7 +16,7 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_SPEAROW] = {{EVO_LEVEL, 20, SPECIES_FEAROW}},
|
||||
[SPECIES_EKANS] = {{EVO_LEVEL, 22, SPECIES_ARBOK}},
|
||||
[SPECIES_PIKACHU] = {{EVO_ITEM, ITEM_THUNDER_STONE, SPECIES_RAICHU},
|
||||
{EVO_ITEM, ITEM_THUNDER_STONE, SPECIES_RAICHU_ALOLAN}},
|
||||
{EVO_NONE, 0, SPECIES_RAICHU_ALOLAN}},
|
||||
[SPECIES_SANDSHREW] = {{EVO_LEVEL, 22, SPECIES_SANDSLASH}},
|
||||
[SPECIES_NIDORAN_F] = {{EVO_LEVEL, 16, SPECIES_NIDORINA}},
|
||||
[SPECIES_NIDORINA] = {{EVO_ITEM, ITEM_MOON_STONE, SPECIES_NIDOQUEEN}},
|
||||
@ -37,6 +37,7 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_PSYDUCK] = {{EVO_LEVEL, 33, SPECIES_GOLDUCK}},
|
||||
[SPECIES_MANKEY] = {{EVO_LEVEL, 28, SPECIES_PRIMEAPE}},
|
||||
[SPECIES_GROWLITHE] = {{EVO_ITEM, ITEM_FIRE_STONE, SPECIES_ARCANINE}},
|
||||
[SPECIES_GROWLITHE_HISUIAN] = {{EVO_ITEM, ITEM_FIRE_STONE, SPECIES_ARCANINE_HISUIAN}},
|
||||
[SPECIES_POLIWAG] = {{EVO_LEVEL, 25, SPECIES_POLIWHIRL}},
|
||||
[SPECIES_POLIWHIRL] = {{EVO_ITEM, ITEM_WATER_STONE, SPECIES_POLIWRATH},
|
||||
{EVO_TRADE_ITEM, ITEM_KINGS_ROCK, SPECIES_POLITOED},
|
||||
@ -74,14 +75,16 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_DROWZEE] = {{EVO_LEVEL, 26, SPECIES_HYPNO}},
|
||||
[SPECIES_KRABBY] = {{EVO_LEVEL, 28, SPECIES_KINGLER}},
|
||||
[SPECIES_VOLTORB] = {{EVO_LEVEL, 30, SPECIES_ELECTRODE}},
|
||||
[SPECIES_VOLTORB_HISUIAN] = {{EVO_ITEM, ITEM_LEAF_STONE, SPECIES_ELECTRODE_HISUIAN}},
|
||||
[SPECIES_EXEGGCUTE] = {{EVO_ITEM, ITEM_LEAF_STONE, SPECIES_EXEGGUTOR},
|
||||
{EVO_ITEM, ITEM_LEAF_STONE, SPECIES_EXEGGUTOR_ALOLAN}},
|
||||
{EVO_NONE, 0, SPECIES_EXEGGUTOR_ALOLAN}},
|
||||
[SPECIES_CUBONE] = {{EVO_LEVEL, 28, SPECIES_MAROWAK},
|
||||
{EVO_LEVEL_NIGHT, 28, SPECIES_MAROWAK_ALOLAN}},
|
||||
{EVO_NONE, 0, SPECIES_MAROWAK_ALOLAN}},
|
||||
#if P_GEN_4_POKEMON == TRUE
|
||||
[SPECIES_LICKITUNG] = {{EVO_MOVE, MOVE_ROLLOUT, SPECIES_LICKILICKY}},
|
||||
#endif
|
||||
[SPECIES_KOFFING] = {{EVO_LEVEL, 35, SPECIES_WEEZING}},
|
||||
[SPECIES_KOFFING] = {{EVO_LEVEL, 35, SPECIES_WEEZING},
|
||||
{EVO_NONE, 0, SPECIES_WEEZING_GALARIAN}},
|
||||
[SPECIES_RHYHORN] = {{EVO_LEVEL, 42, SPECIES_RHYDON}},
|
||||
#if P_GEN_4_POKEMON == TRUE
|
||||
[SPECIES_RHYDON] = {{EVO_TRADE_ITEM, ITEM_PROTECTOR, SPECIES_RHYPERIOR},
|
||||
@ -118,7 +121,7 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
{EVO_ITEM, ITEM_ICE_STONE, SPECIES_GLACEON},
|
||||
#endif
|
||||
#if P_GEN_6_POKEMON == TRUE
|
||||
{EVO_MOVE_TYPE, TYPE_FAIRY, SPECIES_SYLVEON}
|
||||
{EVO_FRIENDSHIP_MOVE_TYPE, TYPE_FAIRY, SPECIES_SYLVEON}
|
||||
#endif
|
||||
},
|
||||
[SPECIES_PORYGON] = {{EVO_TRADE_ITEM, ITEM_UPGRADE, SPECIES_PORYGON2},
|
||||
@ -130,7 +133,8 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_CHIKORITA] = {{EVO_LEVEL, 16, SPECIES_BAYLEEF}},
|
||||
[SPECIES_BAYLEEF] = {{EVO_LEVEL, 32, SPECIES_MEGANIUM}},
|
||||
[SPECIES_CYNDAQUIL] = {{EVO_LEVEL, 14, SPECIES_QUILAVA}},
|
||||
[SPECIES_QUILAVA] = {{EVO_LEVEL, 36, SPECIES_TYPHLOSION}},
|
||||
[SPECIES_QUILAVA] = {{EVO_LEVEL, 36, SPECIES_TYPHLOSION},
|
||||
{EVO_NONE, 0, SPECIES_TYPHLOSION_HISUIAN}},
|
||||
[SPECIES_TOTODILE] = {{EVO_LEVEL, 18, SPECIES_CROCONAW}},
|
||||
[SPECIES_CROCONAW] = {{EVO_LEVEL, 30, SPECIES_FERALIGATR}},
|
||||
[SPECIES_SENTRET] = {{EVO_LEVEL, 15, SPECIES_FURRET}},
|
||||
@ -304,7 +308,8 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_STUNKY] = {{EVO_LEVEL, 34, SPECIES_SKUNTANK}},
|
||||
[SPECIES_BRONZOR] = {{EVO_LEVEL, 33, SPECIES_BRONZONG}},
|
||||
[SPECIES_BONSLY] = {{EVO_MOVE, MOVE_MIMIC, SPECIES_SUDOWOODO}},
|
||||
[SPECIES_MIME_JR] = {{EVO_MOVE, MOVE_MIMIC, SPECIES_MR_MIME}},
|
||||
[SPECIES_MIME_JR] = {{EVO_MOVE, MOVE_MIMIC, SPECIES_MR_MIME},
|
||||
{EVO_NONE, 0, SPECIES_MR_MIME_GALARIAN}},
|
||||
[SPECIES_HAPPINY] = {{EVO_ITEM_HOLD_DAY, ITEM_OVAL_STONE, SPECIES_CHANSEY},
|
||||
{EVO_ITEM_DAY, ITEM_OVAL_STONE, SPECIES_CHANSEY}},
|
||||
[SPECIES_GIBLE] = {{EVO_LEVEL, 24, SPECIES_GABITE}},
|
||||
@ -324,7 +329,8 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_TEPIG] = {{EVO_LEVEL, 17, SPECIES_PIGNITE}},
|
||||
[SPECIES_PIGNITE] = {{EVO_LEVEL, 36, SPECIES_EMBOAR}},
|
||||
[SPECIES_OSHAWOTT] = {{EVO_LEVEL, 17, SPECIES_DEWOTT}},
|
||||
[SPECIES_DEWOTT] = {{EVO_LEVEL, 36, SPECIES_SAMUROTT}},
|
||||
[SPECIES_DEWOTT] = {{EVO_LEVEL, 36, SPECIES_SAMUROTT},
|
||||
{EVO_NONE, 0, SPECIES_SAMUROTT_HISUIAN}},
|
||||
[SPECIES_PATRAT] = {{EVO_LEVEL, 20, SPECIES_WATCHOG}},
|
||||
[SPECIES_LILLIPUP] = {{EVO_LEVEL, 16, SPECIES_HERDIER}},
|
||||
[SPECIES_HERDIER] = {{EVO_LEVEL, 32, SPECIES_STOUTLAND}},
|
||||
@ -351,7 +357,8 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_VENIPEDE] = {{EVO_LEVEL, 22, SPECIES_WHIRLIPEDE}},
|
||||
[SPECIES_WHIRLIPEDE] = {{EVO_LEVEL, 30, SPECIES_SCOLIPEDE}},
|
||||
[SPECIES_COTTONEE] = {{EVO_ITEM, ITEM_SUN_STONE, SPECIES_WHIMSICOTT}},
|
||||
[SPECIES_PETILIL] = {{EVO_ITEM, ITEM_SUN_STONE, SPECIES_LILLIGANT}},
|
||||
[SPECIES_PETILIL] = {{EVO_ITEM, ITEM_SUN_STONE, SPECIES_LILLIGANT},
|
||||
{EVO_NONE, 0, SPECIES_LILLIGANT_HISUIAN}},
|
||||
[SPECIES_SANDILE] = {{EVO_LEVEL, 29, SPECIES_KROKOROK}},
|
||||
[SPECIES_KROKOROK] = {{EVO_LEVEL, 40, SPECIES_KROOKODILE}},
|
||||
[SPECIES_DARUMAKA] = {{EVO_LEVEL, 35, SPECIES_DARMANITAN}},
|
||||
@ -362,6 +369,7 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_ARCHEN] = {{EVO_LEVEL, 37, SPECIES_ARCHEOPS}},
|
||||
[SPECIES_TRUBBISH] = {{EVO_LEVEL, 36, SPECIES_GARBODOR}},
|
||||
[SPECIES_ZORUA] = {{EVO_LEVEL, 30, SPECIES_ZOROARK}},
|
||||
[SPECIES_ZORUA_HISUIAN] = {{EVO_LEVEL, 30, SPECIES_ZOROARK_HISUIAN}},
|
||||
[SPECIES_MINCCINO] = {{EVO_ITEM, ITEM_SHINY_STONE, SPECIES_CINCCINO}},
|
||||
[SPECIES_GOTHITA] = {{EVO_LEVEL, 32, SPECIES_GOTHORITA}},
|
||||
[SPECIES_GOTHORITA] = {{EVO_LEVEL, 41, SPECIES_GOTHITELLE}},
|
||||
@ -390,7 +398,8 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_MIENFOO] = {{EVO_LEVEL, 50, SPECIES_MIENSHAO}},
|
||||
[SPECIES_GOLETT] = {{EVO_LEVEL, 43, SPECIES_GOLURK}},
|
||||
[SPECIES_PAWNIARD] = {{EVO_LEVEL, 52, SPECIES_BISHARP}},
|
||||
[SPECIES_RUFFLET] = {{EVO_LEVEL, 54, SPECIES_BRAVIARY}},
|
||||
[SPECIES_RUFFLET] = {{EVO_LEVEL, 54, SPECIES_BRAVIARY},
|
||||
{EVO_NONE, 0, SPECIES_BRAVIARY_HISUIAN}},
|
||||
[SPECIES_VULLABY] = {{EVO_LEVEL, 54, SPECIES_MANDIBUZZ}},
|
||||
[SPECIES_DEINO] = {{EVO_LEVEL, 50, SPECIES_ZWEILOUS}},
|
||||
[SPECIES_ZWEILOUS] = {{EVO_LEVEL, 64, SPECIES_HYDREIGON}},
|
||||
@ -428,18 +437,22 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
[SPECIES_HELIOPTILE] = {{EVO_ITEM, ITEM_SUN_STONE, SPECIES_HELIOLISK}},
|
||||
[SPECIES_TYRUNT] = {{EVO_LEVEL_DAY, 39, SPECIES_TYRANTRUM}},
|
||||
[SPECIES_AMAURA] = {{EVO_LEVEL_NIGHT, 39, SPECIES_AURORUS}},
|
||||
[SPECIES_GOOMY] = {{EVO_LEVEL, 40, SPECIES_SLIGGOO}},
|
||||
[SPECIES_GOOMY] = {{EVO_LEVEL, 40, SPECIES_SLIGGOO},
|
||||
{EVO_NONE, 0, SPECIES_SLIGGOO_HISUIAN}},
|
||||
[SPECIES_SLIGGOO] = {{EVO_LEVEL_RAIN, 50, SPECIES_GOODRA}},
|
||||
[SPECIES_SLIGGOO_HISUIAN] = {{EVO_LEVEL_RAIN, 40, SPECIES_GOODRA_HISUIAN}},
|
||||
[SPECIES_PHANTUMP] = {{EVO_TRADE, 0, SPECIES_TREVENANT},
|
||||
{EVO_ITEM, ITEM_LINKING_CORD, SPECIES_TREVENANT}},
|
||||
[SPECIES_PUMPKABOO] = {{EVO_TRADE, 0, SPECIES_GOURGEIST},
|
||||
{EVO_ITEM, ITEM_LINKING_CORD, SPECIES_GOURGEIST}},
|
||||
[SPECIES_BERGMITE] = {{EVO_LEVEL, 37, SPECIES_AVALUGG}},
|
||||
[SPECIES_BERGMITE] = {{EVO_LEVEL, 37, SPECIES_AVALUGG},
|
||||
{EVO_NONE, 0, SPECIES_AVALUGG_HISUIAN}},
|
||||
[SPECIES_NOIBAT] = {{EVO_LEVEL, 48, SPECIES_NOIVERN}},
|
||||
#endif
|
||||
#if P_GEN_7_POKEMON == TRUE
|
||||
[SPECIES_ROWLET] = {{EVO_LEVEL, 17, SPECIES_DARTRIX}},
|
||||
[SPECIES_DARTRIX] = {{EVO_LEVEL, 34, SPECIES_DECIDUEYE}},
|
||||
[SPECIES_DARTRIX] = {{EVO_LEVEL, 34, SPECIES_DECIDUEYE},
|
||||
{EVO_NONE, 0, SPECIES_DECIDUEYE_HISUIAN}},
|
||||
[SPECIES_LITTEN] = {{EVO_LEVEL, 17, SPECIES_TORRACAT}},
|
||||
[SPECIES_TORRACAT] = {{EVO_LEVEL, 34, SPECIES_INCINEROAR}},
|
||||
[SPECIES_POPPLIO] = {{EVO_LEVEL, 17, SPECIES_BRIONNE}},
|
||||
@ -584,6 +597,7 @@ const struct Evolution gEvolutionTable[NUM_SPECIES][EVOS_PER_MON] =
|
||||
#if P_GEN_8_POKEMON == TRUE
|
||||
[SPECIES_SINISTEA_ANTIQUE] = {{EVO_ITEM, ITEM_CHIPPED_POT, SPECIES_POLTEAGEIST_ANTIQUE}},
|
||||
[SPECIES_URSARING] = {{EVO_ITEM_NIGHT, ITEM_PEAT_BLOCK, SPECIES_URSALUNA}},
|
||||
[SPECIES_QWILFISH_HISUIAN] = {{EVO_MOVE, MOVE_BARB_BARRAGE, SPECIES_OVERQWIL}},
|
||||
[SPECIES_SNEASEL_HISUIAN] = {{EVO_ITEM_DAY, ITEM_RAZOR_CLAW, SPECIES_SNEASLER},
|
||||
{EVO_ITEM_HOLD_DAY, ITEM_RAZOR_CLAW, SPECIES_SNEASLER}},
|
||||
#endif
|
||||
|
@ -2075,7 +2075,7 @@ static void Task_ItemContext_Sell(u8 taskId)
|
||||
{
|
||||
s16 *data = gTasks[taskId].data;
|
||||
|
||||
if (ItemId_GetPrice(gSpecialVar_ItemId) == 0)
|
||||
if (ItemId_GetPrice(gSpecialVar_ItemId) == 0 || ItemId_GetImportance(gSpecialVar_ItemId))
|
||||
{
|
||||
CopyItemName(gSpecialVar_ItemId, gStringVar2);
|
||||
StringExpandPlaceholders(gStringVar4, gText_CantBuyKeyItem);
|
||||
|
@ -6501,8 +6501,10 @@ u16 GetEvolutionTargetSpecies(struct Pokemon *mon, u8 mode, u16 evolutionItem, s
|
||||
if (MonKnowsMove(mon, gEvolutionTable[species][i].param))
|
||||
targetSpecies = gEvolutionTable[species][i].targetSpecies;
|
||||
break;
|
||||
case EVO_MOVE_TYPE:
|
||||
for (j = 0; j < 4; j++)
|
||||
case EVO_FRIENDSHIP_MOVE_TYPE:
|
||||
if (friendship >= 220)
|
||||
{
|
||||
for (j = 0; j < MAX_MON_MOVES; j++)
|
||||
{
|
||||
if (gBattleMoves[GetMonData(mon, MON_DATA_MOVE1 + j, NULL)].type == gEvolutionTable[species][i].param)
|
||||
{
|
||||
@ -6510,6 +6512,7 @@ u16 GetEvolutionTargetSpecies(struct Pokemon *mon, u8 mode, u16 evolutionItem, s
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case EVO_SPECIFIC_MON_IN_PARTY:
|
||||
for (j = 0; j < PARTY_SIZE; j++)
|
||||
|
@ -844,10 +844,15 @@ void TestRunner_Battle_AfterLastTurn(void)
|
||||
static void CB2_BattleTest_NextParameter(void)
|
||||
{
|
||||
if (++STATE->runParameter >= STATE->parameters)
|
||||
{
|
||||
SetMainCallback2(CB2_TestRunner);
|
||||
}
|
||||
else
|
||||
{
|
||||
STATE->trials = 0;
|
||||
BattleTest_Run(gTestRunnerState.test->data);
|
||||
}
|
||||
}
|
||||
|
||||
static void CB2_BattleTest_NextTrial(void)
|
||||
{
|
||||
@ -942,6 +947,7 @@ static bool32 BattleTest_HandleExitWithResult(void *data, enum TestResult result
|
||||
void Randomly(u32 sourceLine, u32 passes, u32 trials, struct RandomlyContext ctx)
|
||||
{
|
||||
const struct BattleTest *test = gTestRunnerState.test->data;
|
||||
INVALID_IF(STATE->trials != 0, "PASSES_RANDOMLY can only be used once per test");
|
||||
INVALID_IF(test->resultsSize > 0, "PASSES_RANDOMLY is incompatible with results");
|
||||
INVALID_IF(passes > trials, "%d passes specified, but only %d trials", passes, trials);
|
||||
STATE->rngTag = ctx.tag;
|
||||
|
Loading…
Reference in New Issue
Block a user