mirror of
https://github.com/HarbourMasters/Starship.git
synced 2025-02-02 16:23:57 +03:00
Better BackToMap
This commit is contained in:
parent
9947aa8df1
commit
53527072d3
@ -17,6 +17,8 @@
|
||||
#include "assets/ast_font_3d.h"
|
||||
#include "port/interpolation/FrameInterpolation.h"
|
||||
|
||||
extern bool gBackToMap;
|
||||
|
||||
// BSS STARTS HERE
|
||||
u8 gMapVenomCloudTex[96 * 96];
|
||||
u8 gMapCorneriaTex[96 * 96];
|
||||
@ -2143,7 +2145,8 @@ void Map_Prologue_Update(void) {
|
||||
break;
|
||||
}
|
||||
|
||||
if (gControllerPress[gMainController].button & START_BUTTON) {
|
||||
if ((gControllerPress[gMainController].button & START_BUTTON) || gBackToMap) {
|
||||
gBackToMap = false;
|
||||
AUDIO_PLAY_BGM(NA_BGM_MAP);
|
||||
AUDIO_PLAY_SFX(NA_SE_MAP_MOVE_STOP, gDefaultSfxSource, 4);
|
||||
|
||||
|
@ -6,6 +6,8 @@
|
||||
#define INIT_EVENT_IDS
|
||||
#include "port/hooks/Events.h"
|
||||
|
||||
bool gBackToMap;
|
||||
|
||||
void OnDisplayUpdatePost(IEvent* event) {
|
||||
#if DEBUG_BOSS_KILLER == 1
|
||||
KillBoss();
|
||||
@ -41,13 +43,16 @@ void OnDisplayUpdatePost(IEvent* event) {
|
||||
|
||||
if ((gControllerHold[0].button & Z_TRIG) && (gControllerHold[0].button & R_TRIG) &&
|
||||
(gControllerPress[0].button & U_CBUTTONS)) {
|
||||
gFillScreenAlphaTarget = 255;
|
||||
gFillScreenRed = gFillScreenGreen = gFillScreenBlue = 0;
|
||||
gFillScreenAlphaStep = 8;
|
||||
gShowLevelClearStatusScreen = false;
|
||||
pl->state = PLAYERSTATE_NEXT;
|
||||
pl->csTimer = 0;
|
||||
gFadeoutType = 4;
|
||||
gLevelStartStatusScreenTimer = 0;
|
||||
gStarCount = 0;
|
||||
gGameState = GSTATE_MAP;
|
||||
gNextGameStateTimer = 2;
|
||||
gMapState = 0;
|
||||
gLastGameState = GSTATE_NONE;
|
||||
gDrawMode = DRAW_NONE;
|
||||
gControllerLock = 3;
|
||||
gBackToMap = true;
|
||||
}
|
||||
}
|
||||
|
||||
@ -132,7 +137,6 @@ void OnDisplayUpdatePost(IEvent* event) {
|
||||
return;
|
||||
}
|
||||
gHitCount = CVarGetInteger("gScoreEditValue", 1);
|
||||
|
||||
}
|
||||
Hit64_Main();
|
||||
// ground testing
|
||||
|
Loading…
Reference in New Issue
Block a user