mirror of
https://github.com/pret/pokefirered.git
synced 2026-09-30 12:59:43 -05:00
fix player palette after hall of fame
This commit is contained in:
@@ -111,7 +111,7 @@ struct __attribute__((packed, aligned(4))) ObjectEventTemplate
|
||||
{
|
||||
/*0x00*/ u8 localId;
|
||||
/*0x01*/ u16 graphicsId;
|
||||
/*0x03*/ u8 kind; // Always OBJ_KIND_NORMAL in Emerald.
|
||||
/*0x03*/ u8 kind; // The "kind" field determines how to access objUnion union below.
|
||||
/*0x04*/ s16 x;
|
||||
/*0x06*/ s16 y;
|
||||
union {
|
||||
|
||||
@@ -2796,7 +2796,6 @@ static u8 UpdateSpritePalette(const struct SpritePalette *spritePalette, struct
|
||||
FieldEffectFreePaletteIfUnused(sprite->oam.paletteNum);
|
||||
sprite->inUse = TRUE;
|
||||
sprite->oam.paletteNum = LoadSpritePalette(spritePalette);
|
||||
ApplyGlobalFieldPaletteTint(sprite->oam.paletteNum);
|
||||
return sprite->oam.paletteNum;
|
||||
}
|
||||
|
||||
@@ -2814,7 +2813,7 @@ static void ObjectEventSetGraphics(struct ObjectEvent *objectEvent, const struct
|
||||
{
|
||||
struct Sprite *sprite = &gSprites[objectEvent->spriteId];
|
||||
u32 i = FindObjectEventPaletteIndexByTag(graphicsInfo->paletteTag);
|
||||
if (i != 0xFF)
|
||||
if (i != 0xFF && graphicsInfo->paletteSlot != PALSLOT_PLAYER)
|
||||
UpdateSpritePalette(&sObjectEventSpritePalettes[i], sprite);
|
||||
|
||||
// If gfx size changes, we need to reallocate tiles
|
||||
|
||||
Reference in New Issue
Block a user