Generalize usage of castformPalette
This commit is contained in:
parent
ef4d99c87e
commit
91baf08638
1 changed files with 3 additions and 3 deletions
|
@ -590,7 +590,7 @@ void BattleLoadOpponentMonSpriteGfx(struct Pokemon *mon, u8 battlerId)
|
|||
if (species == SPECIES_CASTFORM)
|
||||
{
|
||||
paletteOffset = 0x100 + battlerId * 16;
|
||||
LZDecompressWram(lzPaletteData, gBattleStruct->castformPalette[CASTFORM_NORMAL]);
|
||||
LZDecompressWram(lzPaletteData, gBattleStruct->castformPalette);
|
||||
LoadPalette(gBattleStruct->castformPalette[gBattleMonForms[battlerId]], paletteOffset, 0x20);
|
||||
}
|
||||
|
||||
|
@ -653,7 +653,7 @@ void BattleLoadPlayerMonSpriteGfx(struct Pokemon *mon, u8 battlerId)
|
|||
if (species == SPECIES_CASTFORM)
|
||||
{
|
||||
paletteOffset = 0x100 + battlerId * 16;
|
||||
LZDecompressWram(lzPaletteData, gBattleStruct->castformPalette[CASTFORM_NORMAL]);
|
||||
LZDecompressWram(lzPaletteData, gBattleStruct->castformPalette);
|
||||
LoadPalette(gBattleStruct->castformPalette[gBattleMonForms[battlerId]], paletteOffset, 0x20);
|
||||
}
|
||||
|
||||
|
@ -973,7 +973,7 @@ void HandleSpeciesGfxDataChange(u8 battlerAtk, u8 battlerDef, bool8 castform)
|
|||
if (targetSpecies == SPECIES_CASTFORM)
|
||||
{
|
||||
gSprites[gBattlerSpriteIds[battlerAtk]].anims = gMonFrontAnimsPtrTable[targetSpecies];
|
||||
LZDecompressWram(lzPaletteData, gBattleStruct->castformPalette[CASTFORM_NORMAL]);
|
||||
LZDecompressWram(lzPaletteData, gBattleStruct->castformPalette);
|
||||
LoadPalette(gBattleStruct->castformPalette[gBattleMonForms[battlerDef]], paletteOffset, 32);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue