mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2024-10-19 03:32:41 +00:00
Credits skip (you can merge this now) (#52)
This commit is contained in:
parent
36c1d52e1f
commit
87aa18ef65
2 changed files with 25 additions and 21 deletions
|
@ -1530,6 +1530,7 @@ void update_mario_inputs(struct MarioState *m) {
|
|||
/* End of developer stuff */
|
||||
|
||||
if ((m->action == ACT_END_PEACH_CUTSCENE || m->action == ACT_CREDITS_CUTSCENE) && m->controller->buttonPressed & START_BUTTON) {
|
||||
gCurrCreditsEntry = NULL;
|
||||
gCurrActStarNum = 0;
|
||||
gCurrActNum = 0;
|
||||
gChangeLevel = 16;
|
||||
|
|
|
@ -2807,33 +2807,36 @@ static s32 act_credits_cutscene(struct MarioState *m) {
|
|||
m->actionState += 2;
|
||||
}
|
||||
|
||||
if (m->playerIndex == 0) {
|
||||
s32 width = m->actionState * 640 / 100;
|
||||
s32 height = m->actionState * 480 / 100;
|
||||
if (gCurrCreditsEntry != NULL) {
|
||||
if (m->playerIndex == 0) {
|
||||
s32 width = m->actionState * 640 / 100;
|
||||
s32 height = m->actionState * 480 / 100;
|
||||
|
||||
sEndCutsceneVp.vp.vscale[0] = 640 - width;
|
||||
sEndCutsceneVp.vp.vscale[1] = 480 - height;
|
||||
sEndCutsceneVp.vp.vtrans[0] = (gCurrCreditsEntry->unk02 & 0x10 ? width : -width) * 56 / 100 + 640;
|
||||
sEndCutsceneVp.vp.vtrans[1] = (gCurrCreditsEntry->unk02 & 0x20 ? height : -height) * 66 / 100 + 480;
|
||||
sEndCutsceneVp.vp.vscale[0] = 640 - width;
|
||||
sEndCutsceneVp.vp.vscale[1] = 480 - height;
|
||||
sEndCutsceneVp.vp.vtrans[0] = (gCurrCreditsEntry->unk02 & 0x10 ? width : -width) * 56 / 100 + 640;
|
||||
sEndCutsceneVp.vp.vtrans[1] = (gCurrCreditsEntry->unk02 & 0x20 ? height : -height) * 66 / 100 + 480;
|
||||
|
||||
override_viewport_and_clip(&sEndCutsceneVp, 0, 0, 0, 0);
|
||||
override_viewport_and_clip(&sEndCutsceneVp, 0, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (m->actionTimer == TIMER_CREDITS_PROGRESS && m->playerIndex == 0) {
|
||||
reset_cutscene_msg_fade();
|
||||
if (gCurrCreditsEntry != NULL) {
|
||||
if (m->actionTimer == TIMER_CREDITS_PROGRESS && m->playerIndex == 0) {
|
||||
reset_cutscene_msg_fade();
|
||||
}
|
||||
|
||||
if (m->actionTimer >= TIMER_CREDITS_PROGRESS && m->playerIndex == 0) {
|
||||
sDispCreditsEntry = gCurrCreditsEntry;
|
||||
}
|
||||
|
||||
if (m->actionTimer++ == TIMER_CREDITS_WARP && m->playerIndex == 0) {
|
||||
level_trigger_warp(m, WARP_OP_CREDITS_NEXT);
|
||||
}
|
||||
|
||||
m->marioObj->header.gfx.angle[1] += (gCurrCreditsEntry->unk02 & 0xC0) << 8;
|
||||
}
|
||||
|
||||
if (m->actionTimer >= TIMER_CREDITS_PROGRESS && m->playerIndex == 0) {
|
||||
sDispCreditsEntry = gCurrCreditsEntry;
|
||||
}
|
||||
|
||||
if (m->actionTimer++ == TIMER_CREDITS_WARP && m->playerIndex == 0) {
|
||||
level_trigger_warp(m, WARP_OP_CREDITS_NEXT);
|
||||
}
|
||||
|
||||
m->marioObj->header.gfx.angle[1] += (gCurrCreditsEntry->unk02 & 0xC0) << 8;
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue