From 38616d90a303ff44ca4b94c820fe5e878141c69c Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Sun, 2 Aug 2020 23:47:21 +0200 Subject: [PATCH] - renamed some members of Blood's EPISODEINFO struct. --- source/blood/src/blood.cpp | 2 +- source/blood/src/credits.cpp | 4 ++-- source/blood/src/levels.cpp | 16 ++++++++-------- source/blood/src/levels.h | 9 ++++----- 4 files changed, 15 insertions(+), 16 deletions(-) diff --git a/source/blood/src/blood.cpp b/source/blood/src/blood.cpp index 51c45ae3f..27b62d196 100644 --- a/source/blood/src/blood.cpp +++ b/source/blood/src/blood.cpp @@ -370,7 +370,7 @@ void StartLevel(GAMEOPTIONS *gameOptions) if (!(gGameOptions.uGameFlags&1)) levelSetupOptions(gGameOptions.nEpisode, gGameOptions.nLevel); if (gEpisodeInfo[gGameOptions.nEpisode].cutALevel == gGameOptions.nLevel - && gEpisodeInfo[gGameOptions.nEpisode].at8f08) + && gEpisodeInfo[gGameOptions.nEpisode].cutsceneAName) gGameOptions.uGameFlags |= 4; /////// diff --git a/source/blood/src/credits.cpp b/source/blood/src/credits.cpp index 983c763c5..9c3ce2fd1 100644 --- a/source/blood/src/credits.cpp +++ b/source/blood/src/credits.cpp @@ -128,7 +128,7 @@ void levelPlayIntroScene(int nEpisode, CompletionFunc completion) ambKillAll(); seqKillAll(); EPISODEINFO *pEpisode = &gEpisodeInfo[nEpisode]; - playSmk(pEpisode->at8f08, pEpisode->at9030, pEpisode->at9028, completion); + playSmk(pEpisode->cutsceneAName, pEpisode->cutsceneASound, pEpisode->at9028, completion); } void levelPlayEndScene(int nEpisode, CompletionFunc completion) @@ -140,7 +140,7 @@ void levelPlayEndScene(int nEpisode, CompletionFunc completion) ambKillAll(); seqKillAll(); EPISODEINFO *pEpisode = &gEpisodeInfo[nEpisode]; - playSmk(pEpisode->at8f98, pEpisode->at90c0, pEpisode->at902c, completion); + playSmk(pEpisode->cutsceneBName, pEpisode->cutsceneBSound, pEpisode->at902c, completion); } diff --git a/source/blood/src/levels.cpp b/source/blood/src/levels.cpp index fd44b74f6..bde36ed3b 100644 --- a/source/blood/src/levels.cpp +++ b/source/blood/src/levels.cpp @@ -206,18 +206,18 @@ void levelLoadDefaults(void) EPISODEINFO *pEpisodeInfo = &gEpisodeInfo[i]; auto ep_str = BloodINI->GetKeyString(buffer, "Title", buffer); gVolumeNames[i] = ep_str; // only keep one table for the names. Todo: Consolidate this across games. - strncpy(pEpisodeInfo->at8f08, BloodINI->GetKeyString(buffer, "CutSceneA", ""), BMAX_PATH); + strncpy(pEpisodeInfo->cutsceneAName, BloodINI->GetKeyString(buffer, "CutSceneA", ""), BMAX_PATH); pEpisodeInfo->at9028 = BloodINI->GetKeyInt(buffer, "CutWavA", -1); if (pEpisodeInfo->at9028 == 0) - strncpy(pEpisodeInfo->at9030, BloodINI->GetKeyString(buffer, "CutWavA", ""), BMAX_PATH); + strncpy(pEpisodeInfo->cutsceneASound, BloodINI->GetKeyString(buffer, "CutWavA", ""), BMAX_PATH); else - pEpisodeInfo->at9030[0] = 0; - strncpy(pEpisodeInfo->at8f98, BloodINI->GetKeyString(buffer, "CutSceneB", ""), BMAX_PATH); + pEpisodeInfo->cutsceneASound[0] = 0; + strncpy(pEpisodeInfo->cutsceneBName, BloodINI->GetKeyString(buffer, "CutSceneB", ""), BMAX_PATH); pEpisodeInfo->at902c = BloodINI->GetKeyInt(buffer, "CutWavB", -1); if (pEpisodeInfo->at902c == 0) - strncpy(pEpisodeInfo->at90c0, BloodINI->GetKeyString(buffer, "CutWavB", ""), BMAX_PATH); + strncpy(pEpisodeInfo->cutsceneBSound, BloodINI->GetKeyString(buffer, "CutWavB", ""), BMAX_PATH); else - pEpisodeInfo->at90c0[0] = 0; + pEpisodeInfo->cutsceneBSound[0] = 0; pEpisodeInfo->bloodbath = BloodINI->GetKeyInt(buffer, "BloodBathOnly", 0); pEpisodeInfo->cutALevel = BloodINI->GetKeyInt(buffer, "CutSceneALevel", 0); @@ -296,7 +296,7 @@ void levelEndLevel(int arg) case 0: if (nEndingA == -1) { - if (pEpisodeInfo->at8f98[0]) + if (pEpisodeInfo->cutsceneBName[0]) gGameOptions.uGameFlags |= 8; gGameOptions.nLevel = 0; gGameOptions.uGameFlags |= 2; @@ -309,7 +309,7 @@ void levelEndLevel(int arg) { if (gGameOptions.nEpisode + 1 < gEpisodeCount) { - if (pEpisodeInfo->at8f98[0]) + if (pEpisodeInfo->cutsceneBName[0]) gGameOptions.uGameFlags |= 8; gGameOptions.nLevel = 0; gGameOptions.uGameFlags |= 2; diff --git a/source/blood/src/levels.h b/source/blood/src/levels.h index e1b00d85e..8000be60d 100644 --- a/source/blood/src/levels.h +++ b/source/blood/src/levels.h @@ -72,17 +72,16 @@ enum { struct EPISODEINFO { - //char at0[32]; removed, so that the global episode name table can be used for consistency int nLevels; unsigned int bloodbath : 1; unsigned int cutALevel : 4; MapRecord* levels; // points into the global table. - char at8f08[BMAX_PATH]; - char at8f98[BMAX_PATH]; + char cutsceneAName[BMAX_PATH]; + char cutsceneBName[BMAX_PATH]; int at9028; int at902c; - char at9030[BMAX_PATH]; - char at90c0[BMAX_PATH]; + char cutsceneASound[BMAX_PATH]; + char cutsceneBSound[BMAX_PATH]; }; extern EPISODEINFO gEpisodeInfo[];