port: fix credits crash

campaign is now more or less completable, other than the pushbox collision bug
This commit is contained in:
fgsfds committed 2023-08-13 22:49:00 +02:00
1 parent 358f788b61
commit 758eb77578
1 file changed
+7
+7
View File
@@ -2311,8 +2311,15 @@ Gfx *menuRenderModels(Gfx *gdl, struct menu840 *thing, s32 arg2)
} }
gSPSetLights1(gdl++, var80071468); gSPSetLights1(gdl++, var80071468);
#ifdef AVOID_UB
// during the credits camGetLookAt() can return NULL
if (camGetLookAt()) {
#endif
gSPLookAtX(gdl++, &camGetLookAt()->l[0]); gSPLookAtX(gdl++, &camGetLookAt()->l[0]);
gSPLookAtY(gdl++, &camGetLookAt()->l[1]); gSPLookAtY(gdl++, &camGetLookAt()->l[1]);
#ifdef AVOID_UB
}
#endif
renderdata.unk30 = 1; renderdata.unk30 = 1;
renderdata.envcolour = 0xffffffff; renderdata.envcolour = 0xffffffff;