Skip to content

Commit b2e15cb

Browse files
committed
Flash the screen when starting last-run ROM by holding B button
1 parent 55a1700 commit b2e15cb

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

title/arm9/source/main.cpp

+16
Original file line numberDiff line numberDiff line change
@@ -2723,6 +2723,22 @@ int titleMode(void)
27232723
}
27242724

27252725
scanKeys();
2726+
if (keysHeld() & KEY_B) {
2727+
// Indicate that the B button was held
2728+
if (!ms().macroMode) {
2729+
powerOff(PM_BACKLIGHT_TOP);
2730+
}
2731+
powerOff(PM_BACKLIGHT_BOTTOM);
2732+
2733+
for (int i = 0; i < 5; i++) {
2734+
swiWaitForVBlank();
2735+
}
2736+
2737+
if (!ms().macroMode) {
2738+
powerOn(PM_BACKLIGHT_TOP);
2739+
}
2740+
powerOn(PM_BACKLIGHT_BOTTOM);
2741+
}
27262742

27272743
autoRunBit = (*(u32*)0x02000000 & BIT(3));
27282744
runTempDSiWare = (*(u32*)0x02000000 & BIT(4));

0 commit comments

Comments
 (0)