Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CaveTransition pals #2095

Merged
merged 1 commit into from
Jan 15, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Fix CaveTransition pals
DizzyEggg committed Jan 15, 2025
commit 9385dfed67a4b0d68a7b6e39682ba0b3d2e7d814
10 changes: 9 additions & 1 deletion graphics/cave_transition/enter.pal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
JASC-PAL
0100
8
16
148 197 172
16 16 16
32 32 32
@@ -9,3 +9,11 @@ JASC-PAL
82 82 82
98 98 98
115 115 115
131 131 131
148 148 148
164 164 164
180 180 180
197 197 197
213 213 213
230 230 230
255 255 255
11 changes: 0 additions & 11 deletions graphics/cave_transition/exit.pal

This file was deleted.

8 changes: 4 additions & 4 deletions src/fldeff_flash.c
Original file line number Diff line number Diff line change
@@ -65,7 +65,7 @@ static const u16 sCaveTransitionPalette_White[] = INCBIN_U16("graphics/cave_tran
static const u16 sCaveTransitionPalette_Black[] = INCBIN_U16("graphics/cave_transition/black.gbapal");

static const u16 sCaveTransitionPalette_Enter[] = INCBIN_U16("graphics/cave_transition/enter.gbapal");
static const u16 sCaveTransitionPalette_Exit[] = INCBIN_U16("graphics/cave_transition/exit.gbapal");

static const u32 sCaveTransitionTilemap[] = INCBIN_U32("graphics/cave_transition/tilemap.bin.lz");
static const u32 sCaveTransitionTiles[] = INCBIN_U32("graphics/cave_transition/tiles.4bpp.lz");

@@ -219,7 +219,7 @@ static void Task_ExitCaveTransition2(u8 taskId)
LZ77UnCompVram(sCaveTransitionTiles, (void *)(VRAM + 0xC000));
LZ77UnCompVram(sCaveTransitionTilemap, (void *)(VRAM + 0xF800));
LoadPalette(sCaveTransitionPalette_White, BG_PLTT_ID(14), PLTT_SIZE_4BPP);
LoadPalette(sCaveTransitionPalette_Exit, BG_PLTT_ID(14), PLTT_SIZEOF(8));
LoadPalette(&sCaveTransitionPalette_Enter[8], BG_PLTT_ID(14), PLTT_SIZEOF(8));
SetGpuReg(REG_OFFSET_BLDCNT, BLDCNT_TGT1_BG0
| BLDCNT_EFFECT_BLEND
| BLDCNT_TGT2_BG1
@@ -249,7 +249,7 @@ static void Task_ExitCaveTransition3(u8 taskId)
u16 blend = count + 0x1000;

SetGpuReg(REG_OFFSET_BLDALPHA, blend);
if (count <= 0x10)
if (count <= 16)
{
gTasks[taskId].data[1]++;
}
@@ -270,7 +270,7 @@ static void Task_ExitCaveTransition4(u8 taskId)
if (count < 8)
{
gTasks[taskId].data[2]++;
LoadPalette(&sCaveTransitionPalette_Exit[count], BG_PLTT_ID(14), sizeof(sCaveTransitionPalette_Exit) - PLTT_SIZEOF(count));
LoadPalette(&sCaveTransitionPalette_Enter[8 + count], BG_PLTT_ID(14), PLTT_SIZEOF(8) - PLTT_SIZEOF(count));
}
else
{