Switching to a boss blind now changes the background palette

This commit is contained in:
Elliptical
2025-08-02 10:29:26 -04:00
parent da8b3bbc00
commit 8315d6a42c
2 changed files with 9 additions and 1 deletions
+8
View File
@@ -18,6 +18,7 @@
#include "background_gfx.h"
#include "background_shop_gfx.h"
#include "background_blind_select_gfx.h"
#include "affine_background_gfx.h"
#include "soundbank.h"
@@ -419,6 +420,13 @@ void change_background(int id)
else if (current_blind == BOSS_BLIND)
{
main_bg_se_copy_rect(BOSS_BLIND_TITLE_SRC_RECT, TOP_LEFT_BLIND_TITLE_POINT);
u16 palette[5] = {};
palette[0] = blind_get_color(current_blind, BLIND_BACKGROUND_SECONDARY_COLOR_INDEX);
palette[1] = blind_get_color(current_blind, BLIND_SHADOW_COLOR_INDEX);
palette[2] = blind_get_color(current_blind, BLIND_BACKGROUND_SHADOW_COLOR_INDEX);
palette[3] = blind_get_color(current_blind, BLIND_MAIN_COLOR_INDEX);
palette[4] = blind_get_color(current_blind, BLIND_TEXT_COLOR_INDEX);
memcpy16(&pal_bg_mem[16 * 15], palette, 5);
}
bg_copy_current_item_to_top_left_panel();
+1 -1
View File
@@ -33,7 +33,7 @@ void init_map() // Temp function derived from libtonc example
// Actually for future reference, each number seems to equate to an XY on the palette, so 0xF0F0F0F0 would just push everything down 15 colors, since the second number isn't set.
}
memcpy(&tile8_mem[AFFINE_BG_CBB], correctedTiles, affine_background_gfxTilesLen);
memcpy16(&tile8_mem[AFFINE_BG_CBB], correctedTiles, affine_background_gfxTilesLen);
GRIT_CPY(&se_mem[AFFINE_BG_SBB], affine_background_gfxMap);
memcpy16(&pal_bg_mem[16 * 15], affine_background_gfxPal, 5);