Make use of the Move enum instead of magic numbers for the pokémon moves

This commit is contained in:
Philippe Symons 2025-02-12 12:05:15 +01:00
parent 17232c4651
commit 70b32defc4
2 changed files with 482 additions and 480 deletions

View File

@ -1,5 +1,6 @@
#include "gen1/Gen1DistributionPokemon.h"
#include "common.h"
#include "Moves.h"
static const Gen1TrainerPokemon commonMewDefinition = {
.poke_index = 0x15,
@ -9,7 +10,7 @@ static const Gen1TrainerPokemon commonMewDefinition = {
.type1 = 0x18,
.type2 = 0x18,
.catch_rate_or_held_item = 45, // based on Gen1PokeStats
.index_move1 = 0x1, // pound
.index_move1 = (uint8_t)Move::POUND,
.index_move2 = 0x0,
.index_move3 = 0x0,
.index_move4 = 0x0,
@ -40,9 +41,9 @@ static const Gen1TrainerPokemon surfingPikachu = {
.type1 = 0x17,
.type2 = 0x17,
.catch_rate_or_held_item = 190,
.index_move1 = 84,
.index_move2 = 45,
.index_move3 = 57,
.index_move1 = (uint8_t)Move::THUNDER_SHOCK,
.index_move2 = (uint8_t)Move::GROWL,
.index_move3 = (uint8_t)Move::SURF,
.index_move4 = 0,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(5, GRW_MEDIUM_FAST),
@ -430,10 +431,10 @@ static const Gen1DistributionPokemon g1_jpn_pokemonStampFearow = {
.type1 = 0, // NORMAL
.type2 = 2, // FLYING
.catch_rate_or_held_item = 0xAD,
.index_move1 = 45, // GROWL
.index_move2 = 43, // LEER
.index_move3 = 31, // FURY ATTACK
.index_move4 = 6, // PAY DAY
.index_move1 = (uint8_t)Move::GROWL,
.index_move2 = (uint8_t)Move::LEER,
.index_move3 = (uint8_t)Move::FURY_ATTACK,
.index_move4 = (uint8_t)Move::PAY_DAY,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(25, GRW_MEDIUM_FAST),
.hp_effort_value = 0,
@ -471,10 +472,10 @@ static const Gen1DistributionPokemon g1_jpn_pokemonStampRapidash = {
.type1 = 20, // FIRE
.type2 = 20, // FIRE
.catch_rate_or_held_item = 0x3C,
.index_move1 = 52, // EMBER
.index_move2 = 83, // FIRE SPIN
.index_move3 = 23, // STOMP
.index_move4 = 6, // PAY DAY
.index_move1 = (uint8_t)Move::EMBER,
.index_move2 = (uint8_t)Move::FIRE_SPIN,
.index_move3 = (uint8_t)Move::STOMP,
.index_move4 = (uint8_t)Move::PAY_DAY,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(40, GRW_MEDIUM_FAST),
.hp_effort_value = 0,
@ -512,9 +513,9 @@ static const Gen1DistributionPokemon g1_jpn_summer98PokemonBattleTourPikachu = {
.type1 = 23, // ELECTRIC
.type2 = 23, // ELECTRIC
.catch_rate_or_held_item = 0xAD,
.index_move1 = 84, // THUNDERSHOCK
.index_move2 = 45, // GROWL
.index_move3 = 57, // SURF
.index_move1 = (uint8_t)Move::THUNDER_SHOCK,
.index_move2 = (uint8_t)Move::GROWL,
.index_move3 = (uint8_t)Move::SURF,
.index_move4 = 0,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(5, GRW_MEDIUM_FAST),
@ -553,8 +554,8 @@ static const Gen1DistributionPokemon g1_jpn_universityMagikarp = {
.type1 = 21, // WATER
.type2 = 21, // WATER
.catch_rate_or_held_item = 0xAD,
.index_move1 = 150, // SPLASH
.index_move2 = 82, // DRAGON RAGE
.index_move1 = (uint8_t)Move::SPLASH,
.index_move2 = (uint8_t)Move::DRAGON_RAGE,
.index_move3 = 0,
.index_move4 = 0,
.original_trainer_ID = 0,
@ -618,9 +619,9 @@ static const Gen1DistributionPokemon g1_jpn_nintendo64SurfingPikachu = {
.type1 = 23, // ELECTRIC
.type2 = 23, // ELECTRIC
.catch_rate_or_held_item = 0xAD,
.index_move1 = 84, // THUNDERSHOCK
.index_move2 = 45, // GROWL
.index_move3 = 57, // SURF
.index_move1 = (uint8_t)Move::THUNDER_SHOCK,
.index_move2 = (uint8_t)Move::GROWL,
.index_move3 = (uint8_t)Move::SURF,
.index_move4 = 0,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(5, GRW_MEDIUM_FAST),
@ -659,9 +660,9 @@ static const Gen1DistributionPokemon g1_jpn_flyingPikachu = {
.type1 = 23, // ELECTRIC
.type2 = 23, // ELECTRIC
.catch_rate_or_held_item = 0xAD,
.index_move1 = 84, // THUNDERSHOCK
.index_move2 = 45, // GROWL
.index_move3 = 19, // FLY
.index_move1 = (uint8_t)Move::THUNDER_SHOCK,
.index_move2 = (uint8_t)Move::GROWL,
.index_move3 = (uint8_t)Move::FLY,
.index_move4 = 0,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(5, GRW_MEDIUM_FAST),
@ -700,9 +701,9 @@ static const Gen1DistributionPokemon g1_jpn_surfingPikachu = {
.type1 = 23, // ELECTRIC
.type2 = 23, // ELECTRIC
.catch_rate_or_held_item = 0xAD,
.index_move1 = 84, // THUNDERSHOCK
.index_move2 = 45, // GROWL
.index_move3 = 57, // SURF
.index_move1 = (uint8_t)Move::THUNDER_SHOCK,
.index_move2 = (uint8_t)Move::GROWL,
.index_move3 = (uint8_t)Move::SURF,
.index_move4 = 0,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(5, GRW_MEDIUM_FAST),
@ -741,9 +742,9 @@ static const Gen1DistributionPokemon g1_jpn_pkmn2IdeaContestSurfingPikachu = {
.type1 = 23, // ELECTRIC
.type2 = 23, // ELECTRIC
.catch_rate_or_held_item = 0xAD,
.index_move1 = 84, // THUNDERSHOCK
.index_move2 = 45, // GROWL
.index_move3 = 57, // SURF
.index_move1 = (uint8_t)Move::THUNDER_SHOCK,
.index_move2 = (uint8_t)Move::GROWL,
.index_move3 = (uint8_t)Move::SURF,
.index_move4 = 0,
.original_trainer_ID = 0,
.exp = getExpNeededForLevel(5, GRW_MEDIUM_FAST),

File diff suppressed because it is too large Load Diff