summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/video/flkatck.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/video/flkatck.c')
-rw-r--r--src/mame/video/flkatck.c32
1 files changed, 15 insertions, 17 deletions
diff --git a/src/mame/video/flkatck.c b/src/mame/video/flkatck.c
index 61cd6c5da02..217d43db55b 100644
--- a/src/mame/video/flkatck.c
+++ b/src/mame/video/flkatck.c
@@ -14,16 +14,15 @@
***************************************************************************/
-static TILE_GET_INFO( get_tile_info_A )
+TILE_GET_INFO_MEMBER(flkatck_state::get_tile_info_A)
{
- flkatck_state *state = machine.driver_data<flkatck_state>();
- UINT8 ctrl_0 = k007121_ctrlram_r(state->m_k007121, 0);
- UINT8 ctrl_2 = k007121_ctrlram_r(state->m_k007121, 2);
- UINT8 ctrl_3 = k007121_ctrlram_r(state->m_k007121, 3);
- UINT8 ctrl_4 = k007121_ctrlram_r(state->m_k007121, 4);
- UINT8 ctrl_5 = k007121_ctrlram_r(state->m_k007121, 5);
- int attr = state->m_k007121_ram[tile_index];
- int code = state->m_k007121_ram[tile_index + 0x400];
+ UINT8 ctrl_0 = k007121_ctrlram_r(m_k007121, 0);
+ UINT8 ctrl_2 = k007121_ctrlram_r(m_k007121, 2);
+ UINT8 ctrl_3 = k007121_ctrlram_r(m_k007121, 3);
+ UINT8 ctrl_4 = k007121_ctrlram_r(m_k007121, 4);
+ UINT8 ctrl_5 = k007121_ctrlram_r(m_k007121, 5);
+ int attr = m_k007121_ram[tile_index];
+ int code = m_k007121_ram[tile_index + 0x400];
int bit0 = (ctrl_5 >> 0) & 0x03;
int bit1 = (ctrl_5 >> 2) & 0x03;
int bit2 = (ctrl_5 >> 4) & 0x03;
@@ -42,20 +41,19 @@ static TILE_GET_INFO( get_tile_info_A )
bank = 0; /* this allows the game to print text
in all banks selected by the k007121 */
- SET_TILE_INFO(
+ SET_TILE_INFO_MEMBER(
0,
code + 256*bank,
(attr & 0x0f) + 16,
(attr & 0x20) ? TILE_FLIPY : 0);
}
-static TILE_GET_INFO( get_tile_info_B )
+TILE_GET_INFO_MEMBER(flkatck_state::get_tile_info_B)
{
- flkatck_state *state = machine.driver_data<flkatck_state>();
- int attr = state->m_k007121_ram[tile_index + 0x800];
- int code = state->m_k007121_ram[tile_index + 0xc00];
+ int attr = m_k007121_ram[tile_index + 0x800];
+ int code = m_k007121_ram[tile_index + 0xc00];
- SET_TILE_INFO(
+ SET_TILE_INFO_MEMBER(
0,
code,
(attr & 0x0f) + 16,
@@ -72,8 +70,8 @@ static TILE_GET_INFO( get_tile_info_B )
VIDEO_START( flkatck )
{
flkatck_state *state = machine.driver_data<flkatck_state>();
- state->m_k007121_tilemap[0] = tilemap_create(machine, get_tile_info_A, TILEMAP_SCAN_ROWS, 8, 8, 32, 32);
- state->m_k007121_tilemap[1] = tilemap_create(machine, get_tile_info_B, TILEMAP_SCAN_ROWS, 8, 8, 32, 32);
+ state->m_k007121_tilemap[0] = &machine.tilemap().create(tilemap_get_info_delegate(FUNC(flkatck_state::get_tile_info_A),state), TILEMAP_SCAN_ROWS, 8, 8, 32, 32);
+ state->m_k007121_tilemap[1] = &machine.tilemap().create(tilemap_get_info_delegate(FUNC(flkatck_state::get_tile_info_B),state), TILEMAP_SCAN_ROWS, 8, 8, 32, 32);
}