Match last function in z_prenmi, add DISPS macros to ArmsHook (#305)

* preNMI OK, added DISP macros to ArmsHook

* Decimal colours in preNMI

* SCREEN_WIDTH

* engineer's review
This commit is contained in:
EllipticEllipsis
2021-09-30 20:50:11 -04:00
committed by GitHub
parent 48b91053ee
commit b5e9427db4
2 changed files with 43 additions and 47 deletions
+7 -8
View File
@@ -16,21 +16,20 @@ void PreNMI_Update(PreNMIContext* prenmiCtx) {
prenmiCtx->timer--;
}
#ifdef NON_MATCHING
// Minor reordering around call to func_8012C470
void PreNMI_Draw(PreNMIContext* prenmiCtx) {
GraphicsContext* gfxCtx = prenmiCtx->state.gfxCtx;
func_8012CF0C(gfxCtx, 1, 1, 0, 0, 0);
OPEN_DISPS(gfxCtx);
func_8012C470(gfxCtx);
gDPSetFillColor(gfxCtx->polyOpa.p++,
(GPACK_RGBA5551(0xFF, 0xFF, 0xFF, 1) << 16) | GPACK_RGBA5551(0xFF, 0xFF, 0xFF, 1));
gDPFillRectangle(gfxCtx->polyOpa.p++, 0, prenmiCtx->timer + 100, 320 /*SCREEN_WIDTH*/ - 1, prenmiCtx->timer + 100);
gDPSetFillColor(POLY_OPA_DISP++, (GPACK_RGBA5551(255, 255, 255, 1) << 16) | GPACK_RGBA5551(255, 255, 255, 1));
gDPFillRectangle(POLY_OPA_DISP++, 0, prenmiCtx->timer + 100, SCREEN_WIDTH - 1, prenmiCtx->timer + 100);
CLOSE_DISPS(gfxCtx);
}
#else
#pragma GLOBAL_ASM("asm/non_matchings/code/z_prenmi/PreNMI_Draw.s")
#endif
void PreNMI_Main(PreNMIContext* prenmiCtx) {
PreNMI_Update(prenmiCtx);