Merge branch 'master' into followers

This commit is contained in:
Ariel A
2023-12-31 01:25:51 -05:00
218 changed files with 2173 additions and 2117 deletions

View File

@@ -54,6 +54,9 @@
#define BATTLE_BUFFER_LINK_SIZE 0x1000
// Special indicator value for shellBellDmg in SpecialStatus
#define IGNORE_SHELL_BELL 0xFFFF
struct ResourceFlags
{
u32 flags[MAX_BATTLERS_COUNT];
@@ -133,7 +136,7 @@ struct SpecialStatus
u32 ppNotAffectedByPressure:1;
u32 faintedHasReplacement:1;
u32 focusBanded:1;
s32 dmg;
s32 shellBellDmg;
s32 physicalDmg;
s32 specialDmg;
u8 physicalBattlerId;
@@ -417,7 +420,7 @@ struct BattleStruct
u8 arenaTurnCounter;
u8 turnSideTracker;
u8 unused_6[3];
u8 givenExpMons; // Bits for enemy party's pokemon that gave exp to player's party.
u8 givenExpMons; // Bits for enemy party's Pokémon that gave exp to player's party.
u8 lastTakenMoveFrom[MAX_BATTLERS_COUNT * MAX_BATTLERS_COUNT * 2]; // a 3-D array [target][attacker][byte]
u16 castformPalette[NUM_CASTFORM_FORMS][16];
union {
@@ -437,7 +440,7 @@ struct BattleStruct
u16 arenaStartHp[2];
u8 arenaLostPlayerMons; // Bits for party member, lost as in referee's decision, not by fainting.
u8 arenaLostOpponentMons;
u8 alreadyStatusedMoveAttempt; // As bits for battlers; For example when using Thunder Wave on an already paralyzed pokemon.
u8 alreadyStatusedMoveAttempt; // As bits for battlers; For example when using Thunder Wave on an already paralyzed Pokémon.
};
// The palaceFlags member of struct BattleStruct contains 1 flag per move to indicate which moves the AI should consider,
@@ -445,9 +448,9 @@ struct BattleStruct
// The assert below is to ensure palaceFlags is large enough to store these flags without overlap.
STATIC_ASSERT(sizeof(((struct BattleStruct *)0)->palaceFlags) * 8 >= MAX_BATTLERS_COUNT + MAX_MON_MOVES, PalaceFlagsTooSmall)
#define F_DYNAMIC_TYPE_1 (1 << 6)
#define F_DYNAMIC_TYPE_2 (1 << 7)
#define DYNAMIC_TYPE_MASK (F_DYNAMIC_TYPE_1 - 1)
#define DYNAMIC_TYPE_MASK ((1 << 6) - 1)
#define F_DYNAMIC_TYPE_IGNORE_PHYSICALITY (1 << 6) // If set, the dynamic type's physicality won't be used for certain move effects.
#define F_DYNAMIC_TYPE_SET (1 << 7) // Set for all dynamic types to distinguish a dynamic type of Normal (0) from no dynamic type.
#define GET_MOVE_TYPE(move, typeArg) \
{ \
@@ -592,7 +595,7 @@ struct BattleSpriteData
struct MonSpritesGfx
{
void *firstDecompressed; // ptr to the decompressed sprite of the first pokemon
void *firstDecompressed; // ptr to the decompressed sprite of the first Pokémon
union {
void *ptr[MAX_BATTLERS_COUNT];
u8 *byte[MAX_BATTLERS_COUNT];
@@ -647,7 +650,7 @@ extern u16 gChosenMove;
extern u16 gCalledMove;
extern s32 gBattleMoveDamage;
extern s32 gHpDealt;
extern s32 gTakenDmg[MAX_BATTLERS_COUNT];
extern s32 gBideDmg[MAX_BATTLERS_COUNT];
extern u16 gLastUsedItem;
extern u8 gLastUsedAbility;
extern u8 gBattlerAttacker;
@@ -673,7 +676,7 @@ extern u8 gLastHitBy[MAX_BATTLERS_COUNT];
extern u16 gChosenMoveByBattler[MAX_BATTLERS_COUNT];
extern u8 gMoveResultFlags;
extern u32 gHitMarker;
extern u8 gTakenDmgByBattler[MAX_BATTLERS_COUNT];
extern u8 gBideTarget[MAX_BATTLERS_COUNT];
extern u8 gUnusedFirstBattleVar2;
extern u16 gSideStatuses[NUM_BATTLE_SIDES];
extern struct SideTimer gSideTimers[NUM_BATTLE_SIDES];

View File

@@ -168,7 +168,7 @@
// Not really sure what a "hitmarker" is.
#define HITMARKER_WAKE_UP_CLEAR (1 << 4) // Cleared when waking up. Never set or checked.
#define HITMARKER_SKIP_DMG_TRACK (1 << 5)
#define HITMARKER_IGNORE_BIDE (1 << 5)
#define HITMARKER_DESTINYBOND (1 << 6)
#define HITMARKER_NO_ANIMATIONS (1 << 7)
#define HITMARKER_IGNORE_SUBSTITUTE (1 << 8)
@@ -176,7 +176,7 @@
#define HITMARKER_ATTACKSTRING_PRINTED (1 << 10)
#define HITMARKER_NO_PPDEDUCT (1 << 11)
#define HITMARKER_SWAP_ATTACKER_TARGET (1 << 12)
#define HITMARKER_IGNORE_SAFEGUARD (1 << 13)
#define HITMARKER_STATUS_ABILITY_EFFECT (1 << 13)
#define HITMARKER_SYNCHRONISE_EFFECT (1 << 14)
#define HITMARKER_RUN (1 << 15)
#define HITMARKER_IGNORE_ON_AIR (1 << 16)

View File

@@ -16,12 +16,12 @@
#define PALACE_DATA_WIN_STREAK 1
#define PALACE_DATA_WIN_STREAK_ACTIVE 2
// Pokemon in Battle Palace have a move "group" type preference depending on nature
// Pokémon in Battle Palace have a move "group" type preference depending on nature
#define PALACE_MOVE_GROUP_ATTACK 0
#define PALACE_MOVE_GROUP_DEFENSE 1
#define PALACE_MOVE_GROUP_SUPPORT 2
// In palace doubles battles pokemon have a target preference depending on nature
// In palace doubles battles Pokémon have a target preference depending on nature
#define PALACE_TARGET_STRONGER 0
#define PALACE_TARGET_WEAKER 1
#define PALACE_TARGET_RANDOM 2

View File

@@ -62,7 +62,7 @@
#define DEPT_STORE_FLOORNUM_11F 14
#define DEPT_STORE_FLOORNUM_ROOFTOP 15
// Lilycove Pokemon Trainer Fan Club
// Lilycove Pokémon Trainer Fan Club
#define NUM_TRAINER_FAN_CLUB_MEMBERS 8
#define FANCLUB_GOT_FIRST_FANS 7

View File

@@ -2,9 +2,9 @@
#define GUARD_CONSTANTS_GLOBAL_H
// Invalid Versions show as "----------" in Gen 4 and Gen 5's summary screen.
// In Gens 6 and 7, invalid versions instead show "a distant land" in the summary screen.
// In Gen 4 only, migrated Pokemon with Diamond, Pearl, or Platinum's ID show as "----------".
// In Gen 4 only, migrated Pokémon with Diamond, Pearl, or Platinum's ID show as "----------".
// Gen 5 and up read Diamond, Pearl, or Platinum's ID as "Sinnoh".
// In Gen 4 and up, migrated Pokemon with HeartGold or SoulSilver's ID show the otherwise unused "Johto" string.
// In Gen 4 and up, migrated Pokémon with HeartGold or SoulSilver's ID show the otherwise unused "Johto" string.
#define VERSION_SAPPHIRE 1
#define VERSION_RUBY 2
#define VERSION_EMERALD 3

View File

@@ -23,7 +23,7 @@
#define FIRST_BALL ITEM_MASTER_BALL
#define LAST_BALL ITEM_PREMIER_BALL
// Pokemon Items
// Pokémon Items
#define ITEM_POTION 13
#define ITEM_ANTIDOTE 14
#define ITEM_BURN_HEAL 15
@@ -476,7 +476,7 @@
#define ITEM_B_USE_MEDICINE 1
#define ITEM_B_USE_OTHER 2
// Check if the item is one that can be used on a Pokemon.
// Check if the item is one that can be used on a Pokémon.
#define ITEM_HAS_EFFECT(item) ((item) >= ITEM_POTION && (item) <= MAX_BERRY_INDEX)
#endif // GUARD_CONSTANTS_ITEMS_H

View File

@@ -1,7 +1,7 @@
#ifndef GUARD_CONSTANTS_POKEDEX_H
#define GUARD_CONSTANTS_POKEDEX_H
// National Pokedex order
// National Pokédex order
enum {
NATIONAL_DEX_NONE,
// Kanto
@@ -425,7 +425,7 @@ enum {
#define JOHTO_DEX_COUNT NATIONAL_DEX_CELEBI
#define NATIONAL_DEX_COUNT NATIONAL_DEX_DEOXYS
// Hoenn Pokedex order
// Hoenn Pokédex order
enum {
HOENN_DEX_NONE,
HOENN_DEX_TREECKO,
@@ -631,7 +631,7 @@ enum {
HOENN_DEX_JIRACHI,
HOENN_DEX_DEOXYS,
// End of Hoenn Dex (see HOENN_DEX_COUNT)
// Here below have values but are excluded from the Pokedex
// Here below have values but are excluded from the Pokédex
HOENN_DEX_BULBASAUR,
HOENN_DEX_IVYSAUR,
HOENN_DEX_VENUSAUR,

View File

@@ -1,7 +1,7 @@
#ifndef GUARD_CONSTANTS_POKEMON_H
#define GUARD_CONSTANTS_POKEMON_H
// Pokemon types
// Pokémon types
#define TYPE_NONE 255
#define TYPE_NORMAL 0
#define TYPE_FIGHTING 1
@@ -23,27 +23,27 @@
#define TYPE_DARK 17
#define NUMBER_OF_MON_TYPES 18
// Pokemon egg groups
#define EGG_GROUP_NONE 0
#define EGG_GROUP_MONSTER 1
#define EGG_GROUP_WATER_1 2
#define EGG_GROUP_BUG 3
#define EGG_GROUP_FLYING 4
#define EGG_GROUP_FIELD 5
#define EGG_GROUP_FAIRY 6
#define EGG_GROUP_GRASS 7
#define EGG_GROUP_HUMAN_LIKE 8
#define EGG_GROUP_WATER_3 9
#define EGG_GROUP_MINERAL 10
#define EGG_GROUP_AMORPHOUS 11
#define EGG_GROUP_WATER_2 12
#define EGG_GROUP_DITTO 13
#define EGG_GROUP_DRAGON 14
#define EGG_GROUP_UNDISCOVERED 15
// Pokémon egg groups
#define EGG_GROUP_NONE 0
#define EGG_GROUP_MONSTER 1
#define EGG_GROUP_WATER_1 2
#define EGG_GROUP_BUG 3
#define EGG_GROUP_FLYING 4
#define EGG_GROUP_FIELD 5
#define EGG_GROUP_FAIRY 6
#define EGG_GROUP_GRASS 7
#define EGG_GROUP_HUMAN_LIKE 8
#define EGG_GROUP_WATER_3 9
#define EGG_GROUP_MINERAL 10
#define EGG_GROUP_AMORPHOUS 11
#define EGG_GROUP_WATER_2 12
#define EGG_GROUP_DITTO 13
#define EGG_GROUP_DRAGON 14
#define EGG_GROUP_NO_EGGS_DISCOVERED 15
#define EGG_GROUPS_PER_MON 2
#define EGG_GROUPS_PER_MON 2
// Pokemon natures
// Pokémon natures
#define NATURE_HARDY 0
#define NATURE_LONELY 1
#define NATURE_BRAVE 2
@@ -71,7 +71,7 @@
#define NATURE_QUIRKY 24
#define NUM_NATURES 25
// Pokemon Stats
// Pokémon Stats
#define STAT_HP 0
#define STAT_ATK 1
#define STAT_DEF 2
@@ -220,7 +220,7 @@
#define GROWTH_FAST 4
#define GROWTH_SLOW 5
// Body colors for pokedex search
// Body colors for Pokédex search
#define BODY_COLOR_RED 0
#define BODY_COLOR_BLUE 1
#define BODY_COLOR_YELLOW 2
@@ -263,7 +263,7 @@
#define MON_PIC_HEIGHT 64
#define MON_PIC_SIZE (MON_PIC_WIDTH * MON_PIC_HEIGHT / 2)
// Most pokemon have 2 frames (a default and an alternate for their animation).
// Most Pokémon have 2 frames (a default and an alternate for their animation).
// There are 4 exceptions:
// - Castform has 4 frames, 1 for each form
// - Deoxys has 2 frames, 1 for each form

View File

@@ -170,7 +170,7 @@
#define NUM_SECRET_BASE_FLAGS 32 // by definition, bitfield of 2 u16s
// TV Show states for Pokemon Contest Live Updates
// TV Show states for Pokémon Contest Live Updates
#define CONTESTLIVE_STATE_INTRO 0
#define CONTESTLIVE_STATE_WON_BOTH_ROUNDS 1
#define CONTESTLIVE_STATE_BETTER_ROUND2 2

View File

@@ -209,7 +209,7 @@ struct ContestantStatus
u8 comboAppealBonus;
u8 repeatJam;
u8 nextTurnOrder; // turn position
u8 attentionLevel; // How much the Pokemon "stood out"
u8 attentionLevel; // How much the Pokémon "stood out"
u8 contestantAnimTarget;
};

View File

@@ -137,7 +137,7 @@
#define ROUND_BITS_TO_BYTES(numBits) DIV_ROUND_UP(numBits, 8)
// NUM_DEX_FLAG_BYTES allocates more flags than it needs to, as NUM_SPECIES includes the "old unown"
// values that don't appear in the Pokedex. NATIONAL_DEX_COUNT does not include these values.
// values that don't appear in the Pokédex. NATIONAL_DEX_COUNT does not include these values.
#define NUM_DEX_FLAG_BYTES ROUND_BITS_TO_BYTES(NUM_SPECIES)
#define NUM_FLAG_BYTES ROUND_BITS_TO_BYTES(FLAGS_COUNT)
#define NUM_TRENDY_SAYING_BYTES ROUND_BITS_TO_BYTES(NUM_TRENDY_SAYINGS)
@@ -522,7 +522,7 @@ struct SaveBlock2
/*0x90*/ u8 filler_90[0x8];
/*0x98*/ struct Time localTimeOffset;
/*0xA0*/ struct Time lastBerryTreeUpdate;
/*0xA8*/ u32 gcnLinkFlags; // Read by Pokemon Colosseum/XD
/*0xA8*/ u32 gcnLinkFlags; // Read by Pokémon Colosseum/XD
/*0xAC*/ u32 encryptionKey;
/*0xB0*/ struct PlayersApprentice playerApprentice;
/*0xDC*/ struct Apprentice apprentices[APPRENTICE_COUNT];

View File

@@ -32,7 +32,7 @@ extern const u32 gBallGfx_Premier[];
extern const u32 gBallPal_Premier[];
extern const u32 gOpenPokeballGfx[];
// pokemon gfx
// Pokémon gfx
extern const u32 gMonFrontPic_Bulbasaur[];
extern const u32 gMonPalette_Bulbasaur[];
extern const u32 gMonBackPic_Bulbasaur[];
@@ -881,13 +881,13 @@ extern const u32 gMonShinyPalette_Starmie[];
extern const u32 gMonStillFrontPic_Starmie[];
extern const u8 gMonIcon_Starmie[];
extern const u8 gMonFootprint_Starmie[];
extern const u32 gMonFrontPic_Mrmime[];
extern const u32 gMonPalette_Mrmime[];
extern const u32 gMonBackPic_Mrmime[];
extern const u32 gMonShinyPalette_Mrmime[];
extern const u32 gMonStillFrontPic_Mrmime[];
extern const u8 gMonIcon_Mrmime[];
extern const u8 gMonFootprint_Mrmime[];
extern const u32 gMonFrontPic_MrMime[];
extern const u32 gMonPalette_MrMime[];
extern const u32 gMonBackPic_MrMime[];
extern const u32 gMonShinyPalette_MrMime[];
extern const u32 gMonStillFrontPic_MrMime[];
extern const u8 gMonIcon_MrMime[];
extern const u8 gMonFootprint_MrMime[];
extern const u32 gMonFrontPic_Scyther[];
extern const u32 gMonPalette_Scyther[];
extern const u32 gMonBackPic_Scyther[];
@@ -3282,7 +3282,7 @@ extern const u32 gBattleTerrainPalette_StadiumGlacia[];
extern const u32 gBattleTerrainPalette_StadiumDrake[];
extern const u32 gBattleTerrainPalette_StadiumWallace[];
// pokedex
// Pokédex
extern const u32 gPokedexInterface_Gfx[];
extern const u16 gPokedexBgHoenn_Pal[];
extern const u32 gPokedexMenu_Gfx[];
@@ -4005,7 +4005,7 @@ extern const u32 gBerryPalette_Starf[];
extern const u32 gBerryPic_Enigma[];
extern const u32 gBerryPalette_Enigma[];
//pokenav
//PokéNav
extern const u16 gPokenavCondition_Pal[];
extern const u32 gPokenavCondition_Gfx[];
extern const u32 gPokenavCondition_Tilemap[];
@@ -4879,11 +4879,11 @@ extern const u16 gSlotMachineReelTimePikachu_Pal[];
extern const u32 gBattleAnimBgTilemap_Sandstorm[];
extern const u32 gBattleAnimBgImage_Sandstorm[];
// Pokedex Area Screen
// Pokédex Area Screen
extern const u32 gPokedexAreaScreenAreaUnknown_Gfx[];
extern const u16 gPokedexAreaScreenAreaUnknown_Pal[];
// Pokemon Storage System
// Pokémon Storage System
extern const u32 gStorageSystemMenu_Gfx[];
extern const u16 gStorageSystemPartyMenu_Pal[];
extern const u32 gStorageSystemPartyMenu_Tilemap[];
@@ -5011,7 +5011,7 @@ extern const u32 gBerryCrush_Crusher_Gfx[];
extern const u16 gBerryCrush_Crusher_Pal[];
extern const u32 gBerryCrush_TextWindows_Tilemap[];
// Pokenav
// PokéNav
extern const u32 gPokenavMessageBox_Gfx[];
extern const u32 gPokenavMessageBox_Tilemap[];
extern const u16 gPokenavMessageBox_Pal[];

View File

@@ -203,7 +203,8 @@ struct BoxPokemon
u8 isBadEgg:1;
u8 hasSpecies:1;
u8 isEgg:1;
u8 unused:5;
u8 blockBoxRS:1; // Unused, but Pokémon Box Ruby & Sapphire will refuse to deposit a Pokémon with this flag set
u8 unused:4;
u8 otName[PLAYER_NAME_LENGTH];
u8 markings;
u16 checksum;

View File

@@ -14,7 +14,7 @@ void ShowPokemonSummaryScreenHandleDeoxys(u8 mode, struct BoxPokemon *mons, u8 m
u8 GetMoveSlotToReplace(void);
void SummaryScreen_SetAnimDelayTaskId(u8 taskId);
// The Pokemon Summary Screen can operate in different modes. Certain features,
// The Pokémon Summary Screen can operate in different modes. Certain features,
// such as move re-ordering, are available in the different modes.
enum PokemonSummaryScreenMode
{

View File

@@ -65,8 +65,8 @@ struct PokenavMonList
enum
{
POKENAV_MODE_NORMAL, // Chosen from Start menu.
POKENAV_MODE_FORCE_CALL_READY, // Pokenav tutorial before calling Mr. Stone
POKENAV_MODE_FORCE_CALL_EXIT, // Pokenav tutorial after calling Mr. Stone
POKENAV_MODE_FORCE_CALL_READY, // PokéNav tutorial before calling Mr. Stone
POKENAV_MODE_FORCE_CALL_EXIT, // PokéNav tutorial after calling Mr. Stone
};
enum
@@ -232,8 +232,8 @@ enum
[CHECK_PAGE_INTRO_2] = gText_MatchCall##name##_Intro2}
// Pokenav Function IDs
// Indices into the LoopedTask tables for each of the main Pokenav features
// PokéNav Function IDs
// Indices into the LoopedTask tables for each of the main PokéNav features
enum RegionMapFuncIds
{

View File

@@ -9,6 +9,10 @@
#define SIIRTCINFO_24HOUR 0x40 // 0: 12-hour mode, 1: 24-hour mode
#define SIIRTCINFO_POWER 0x80 // power on or power failure occurred
#define HOURS_PER_DAY 24
#define MINUTES_PER_HOUR 60
#define SECONDS_PER_MINUTE 60
enum
{
MONTH_JAN = 1,
@@ -22,7 +26,8 @@ enum
MONTH_SEP,
MONTH_OCT,
MONTH_NOV,
MONTH_DEC
MONTH_DEC,
MONTH_COUNT = MONTH_DEC
};
struct SiiRtcInfo

View File

@@ -519,7 +519,7 @@ extern const u8 gText_Speed[];
extern const u8 gText_Dash[];
extern const u8 gText_Plus[];
//pokedex text
//Pokédex text
extern const u8 gText_CryOf[];
extern const u8 gText_SizeComparedTo[];
extern const u8 gText_PokedexRegistration[];
@@ -1121,7 +1121,7 @@ extern const u8 gTrickHouse_Mechadoll_Six2[];
extern const u8 gTrickHouse_Mechadoll_Seven2[];
extern const u8 gTrickHouse_Mechadoll_Eight2[];
// Pokedex strings
// Pokédex strings
extern const u8 gText_SearchForPkmnBasedOnParameters[];
extern const u8 gText_SwitchPokedexListings[];
extern const u8 gText_ReturnToPokedex[];
@@ -2874,7 +2874,7 @@ extern const u8 gText_WantToPlayAgain[];
extern const u8 gText_CommunicationStandby3[];
extern const u8 gText_SomeoneDroppedOut[];
// Pokemon jump
// Pokémon jump
extern const u8 gText_WantToPlayAgain2[];
extern const u8 gText_SomeoneDroppedOut2[];
extern const u8 gText_CommunicationStandby4[];
@@ -2949,7 +2949,7 @@ extern const u8 gText_CutenessContest[];
extern const u8 gText_SmartnessContest[];
extern const u8 gText_ToughnessContest[];
// Pokenav Match Call
// PokéNav Match Call
extern const u8 gText_CallCantBeMadeHere[];
extern const u8 gText_NumberRegistered[];
extern const u8 gText_NumberOfBattles[];
@@ -2959,7 +2959,7 @@ extern const u8 gText_Call[];
extern const u8 gText_Check[];
extern const u8 gText_Cancel6[];
// Pokenav Menu Handler
// PokéNav Menu Handler
extern const u8 gText_CheckMapOfHoenn[];
extern const u8 gText_CheckPokemonInDetail[];
extern const u8 gText_CallRegisteredTrainer[];
@@ -2976,7 +2976,7 @@ extern const u8 gText_FindToughPokemon[];
extern const u8 gText_ReturnToConditionMenu[];
extern const u8 gText_NoRibbonWinners[];
// Pokenav
// PokéNav
extern const u8 gText_NumberIndex[];
extern const u8 gText_RibbonsF700[];