From 8afd2503ebca2344690b7265052d334ded2d34f9 Mon Sep 17 00:00:00 2001 From: Robbbert Date: Thu, 17 Jun 2021 03:03:14 +1000 Subject: [PATCH] rx78: fixed regression when there's no cart in. --- src/mame/drivers/rx78.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/mame/drivers/rx78.cpp b/src/mame/drivers/rx78.cpp index 930d14a32ba..cd1fc360f85 100644 --- a/src/mame/drivers/rx78.cpp +++ b/src/mame/drivers/rx78.cpp @@ -173,9 +173,11 @@ uint32_t rx78_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, laycol[BIT(m_pal_reg[6], j)] |= m_pal_reg[j]; // This fixes text in Space Enemy - for (u8 j = 0; j < 6; j++) - if (BIT(layers, j)) - if (!m_pal_reg[j]) laycol[0] = 0; + if (m_pal_reg[6]) + for (u8 j = 0; j < 6; j++) + if (BIT(layers, j)) + if (!m_pal_reg[j]) + laycol[0] = 0; u8 color = laycol[1] ? laycol[1] : (laycol[0] ? laycol[0] : m_background); bitmap.pix(y+bordery, x+i+borderx) = color;