budude2 / openfpga-GBC

193 stars 5 forks source link

Colour change in Pokemon blue #52

Open KimiRaiki7 opened 2 months ago

KimiRaiki7 commented 2 months ago

In Pokémon Blue the color often changes briefly during battles (if sgb mode is enabled) Is this a known problem?

KimiRaiki7 commented 2 months ago

https://github.com/budude2/openfpga-GBC/assets/167031783/0a5a453e-da2e-4cbd-aa0d-05a454746fdc

here you can seethe problem: the graphics change the color during the fight

825i commented 3 weeks ago

Is it happening in other games? Looks like your pocket is breaking...

KimiRaiki7 commented 3 weeks ago

Is it happening in other games? Looks like your pocket is breaking...

No, I only noticed the problem in pokemon blue/red. Did you try it on your pocket?

Anatrok commented 2 weeks ago

I can confirm this behavior. If you compare to the spiritualized SGB core (or a physical SGB) this brief color cycle does not occur.

I noticed that on startup this core is using a green DMG-esque palette before flashing to black, the back to white with the expected SGB palette.

It seems that during any sprite palette swap (Pokémon red/blue does this when swapping Pokémon in battle on SGB so every Pokémon has an accurate palette) this core has a frame where both sprites default back to the dmg-esque palette. This is just my laymen's guess. This is also why the flash occurs when the health bar goes to yellow or red.