Skip to content

Commit

Permalink
Temporarely revert regional form inheritance (rh-hideout#5004)
Browse files Browse the repository at this point in the history
  • Loading branch information
AsparagusEduardo committed Jul 20, 2024
1 parent 9d5e253 commit 01831a3
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions src/daycare.c
Original file line number Diff line number Diff line change
Expand Up @@ -1038,8 +1038,7 @@ static u16 DetermineEggSpeciesAndParentSlots(struct DayCare *daycare, u8 *parent
{
u16 i;
u16 species[DAYCARE_MON_COUNT];
u16 eggSpecies, parentSpecies;
bool8 hasMotherEverstone, hasFatherEverstone;
u16 eggSpecies;

for (i = 0; i < DAYCARE_MON_COUNT; i++)
{
Expand All @@ -1056,18 +1055,7 @@ static u16 DetermineEggSpeciesAndParentSlots(struct DayCare *daycare, u8 *parent
}
}

hasMotherEverstone = ItemId_GetHoldEffect(GetBoxMonData(&daycare->mons[0].mon, MON_DATA_HELD_ITEM)) == HOLD_EFFECT_PREVENT_EVOLVE;
hasFatherEverstone = ItemId_GetHoldEffect(GetBoxMonData(&daycare->mons[1].mon, MON_DATA_HELD_ITEM)) == HOLD_EFFECT_PREVENT_EVOLVE;

if (hasMotherEverstone)
parentSpecies = species[parentSlots[0]];
else if (hasFatherEverstone && GET_BASE_SPECIES_ID(GetEggSpecies(species[parentSlots[0]])) == GET_BASE_SPECIES_ID(GetEggSpecies(species[parentSlots[1]])))
parentSpecies = species[parentSlots[1]];
else
parentSpecies = GET_BASE_SPECIES_ID(GetEggSpecies(species[parentSlots[0]]));

eggSpecies = GetEggSpecies(parentSpecies);

eggSpecies = GetEggSpecies(species[parentSlots[0]]);
if (eggSpecies == SPECIES_NIDORAN_F && daycare->offspringPersonality & EGG_GENDER_MALE)
eggSpecies = SPECIES_NIDORAN_M;
else if (eggSpecies == SPECIES_ILLUMISE && daycare->offspringPersonality & EGG_GENDER_MALE)
Expand Down

0 comments on commit 01831a3

Please sign in to comment.