• Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
  • Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
  • Our weekly protagonist poll is now up! Vote for your favorite Trading Card Game 2 protagonist in the poll by clicking here.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

[Graphics] Surf Blob Palette issues

  • 34
    Posts
    3
    Years
    • Seen Aug 13, 2023
    Hello!

    I've recently run into an issue with my Surf Blob palette. After changing my player character's, I noticed the colors of the Surf Blob were wrong. I fixed this by changing the Surf Blob's palette to PAL_TAG_NPC_1 instead of PAL_TAG_MAY.

    However, I'm now noticing that after a battle, the Surf Blob's colors completely change again.
    [PokeCommunity.com] Surf Blob Palette issues

    When using mGBA, I used the View Palettes and View Sprites tools, and it seems that after a battle the surf blob loads Palette 15.

    [PokeCommunity.com] Surf Blob Palette issues


    My guess right now is that this is somehow connected to the Dynamic Palette system that came as part of the Lighting branch I've pulled from Aarant's lighting branch. Since the pokemon followers and dynamic palette system were bundled into the Lighting Branch and I didn't implement them myself, I don't really have a lot of insight into how they work, so if anyone has any leads or ideas on how I could address this, it'd be very helpful!

    Thanks!
     
    Scratch that; was able to fix it! Because this is an issue I've seen others bring up, I'll share what I did:

    Change gFieldEffectScript_SurfBlob:: in data/field_effect_scripts.s to:
    gFieldEffectScript_SurfBlob::
    field_eff_loadfadedpal_callnative gSpritePalette_SurfBlob, FldEff_SurfBlob
    field_eff_end

    Then, in src/data/field_effect_objects.h, put in the following:
    const struct SpritePalette gSpritePalette_SurfBlob = {gObjectEventPal_Npc1, OBJ_EVENT_PAL_TAG_NPC_1};

    I used Npc1 and the NPC_1 Pal Tag because that is the pointer I used for my Surf Blob (originally, it's MAY).

    This seems to have solved it so far from some quick spot checking, but I'll update if there's any issues.

    Credit goes to the user "Josh" on the Pret Discord, I wouldn't have been able to fix this if I hadn't found some of their older posts and then tweaked it to fit the changes I already made to palettes.
     
    Following up, but it seems dynamic palettes also caused some issues with the FLY animation. Using the same process as the fix for Surf Blob, I was able to address FLY's Bird problem.

    In data/field_effect_scripts.s, update two of the Fly scripts to:
    gFieldEffectScript_UseFly::
    field_eff_loadfadedpal_callnative gSpritePalette_Bird FldEff_UseFly
    field_eff_end

    gFieldEffectScript_FlyIn::
    field_eff_loadfadedpal_callnative gSpritePalette_Bird FldEff_FlyIn
    field_eff_end

    Then, in src/data/field_effect_objects.h, put in the following:
    const struct SpritePalette gSpritePalette_Bird = {gObjectEventPal_Npc1, OBJ_EVENT_PAL_TAG_NPC_1};

    Don't forget to change the PAL_TAG of the Fly sprite, or update the above to reference the pointers you're using.
     
    Back
    Top