diff --git a/sc2/content/starcon.lst b/sc2/content/starcon.lst index 14f4df564..96ff6aa1c 100644 --- a/sc2/content/starcon.lst +++ b/sc2/content/starcon.lst @@ -461,3 +461,5 @@ 283 284 2 slides/ending/sis_skel.ani 284 285 2 ipanims/orbenter.ani 285 286 2 lbm/setupmenu.ani +286 98 4 slides/intro/intro.txt +287 99 4 slides/ending/ending.txt diff --git a/sc2/src/sc2code/fmv.c b/sc2/src/sc2code/fmv.c index 3bae67b1f..e7ce16041 100644 --- a/sc2/src/sc2code/fmv.c +++ b/sc2/src/sc2code/fmv.c @@ -23,6 +23,7 @@ #include "options.h" #include "master.h" #include "resinst.h" +#include "nameref.h" #include "settings.h" #include "setup.h" #include "vidlib.h" @@ -141,7 +142,8 @@ Introduction (void) * not present */ if (optWhichIntro == OPT_PC || !DoFMV ("slides/intro/intro.duk", NULL, TRUE)) - ShowPresentation ("slides/intro/intro.txt"); + ShowPresentation ( CaptureStringTable ( + LoadStringTable (INTROPRES_STRTAB))); } } @@ -157,7 +159,8 @@ Victory (void) * not present */ if (optWhichIntro == OPT_PC || !DoFMV ("slides/ending/victory.duk", NULL, TRUE)) - ShowPresentation ("slides/ending/ending.txt"); + ShowPresentation ( CaptureStringTable ( + LoadStringTable (FINALPRES_STRTAB))); xform_buf[0] = FadeAllToBlack; XFormColorMap ((COLORMAPPTR)xform_buf, 0); diff --git a/sc2/src/sc2code/fmv.h b/sc2/src/sc2code/fmv.h index b206af05a..ed9db39cc 100644 --- a/sc2/src/sc2code/fmv.h +++ b/sc2/src/sc2code/fmv.h @@ -29,7 +29,7 @@ extern void DoShipSpin (COUNT index, MUSIC_REF hMusic); extern BOOLEAN DoFMV (const char *name, const char *loopname, BOOLEAN uninit); -extern BOOLEAN ShowPresentation (const char *name); +extern BOOLEAN ShowPresentation (STRING PresStr); #endif /* _FMV_H */ diff --git a/sc2/src/sc2code/intro.c b/sc2/src/sc2code/intro.c index 7064fcf06..4c7380c55 100644 --- a/sc2/src/sc2code/intro.c +++ b/sc2/src/sc2code/intro.c @@ -271,6 +271,13 @@ Present_GenerateSIS (PRESENTATION_INPUT_STATE* pPIS) pPIS->SisFrame = SisFrame; } +BOOLEAN +ShowPresentationFile (const char *name) +{ + return ShowPresentation (CaptureStringTable ( + LoadStringTableFile (contentDir, name))); +} + static BOOLEAN DoPresentation (PVOID pIS) { @@ -668,7 +675,7 @@ DoPresentation (PVOID pIS) Present_UnbatchGraphics (pPIS, TRUE); CopyTextString (pPIS->Buffer, sizeof(pPIS->Buffer), pStr); - ShowPresentation (pPIS->Buffer); + ShowPresentationFile (pPIS->Buffer); } else if (strcmp (Opcode, "NOOP") == 0) { /* no operation - must be a comment in script */ @@ -680,7 +687,7 @@ DoPresentation (PVOID pIS) } BOOLEAN -ShowPresentation (const char *name) +ShowPresentation (STRING PresStr) { CONTEXT OldContext; FONT OldFont; @@ -688,8 +695,7 @@ ShowPresentation (const char *name) PRESENTATION_INPUT_STATE pis; RECT r = {{0, 0}, {SCREEN_WIDTH, SCREEN_HEIGHT}}; - pis.SlideShow = CaptureStringTable ( - LoadStringTableFile (contentDir, name)); + pis.SlideShow = PresStr; if (!pis.SlideShow) return FALSE; pis.SlideShow = SetAbsStringTableIndex (pis.SlideShow, 0); diff --git a/sc2/src/sc2code/istrtab.h b/sc2/src/sc2code/istrtab.h index 585135421..039cb3293 100644 --- a/sc2/src/sc2code/istrtab.h +++ b/sc2/src/sc2code/istrtab.h @@ -97,4 +97,6 @@ #define IPSUN_COLOR_MAP 0x05206004L #define HANGAR_COLOR_TAB 0x18a06104L +#define INTROPRES_STRTAB 0x23c06204L +#define FINALPRES_STRTAB 0x23e06304L diff --git a/sc2/src/sc2code/respkg.h b/sc2/src/sc2code/respkg.h index da4249789..e165cc76a 100644 --- a/sc2/src/sc2code/respkg.h +++ b/sc2/src/sc2code/respkg.h @@ -303,5 +303,7 @@ enum SISSKEL_PACKAGE, ORBENTER_PACKAGE, MENUBKG_PACKAGE, + INTRO_PACKAGE, + FINAL_PACKAGE, };