mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-01-22 07:32:07 -05:00
Make ending set level to LEVEL_ENDING
This commit is contained in:
parent
7e21a58eb3
commit
95ef1eb133
3 changed files with 22 additions and 20 deletions
|
@ -17,25 +17,26 @@
|
|||
#include "levels/ending/header.h"
|
||||
|
||||
const LevelScript level_ending_entry[] = {
|
||||
/*0*/ INIT_LEVEL(),
|
||||
/*1*/ LOAD_MIO0(/*seg*/ 0x07, _ending_segment_7SegmentRomStart, _ending_segment_7SegmentRomEnd),
|
||||
/*4*/ ALLOC_LEVEL_POOL(),
|
||||
CALL(/*arg*/ LEVEL_ENDING, /*func*/ lvl_set_current_level),
|
||||
INIT_LEVEL(),
|
||||
LOAD_MIO0(/*seg*/ 0x07, _ending_segment_7SegmentRomStart, _ending_segment_7SegmentRomEnd),
|
||||
ALLOC_LEVEL_POOL(),
|
||||
|
||||
/*5*/ AREA(/*index*/ 1, ending_geo_000050),
|
||||
/*7*/ END_AREA(),
|
||||
AREA(/*index*/ 1, ending_geo_000050),
|
||||
END_AREA(),
|
||||
|
||||
/*8*/ FREE_LEVEL_POOL(),
|
||||
/*9*/ SLEEP(/*frames*/ 60),
|
||||
/*10*/ BLACKOUT(/*active*/ FALSE),
|
||||
/*11*/ LOAD_AREA(/*area*/ 1),
|
||||
/*12*/ TRANSITION(/*transType*/ WARP_TRANSITION_FADE_FROM_COLOR, /*time*/ 75, /*color*/ 0x00, 0x00, 0x00),
|
||||
/*14*/ SLEEP(/*frames*/ 120),
|
||||
/*15*/ CALL(/*arg*/ 0, /*func*/ lvl_play_the_end_screen_sound),
|
||||
FREE_LEVEL_POOL(),
|
||||
SLEEP(/*frames*/ 60),
|
||||
BLACKOUT(/*active*/ FALSE),
|
||||
LOAD_AREA(/*area*/ 1),
|
||||
TRANSITION(/*transType*/ WARP_TRANSITION_FADE_FROM_COLOR, /*time*/ 75, /*color*/ 0x00, 0x00, 0x00),
|
||||
SLEEP(/*frames*/ 120),
|
||||
CALL(/*arg*/ 0, /*func*/ lvl_play_the_end_screen_sound),
|
||||
// L1:
|
||||
/*17*/ //SLEEP(/*frames*/ 1),
|
||||
/*18*/ //JUMP(level_ending_entry + 17),
|
||||
// SLEEP(/*frames*/ 1),
|
||||
// JUMP(level_ending_entry + 17),
|
||||
SLEEP_BEFORE_EXIT(/*frames*/ 30 * 10),
|
||||
/*15*/ CALL(/*arg*/ 0, /*func*/ lvl_exiting_credits),
|
||||
CALL(/*arg*/ 0, /*func*/ lvl_exiting_credits),
|
||||
CLEAR_LEVEL(),
|
||||
EXIT(),
|
||||
};
|
||||
|
|
|
@ -1906,16 +1906,17 @@ s32 lvl_init_from_save_file(UNUSED s16 arg0, s16 levelNum) {
|
|||
return levelNum;
|
||||
}
|
||||
|
||||
s32 lvl_set_current_level(UNUSED s16 arg0, s16 levelNum) {
|
||||
s32 lvl_set_current_level(s16 arg0, s16 levelNum) {
|
||||
s32 warpCheckpointActive = sWarpCheckpointActive;
|
||||
s16 level = arg0 != 0 ? arg0 : levelNum;
|
||||
|
||||
sWarpCheckpointActive = FALSE;
|
||||
gCurrLevelNum = levelNum;
|
||||
gCurrCourseNum = get_level_course_num(levelNum);
|
||||
gCurrLevelNum = level;
|
||||
gCurrCourseNum = get_level_course_num(level);
|
||||
|
||||
bool foundHook = false;
|
||||
bool hookUseActSelect = false;
|
||||
smlua_call_event_hooks_use_act_select(HOOK_USE_ACT_SELECT, levelNum, &foundHook, &hookUseActSelect);
|
||||
smlua_call_event_hooks_use_act_select(HOOK_USE_ACT_SELECT, level, &foundHook, &hookUseActSelect);
|
||||
|
||||
if (!foundHook || !hookUseActSelect) {
|
||||
if (gCurrDemoInput != NULL || gCurrCreditsEntry != NULL || gCurrCourseNum == COURSE_NONE) {
|
||||
|
|
|
@ -180,7 +180,7 @@ void initiate_warp(s16 destLevel, s16 destArea, s16 destWarpNode, s32 arg3);
|
|||
|
||||
s32 lvl_init_or_update(s16 initOrUpdate, UNUSED s32 unused);
|
||||
s32 lvl_init_from_save_file(UNUSED s16 arg0, s16 levelNum);
|
||||
s32 lvl_set_current_level(UNUSED s16 arg0, s16 levelNum);
|
||||
s32 lvl_set_current_level(s16 arg0, s16 levelNum);
|
||||
s32 lvl_play_the_end_screen_sound(UNUSED s16 arg0, UNUSED s32 arg1);
|
||||
void basic_update(UNUSED s16 *arg);
|
||||
|
||||
|
|
Loading…
Reference in a new issue