diff --git a/agi.c b/agi.c index b0a9fce..53bc38d 100644 --- a/agi.c +++ b/agi.c @@ -149,7 +149,7 @@ static void updateEgoFromInput(void); static AgiGameT gGame; static AgiPicT gPic; static jlSurfaceT *gBackdrop; -static jlSurfaceT *gStage; +static jlSurfaceT *gAgiStage; static AgiVmT gVm; static LogicCacheSlotT gLogicCache[AGI_MAX_RESOURCES]; // View cache: 256 slots of ~5 KB each (~1.3 MB). Far too large for the @@ -546,7 +546,7 @@ static void cbOverlayPic(void *ctx, uint8_t picId) { static void cbShowPic(void *ctx) { (void)ctx; jlLogF("cbShowPic v11=%u", (unsigned)gVm.vars[11]); - if (gStage == NULL) { + if (gAgiStage == NULL) { return; } // Clear the WHOLE stage first so the rows above/below the AGI @@ -556,10 +556,10 @@ static void cbShowPic(void *ctx) { // copy below and gets restored over every subsequent frame -- // so clear.lines never visually erases anything that sat in // the border bands. - jlSurfaceClear(gStage, COLOR_MISSING); - agiPicBlit(&gPic, gStage, PIC_DEST_Y); + jlSurfaceClear(gAgiStage, COLOR_MISSING); + agiPicBlit(&gPic, gAgiStage, PIC_DEST_Y); if (gBackdrop != NULL) { - jlSurfaceCopy(gBackdrop, gStage); + jlSurfaceCopy(gBackdrop, gAgiStage); } gPicReady = true; // The stage just got repainted; any prior save-under refers to @@ -1716,8 +1716,8 @@ int main(int argc, char **argv) { jlLogReset(); jlLogF("AGI TRACE build=%s %s", __DATE__, __TIME__); jlLogFlush(); - gStage = jlStageGet(); - jlPaletteSet(gStage, 0u, kAgiPalette); + gAgiStage = jlStageGet(); + jlPaletteSet(gAgiStage, 0u, kAgiPalette); jlRandomSeed(0xA61DA61Du); // Bring up the SB DMA + mixer. AGI music feeds the SFX stream @@ -1786,7 +1786,7 @@ int main(int argc, char **argv) { } } - jlSurfaceClear(gStage, COLOR_MISSING); + jlSurfaceClear(gAgiStage, COLOR_MISSING); if (gBackdrop != NULL) { jlSurfaceClear(gBackdrop, COLOR_MISSING); } @@ -1852,7 +1852,7 @@ int main(int argc, char **argv) { { uint32_t nowMs2 = jlMillisElapsed(); if (nowMs2 - lastRenderMs >= AGI_RENDER_PERIOD_MS) { - renderFrame(gStage); + renderFrame(gAgiStage); lastRenderMs = nowMs2; } else { jlStagePresent();