use GetBattlerParty in LoadMonSprite

This commit is contained in:
DizzyEggg 2023-08-21 09:43:01 +02:00
parent ce18df46e6
commit 9cf5376c96
8 changed files with 9 additions and 8 deletions

View File

@ -267,7 +267,7 @@ void BtlController_HandleGetMonData(u32 battler);
void BtlController_HandleGetRawMonData(u32 battler);
void BtlController_HandleSetMonData(u32 battler);
void BtlController_HandleSetRawMonData(u32 battler);
void BtlController_HandleLoadMonSprite(u32 battler, struct Pokemon *party, void (*controllerCallback)(u32 battler));
void BtlController_HandleLoadMonSprite(u32 battler, void (*controllerCallback)(u32 battler));
void BtlController_HandleSwitchInAnim(u32 battler, bool32 isPlayerSide, void (*controllerCallback)(u32 battler));
void BtlController_HandleReturnMonToBall(u32 battler);
void BtlController_HandleDrawTrainerPic(u32 battlerId, u32 trainerPicId, bool32 isFrontPic, s16 xPos, s16 yPos, s32 subpriority);

View File

@ -381,7 +381,7 @@ static void LinkOpponentBufferExecCompleted(u32 battler)
static void LinkOpponentHandleLoadMonSprite(u32 battler)
{
BtlController_HandleLoadMonSprite(battler, gEnemyParty, TryShinyAnimAfterMonAnim);
BtlController_HandleLoadMonSprite(battler, TryShinyAnimAfterMonAnim);
}
static void LinkOpponentHandleSwitchInAnim(u32 battler)

View File

@ -207,7 +207,7 @@ static void LinkPartnerBufferExecCompleted(u32 battler)
static void LinkPartnerHandleLoadMonSprite(u32 battler)
{
BtlController_HandleLoadMonSprite(battler, gPlayerParty, WaitForMonAnimAfterLoad);
BtlController_HandleLoadMonSprite(battler, WaitForMonAnimAfterLoad);
}
static void LinkPartnerHandleSwitchInAnim(u32 battler)

View File

@ -398,7 +398,7 @@ static void OpponentBufferExecCompleted(u32 battler)
static void OpponentHandleLoadMonSprite(u32 battler)
{
BtlController_HandleLoadMonSprite(battler, gEnemyParty, TryShinyAnimAfterMonAnim);
BtlController_HandleLoadMonSprite(battler, TryShinyAnimAfterMonAnim);
}
static void OpponentHandleSwitchInAnim(u32 battler)

View File

@ -278,7 +278,7 @@ static void PlayerPartnerBufferExecCompleted(u32 battler)
static void PlayerPartnerHandleLoadMonSprite(u32 battler)
{
BtlController_HandleLoadMonSprite(battler, gPlayerParty, WaitForMonAnimAfterLoad);
BtlController_HandleLoadMonSprite(battler, WaitForMonAnimAfterLoad);
}
static void PlayerPartnerHandleSwitchInAnim(u32 battler)

View File

@ -375,7 +375,7 @@ static void SwitchIn_TryShinyAnim(u32 battler)
static void RecordedOpponentHandleLoadMonSprite(u32 battler)
{
BtlController_HandleLoadMonSprite(battler, gEnemyParty, TryShinyAnimAfterMonAnim);
BtlController_HandleLoadMonSprite(battler, TryShinyAnimAfterMonAnim);
}
static void RecordedOpponentHandleSwitchInAnim(u32 battler)

View File

@ -357,7 +357,7 @@ static void RecordedPlayerBufferExecCompleted(u32 battler)
static void RecordedPlayerHandleLoadMonSprite(u32 battler)
{
BtlController_HandleLoadMonSprite(battler, gPlayerParty, WaitForMonAnimAfterLoad);
BtlController_HandleLoadMonSprite(battler, WaitForMonAnimAfterLoad);
}
static void RecordedPlayerHandleSwitchInAnim(u32 battler)

View File

@ -2417,8 +2417,9 @@ void BtlController_HandleSetRawMonData(u32 battler)
BattleControllerComplete(battler);
}
void BtlController_HandleLoadMonSprite(u32 battler, struct Pokemon *party, void (*controllerCallback)(u32 battler))
void BtlController_HandleLoadMonSprite(u32 battler, void (*controllerCallback)(u32 battler))
{
struct Pokemon *party = GetBattlerParty(battler);
u16 species = GetMonData(&party[gBattlerPartyIndexes[battler]], MON_DATA_SPECIES);
BattleLoadMonSpriteGfx(&party[gBattlerPartyIndexes[battler]], battler);