diff options
Diffstat (limited to 'src/code')
| -rw-r--r-- | src/code/z_play.c | 8 | ||||
| -rw-r--r-- | src/code/z_scene_table.c | 11 |
2 files changed, 11 insertions, 8 deletions
diff --git a/src/code/z_play.c b/src/code/z_play.c index dd8c42466..ca13477ea 100644 --- a/src/code/z_play.c +++ b/src/code/z_play.c @@ -349,9 +349,8 @@ void Play_Init(GameState* thisx) { if (gSaveContext.gameMode != 1) { if (gSaveContext.nextTransitionType == TRANS_NEXT_TYPE_DEFAULT) { - // fade in - this->transitionType = - (gEntranceTable[((void)0, gSaveContext.entranceIndex) + tempSetupIndex].field >> 7) & 0x7F; + this->transitionType = ENTRANCE_INFO_END_TRANS_TYPE( + gEntranceTable[((void)0, gSaveContext.entranceIndex) + tempSetupIndex].field); } else { this->transitionType = gSaveContext.nextTransitionType; gSaveContext.nextTransitionType = TRANS_NEXT_TYPE_DEFAULT; @@ -490,7 +489,8 @@ void Play_Update(PlayState* this) { } // fade out bgm if "continue bgm" flag is not set - if (!(gEntranceTable[this->nextEntranceIndex + sceneSetupIndex].field & 0x8000)) { + if (!(gEntranceTable[this->nextEntranceIndex + sceneSetupIndex].field & + ENTRANCE_INFO_CONTINUE_BGM_FLAG)) { // "Sound initalized. 111" osSyncPrintf("\n\n\nサウンドイニシャル来ました。111"); if ((this->transitionType < TRANS_TYPE_MAX) && !Environment_IsForcedSequenceDisabled()) { diff --git a/src/code/z_scene_table.c b/src/code/z_scene_table.c index 1477c6d5f..91fc9d360 100644 --- a/src/code/z_scene_table.c +++ b/src/code/z_scene_table.c @@ -24,9 +24,12 @@ #include "overlays/actors/ovl_Bg_Dodoago/z_bg_dodoago.h" // Entrance Table definition -#define DEFINE_ENTRANCE(_0, scene, spawn, continueBgm, displayTitleCard, fadeIn, fadeOut) \ - { scene, spawn, \ - ((continueBgm & 1) << 15) | ((displayTitleCard & 1) << 14) | ((fadeIn & 0x7F) << 7) | (fadeOut & 0x7F) }, +#define DEFINE_ENTRANCE(_0, scene, spawn, continueBgm, displayTitleCard, endTransType, startTransType) \ + { scene, spawn, \ + (((continueBgm) ? ENTRANCE_INFO_CONTINUE_BGM_FLAG : 0) | \ + ((displayTitleCard) ? ENTRANCE_INFO_DISPLAY_TITLE_CARD_FLAG : 0) | \ + (((endTransType) << ENTRANCE_INFO_END_TRANS_TYPE_SHIFT) & ENTRANCE_INFO_END_TRANS_TYPE_MASK) | \ + (((startTransType) << ENTRANCE_INFO_START_TRANS_TYPE_SHIFT) & ENTRANCE_INFO_START_TRANS_TYPE_MASK)) }, EntranceInfo gEntranceTable[] = { #include "tables/entrance_table.h" @@ -90,7 +93,7 @@ void Scene_SetTransitionForNextEntrance(PlayState* play) { } } - play->transitionType = gEntranceTable[entranceIndex].field & 0x7F; // Fade out + play->transitionType = ENTRANCE_INFO_START_TRANS_TYPE(gEntranceTable[entranceIndex].field); } void Scene_DrawConfigDefault(PlayState* play) { |
