summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/drivers/acefruit.c
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2012-09-17 15:00:31 +0000
committer Miodrag Milanovic <mmicko@gmail.com>2012-09-17 15:00:31 +0000
commit5ddbca3e7a2327786fd92cc7443dd84257ba889a (patch)
treef6eb4b827714a8658ea246336342b03d6d7938e0 /src/mame/drivers/acefruit.c
parentf27b07d0822f4ff52b95a1a0143f3c2313ea02ce (diff)
Modernized screen update calls (no whatsnew)
Diffstat (limited to 'src/mame/drivers/acefruit.c')
-rw-r--r--src/mame/drivers/acefruit.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mame/drivers/acefruit.c b/src/mame/drivers/acefruit.c
index 8100daef70b..e65674e952b 100644
--- a/src/mame/drivers/acefruit.c
+++ b/src/mame/drivers/acefruit.c
@@ -39,6 +39,7 @@ public:
DECLARE_DRIVER_INIT(sidewndr);
virtual void video_start();
virtual void palette_init();
+ UINT32 screen_update_acefruit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
};
@@ -89,9 +90,8 @@ static INTERRUPT_GEN( acefruit_vblank )
state->m_refresh_timer->adjust( attotime::zero );
}
-static SCREEN_UPDATE_IND16( acefruit )
+UINT32 acefruit_state::screen_update_acefruit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
- acefruit_state *state = screen.machine().driver_data<acefruit_state>();
int startrow = cliprect.min_y / 8;
int endrow = cliprect.max_y / 8;
int row;
@@ -106,8 +106,8 @@ static SCREEN_UPDATE_IND16( acefruit )
for( col = 0; col < 32; col++ )
{
int tile_index = ( col * 32 ) + row;
- int code = state->m_videoram[ tile_index ];
- int color = state->m_colorram[ tile_index ];
+ int code = m_videoram[ tile_index ];
+ int color = m_colorram[ tile_index ];
if( color < 0x4 )
{
@@ -123,7 +123,7 @@ static SCREEN_UPDATE_IND16( acefruit )
for( x = 0; x < 16; x++ )
{
- int sprite = ( state->m_spriteram[ ( spriteindex / 64 ) % 6 ] & 0xf ) ^ 0xf;
+ int sprite = ( m_spriteram[ ( spriteindex / 64 ) % 6 ] & 0xf ) ^ 0xf;
const UINT8 *gfxdata = gfx->get_data(sprite);
for( y = 0; y < 8; y++ )
@@ -592,7 +592,7 @@ static MACHINE_CONFIG_START( acefruit, acefruit_state )
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500) /* not accurate */)
MCFG_SCREEN_SIZE(512, 256)
MCFG_SCREEN_VISIBLE_AREA(0, 511, 0, 255)
- MCFG_SCREEN_UPDATE_STATIC(acefruit)
+ MCFG_SCREEN_UPDATE_DRIVER(acefruit_state, screen_update_acefruit)
MCFG_PALETTE_LENGTH(16)