trunk/src/mame/includes/namcoic.h
| r17663 | r17664 | |
| 88 | 88 | |
| 89 | 89 | /***********************************************************************************/ |
| 90 | 90 | |
| 91 | #pragma once |
| 92 | |
| 93 | #ifndef __NAMCOIC_H__ |
| 94 | #define __NAMCOIC_H__ |
| 95 | |
| 96 | |
| 97 | //************************************************************************** |
| 98 | // INTERFACE CONFIGURATION MACROS |
| 99 | //************************************************************************** |
| 100 | |
| 101 | #define MCFG_NAMCO_C45_ROAD_ADD(_tag) \ |
| 102 | MCFG_DEVICE_ADD(_tag, NAMCO_C45_ROAD, 0) \ |
| 103 | |
| 104 | |
| 105 | |
| 106 | //************************************************************************** |
| 107 | // TYPE DEFINITIONS |
| 108 | //************************************************************************** |
| 109 | |
| 110 | |
| 111 | // ======================> namco_c45_road_device |
| 112 | |
| 113 | class namco_c45_road_device : public device_t |
| 114 | { |
| 115 | // constants |
| 116 | static const int ROAD_COLS = 64; |
| 117 | static const int ROAD_ROWS = 512; |
| 118 | static const int ROAD_TILE_SIZE = 16; |
| 119 | static const int ROAD_TILEMAP_WIDTH = ROAD_TILE_SIZE * ROAD_COLS; |
| 120 | static const int ROAD_TILEMAP_HEIGHT = ROAD_TILE_SIZE * ROAD_ROWS; |
| 121 | static const int ROAD_TILE_COUNT_MAX = 0xfa00 / 0x40; // 0x3e8 |
| 122 | static const int WORDS_PER_ROAD_TILE = 0x40/2; |
| 123 | |
| 124 | public: |
| 125 | // construction/destruction |
| 126 | namco_c45_road_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 127 | |
| 128 | // read/write handlers |
| 129 | DECLARE_READ16_MEMBER( read ); |
| 130 | DECLARE_WRITE16_MEMBER( write ); |
| 131 | |
| 132 | // C45 Land (Road) Emulation |
| 133 | void set_transparent_color(pen_t pen) { m_transparent_color = pen; } |
| 134 | void draw(bitmap_ind16 &bitmap, const rectangle &cliprect, int pri); |
| 135 | |
| 136 | protected: |
| 137 | // device-level overrides |
| 138 | virtual void device_start(); |
| 139 | virtual void device_stop(); |
| 140 | |
| 141 | // internal helpers |
| 142 | TILE_GET_INFO_MEMBER( get_road_info ); |
| 143 | |
| 144 | // internal state |
| 145 | pen_t m_transparent_color; |
| 146 | gfx_element * m_gfx; |
| 147 | tilemap_t * m_tilemap; |
| 148 | UINT16 m_ram[0x20000/2]; // at 0x880000 in Final Lap; at 0xa00000 in Lucky&Wild |
| 149 | |
| 150 | static const gfx_layout s_tile_layout; |
| 151 | }; |
| 152 | |
| 153 | |
| 154 | // device type definition |
| 155 | extern const device_type NAMCO_C45_ROAD; |
| 156 | |
| 157 | |
| 158 | |
| 91 | 159 | /*----------- defined in drivers/namcoic.c -----------*/ |
| 92 | 160 | |
| 93 | 161 | void namco_tilemap_init( |
| r17663 | r17664 | |
| 112 | 180 | |
| 113 | 181 | /***********************************************************************************/ |
| 114 | 182 | |
| 115 | | /***********************************************************************************/ |
| 116 | | /* C45 Land (Road) Emulation */ |
| 117 | | |
| 118 | | void namco_road_init( running_machine &machine, int gfxbank ); |
| 119 | | void namco_road_set_transparent_color(pen_t pen); |
| 120 | | void namco_road_draw( running_machine &machine, bitmap_ind16 &bitmap, const rectangle &cliprect, int pri ); |
| 121 | | |
| 122 | | READ16_HANDLER( namco_road16_r ); |
| 123 | | WRITE16_HANDLER( namco_road16_w ); |
| 124 | | |
| 125 | | /***********************************************************************************/ |
| 183 | #endif |
trunk/src/mame/drivers/namcoic.c
| r17663 | r17664 | |
| 2 | 2 | #include "includes/namcos2.h" /* for game-specific hacks */ |
| 3 | 3 | #include "includes/namcoic.h" |
| 4 | 4 | |
| 5 | |
| 6 | //**************************************************************************** |
| 7 | // CONSTANTS |
| 8 | //**************************************************************************** |
| 9 | |
| 10 | // device type definition |
| 11 | const device_type NAMCO_C45_ROAD = &device_creator<namco_c45_road_device>; |
| 12 | |
| 13 | |
| 5 | 14 | /**************************************************************************************/ |
| 6 | 15 | static struct |
| 7 | 16 | { |
| r17663 | r17664 | |
| 1278 | 1287 | * 0x1fe00..0x1ffdf ---- --xx xxxx xxxx zoomx |
| 1279 | 1288 | * 0x1fffd always 0xffff 0xffff? |
| 1280 | 1289 | */ |
| 1281 | | static UINT16 *mpRoadRAM; /* at 0x880000 in Final Lap; at 0xa00000 in Lucky&Wild */ |
| 1282 | | static int mRoadGfxBank; |
| 1283 | | static tilemap_t *mpRoadTilemap; |
| 1284 | | static pen_t mRoadTransparentColor; |
| 1285 | | static int mbRoadNeedTransparent; |
| 1286 | 1290 | |
| 1287 | | #define ROAD_COLS 64 |
| 1288 | | #define ROAD_ROWS 512 |
| 1289 | | #define ROAD_TILE_SIZE 16 |
| 1290 | | #define ROAD_TILEMAP_WIDTH (ROAD_TILE_SIZE*ROAD_COLS) |
| 1291 | | #define ROAD_TILEMAP_HEIGHT (ROAD_TILE_SIZE*ROAD_ROWS) |
| 1292 | | |
| 1293 | | #define ROAD_TILE_COUNT_MAX (0xfa00/0x40) /* 0x3e8 */ |
| 1294 | | #define WORDS_PER_ROAD_TILE (0x40/2) |
| 1295 | | |
| 1296 | | static const gfx_layout RoadTileLayout = |
| 1291 | const gfx_layout namco_c45_road_device::s_tile_layout = |
| 1297 | 1292 | { |
| 1298 | 1293 | ROAD_TILE_SIZE, ROAD_TILE_SIZE, |
| 1299 | 1294 | ROAD_TILE_COUNT_MAX, |
| 1300 | 1295 | 2, |
| 1301 | 1296 | { NATIVE_ENDIAN_VALUE_LE_BE(8,0), NATIVE_ENDIAN_VALUE_LE_BE(0,8) }, |
| 1302 | | {/* x offset */ |
| 1297 | {// x offset |
| 1303 | 1298 | 0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07, |
| 1304 | 1299 | 0x10,0x11,0x12,0x13,0x14,0x15,0x16,0x17 |
| 1305 | 1300 | }, |
| 1306 | | {/* y offset */ |
| 1301 | {// y offset |
| 1307 | 1302 | 0x000,0x020,0x040,0x060,0x080,0x0a0,0x0c0,0x0e0, |
| 1308 | 1303 | 0x100,0x120,0x140,0x160,0x180,0x1a0,0x1c0,0x1e0 |
| 1309 | 1304 | }, |
| 1310 | | 0x200, /* offset to next tile */ |
| 1305 | 0x200 // offset to next tile |
| 1311 | 1306 | }; |
| 1312 | 1307 | |
| 1313 | | static TILE_GET_INFO( get_road_info ) |
| 1308 | //------------------------------------------------- |
| 1309 | // namco_c45_road_device -- constructor |
| 1310 | //------------------------------------------------- |
| 1311 | |
| 1312 | namco_c45_road_device::namco_c45_road_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) |
| 1313 | : device_t(mconfig, NAMCO_C45_ROAD, "Namco C45 Road", tag, owner, clock), |
| 1314 | m_transparent_color(~0), |
| 1315 | m_gfx(NULL), |
| 1316 | m_tilemap(NULL) |
| 1314 | 1317 | { |
| 1315 | | UINT16 data = mpRoadRAM[tile_index]; |
| 1316 | | /* ------xx xxxxxxxx tile number |
| 1317 | | * xxxxxx-- -------- palette select |
| 1318 | | */ |
| 1319 | | int tile = (data&0x3ff); |
| 1320 | | int color = (data>>10); |
| 1318 | } |
| 1321 | 1319 | |
| 1322 | | SET_TILE_INFO( mRoadGfxBank, tile, color , 0 ); |
| 1323 | | } /* get_road_info */ |
| 1324 | 1320 | |
| 1325 | | READ16_HANDLER( namco_road16_r ) |
| 1321 | //------------------------------------------------- |
| 1322 | // read -- read from RAM |
| 1323 | //------------------------------------------------- |
| 1324 | |
| 1325 | READ16_MEMBER( namco_c45_road_device::read ) |
| 1326 | 1326 | { |
| 1327 | | return mpRoadRAM[offset]; |
| 1327 | return m_ram[offset]; |
| 1328 | 1328 | } |
| 1329 | 1329 | |
| 1330 | | WRITE16_HANDLER( namco_road16_w ) |
| 1330 | |
| 1331 | //------------------------------------------------- |
| 1332 | // write -- write to RAM |
| 1333 | //------------------------------------------------- |
| 1334 | |
| 1335 | WRITE16_MEMBER( namco_c45_road_device::write ) |
| 1331 | 1336 | { |
| 1332 | | COMBINE_DATA( &mpRoadRAM[offset] ); |
| 1333 | | if( offset<0x10000/2 ) |
| 1334 | | { |
| 1335 | | mpRoadTilemap->mark_tile_dirty( offset ); |
| 1336 | | } |
| 1337 | COMBINE_DATA(&m_ram[offset]); |
| 1338 | |
| 1339 | // first half maps to the tilemap |
| 1340 | if (offset < 0x10000/2) |
| 1341 | m_tilemap->mark_tile_dirty(offset); |
| 1342 | |
| 1343 | // second half maps to the gfx elements |
| 1337 | 1344 | else |
| 1338 | 1345 | { |
| 1339 | 1346 | offset -= 0x10000/2; |
| 1340 | | gfx_element_mark_dirty(space->machine().gfx[mRoadGfxBank], offset/WORDS_PER_ROAD_TILE); |
| 1347 | gfx_element_mark_dirty(m_gfx, offset / WORDS_PER_ROAD_TILE); |
| 1341 | 1348 | } |
| 1342 | 1349 | } |
| 1343 | 1350 | |
| 1344 | | void |
| 1345 | | namco_road_init(running_machine &machine, int gfxbank ) |
| 1351 | |
| 1352 | //------------------------------------------------- |
| 1353 | // draw -- render to the target bitmap |
| 1354 | //------------------------------------------------- |
| 1355 | |
| 1356 | void namco_c45_road_device::draw(bitmap_ind16 &bitmap, const rectangle &cliprect, int pri) |
| 1346 | 1357 | { |
| 1347 | | gfx_element *pGfx; |
| 1358 | const UINT8 *clut = (const UINT8 *)memregion("clut")->base(); |
| 1359 | bitmap_ind16 &source_bitmap = m_tilemap->pixmap(); |
| 1360 | unsigned yscroll = m_ram[0x1fdfe/2]; |
| 1348 | 1361 | |
| 1349 | | mbRoadNeedTransparent = 0; |
| 1350 | | mRoadGfxBank = gfxbank; |
| 1362 | // loop over scanlines |
| 1363 | for (int y = cliprect.min_y; y <= cliprect.max_y; y++) |
| 1364 | { |
| 1365 | // skip if we are not the right priority |
| 1366 | int screenx = m_ram[0x1fa00/2 + y + 15]; |
| 1367 | if (pri != ((screenx & 0xf000) >> 12)) |
| 1368 | continue; |
| 1351 | 1369 | |
| 1352 | | mpRoadRAM = auto_alloc_array(machine, UINT16, 0x20000/2); |
| 1370 | // skip if we don't have a valid zoom factor |
| 1371 | unsigned zoomx = m_ram[0x1fe00/2 + y + 15] & 0x3ff; |
| 1372 | if (zoomx == 0) |
| 1373 | continue; |
| 1353 | 1374 | |
| 1354 | | pGfx = gfx_element_alloc( machine, &RoadTileLayout, 0x10000+(UINT8 *)mpRoadRAM, 0x3f, 0xf00); |
| 1375 | // skip if we don't have a valid source increment |
| 1376 | unsigned sourcey = m_ram[0x1fc00/2 + y + 15] + yscroll; |
| 1377 | const UINT16 *source_gfx = &source_bitmap.pix(sourcey & (ROAD_TILEMAP_HEIGHT - 1)); |
| 1378 | unsigned dsourcex = (ROAD_TILEMAP_WIDTH << 16) / zoomx; |
| 1379 | if (dsourcex == 0) |
| 1380 | continue; |
| 1355 | 1381 | |
| 1356 | | machine.gfx[gfxbank] = pGfx; |
| 1357 | | mpRoadTilemap = tilemap_create(machine, |
| 1358 | | get_road_info,TILEMAP_SCAN_ROWS, |
| 1359 | | ROAD_TILE_SIZE,ROAD_TILE_SIZE, |
| 1360 | | ROAD_COLS,ROAD_ROWS); |
| 1382 | // mask off priority bits and sign-extend |
| 1383 | screenx &= 0x0fff; |
| 1384 | if (screenx & 0x0800) |
| 1385 | screenx |= ~0x7ff; |
| 1361 | 1386 | |
| 1362 | | state_save_register_global_pointer(machine, mpRoadRAM, 0x20000 / 2); |
| 1363 | | } /* namco_road_init */ |
| 1387 | // adjust the horizontal placement |
| 1388 | screenx -= 64; // needs adjustment to left |
| 1364 | 1389 | |
| 1365 | | void |
| 1366 | | namco_road_set_transparent_color(pen_t pen) |
| 1367 | | { |
| 1368 | | mbRoadNeedTransparent = 1; |
| 1369 | | mRoadTransparentColor = pen; |
| 1370 | | } |
| 1390 | int numpixels = (44 * ROAD_TILE_SIZE << 16) / dsourcex; |
| 1391 | unsigned sourcex = 0; |
| 1392 | |
| 1393 | // crop left |
| 1394 | int clip_pixels = cliprect.min_x - screenx; |
| 1395 | if (clip_pixels > 0) |
| 1396 | { |
| 1397 | numpixels -= clip_pixels; |
| 1398 | sourcex += dsourcex*clip_pixels; |
| 1399 | screenx = cliprect.min_x; |
| 1400 | } |
| 1371 | 1401 | |
| 1372 | | void |
| 1373 | | namco_road_draw(running_machine &machine, bitmap_ind16 &bitmap, const rectangle &cliprect, int pri ) |
| 1374 | | { |
| 1375 | | const UINT8 *clut = (const UINT8 *)machine.root_device().memregion("user3")->base(); |
| 1376 | | unsigned yscroll; |
| 1377 | | int i; |
| 1402 | // crop right |
| 1403 | clip_pixels = (screenx + numpixels) - (cliprect.max_x + 1); |
| 1404 | if (clip_pixels > 0) |
| 1405 | numpixels -= clip_pixels; |
| 1378 | 1406 | |
| 1379 | | bitmap_ind16 &SourceBitmap = mpRoadTilemap->pixmap(); |
| 1380 | | yscroll = mpRoadRAM[0x1fdfe/2]; |
| 1407 | // TBA: work out palette mapping for Final Lap, Suzuka |
| 1381 | 1408 | |
| 1382 | | for( i=cliprect.min_y; i<=cliprect.max_y; i++ ) |
| 1383 | | { |
| 1384 | | int screenx = mpRoadRAM[0x1fa00/2+i+15]; |
| 1385 | | if( pri == ((screenx&0xf000)>>12) ) |
| 1409 | // BUT: support transparent color for Thunder Ceptor |
| 1410 | UINT16 *dest = &bitmap.pix(y); |
| 1411 | if (m_transparent_color != ~0) |
| 1386 | 1412 | { |
| 1387 | | unsigned zoomx = mpRoadRAM[0x1fe00/2+i+15]&0x3ff; |
| 1388 | | if( zoomx ) |
| 1413 | while (numpixels-- > 0) |
| 1389 | 1414 | { |
| 1390 | | unsigned sourcey = mpRoadRAM[0x1fc00/2+i+15]+yscroll; |
| 1391 | | const UINT16 *pSourceGfx = &SourceBitmap.pix16(sourcey&(ROAD_TILEMAP_HEIGHT-1)); |
| 1392 | | unsigned dsourcex = (ROAD_TILEMAP_WIDTH<<16)/zoomx; |
| 1393 | | if( dsourcex ) |
| 1415 | int pen = source_gfx[sourcex >> 16]; |
| 1416 | if (colortable_entry_get_value(machine().colortable, pen) != m_transparent_color) |
| 1394 | 1417 | { |
| 1395 | | UINT16 *pDest = &bitmap.pix16(i); |
| 1396 | | unsigned sourcex = 0; |
| 1397 | | int numpixels = (44*ROAD_TILE_SIZE<<16)/dsourcex; |
| 1398 | | int clipPixels; |
| 1418 | if (clut != NULL) |
| 1419 | pen = (pen & ~0xff) | clut[pen & 0xff]; |
| 1420 | dest[screenx] = pen; |
| 1421 | } |
| 1422 | screenx++; |
| 1423 | sourcex += dsourcex; |
| 1424 | } |
| 1425 | } |
| 1426 | else |
| 1427 | { |
| 1428 | while (numpixels-- > 0) |
| 1429 | { |
| 1430 | int pen = source_gfx[sourcex >> 16]; |
| 1431 | if (clut != NULL) |
| 1432 | pen = (pen & ~0xff) | clut[pen & 0xff]; |
| 1433 | dest[screenx++] = pen; |
| 1434 | sourcex += dsourcex; |
| 1435 | } |
| 1436 | } |
| 1437 | } |
| 1438 | } |
| 1399 | 1439 | |
| 1400 | | screenx &= 0x0fff; /* mask off priority bits */ |
| 1401 | | if( screenx&0x0800 ) |
| 1402 | | { |
| 1403 | | /* sign extend */ |
| 1404 | | screenx |= ~0x7ff; |
| 1405 | | } |
| 1406 | 1440 | |
| 1407 | | /* adjust the horizontal placement */ |
| 1408 | | screenx -= 64; /*needs adjustment to left*/ |
| 1441 | //------------------------------------------------- |
| 1442 | // device_start -- device startup |
| 1443 | //------------------------------------------------- |
| 1409 | 1444 | |
| 1410 | | clipPixels = cliprect.min_x - screenx; |
| 1411 | | if( clipPixels>0 ) |
| 1412 | | { /* crop left */ |
| 1413 | | numpixels -= clipPixels; |
| 1414 | | sourcex += dsourcex*clipPixels; |
| 1415 | | screenx = cliprect.min_x; |
| 1416 | | } |
| 1445 | void namco_c45_road_device::device_start() |
| 1446 | { |
| 1447 | // create a gfx_element describing the road graphics |
| 1448 | m_gfx = gfx_element_alloc(machine(), &s_tile_layout, 0x10000 + (UINT8 *)&m_ram[0], 0x3f, 0xf00); |
| 1417 | 1449 | |
| 1418 | | clipPixels = (screenx+numpixels) - (cliprect.max_x+1); |
| 1419 | | if( clipPixels>0 ) |
| 1420 | | { /* crop right */ |
| 1421 | | numpixels -= clipPixels; |
| 1422 | | } |
| 1450 | // create a tilemap for the road |
| 1451 | m_tilemap = &machine().tilemap().create(tilemap_get_info_delegate(FUNC(namco_c45_road_device::get_road_info), this), |
| 1452 | TILEMAP_SCAN_ROWS, ROAD_TILE_SIZE, ROAD_TILE_SIZE, ROAD_COLS, ROAD_ROWS); |
| 1453 | } |
| 1423 | 1454 | |
| 1424 | | /* TBA: work out palette mapping for Final Lap, Suzuka */ |
| 1425 | 1455 | |
| 1426 | | /* BUT: support transparent color for Thunder Ceptor */ |
| 1427 | | if( mbRoadNeedTransparent ) |
| 1428 | | { |
| 1429 | | while( numpixels-- > 0 ) |
| 1430 | | { |
| 1431 | | int pen = pSourceGfx[sourcex>>16]; |
| 1456 | //------------------------------------------------- |
| 1457 | // device_stop -- device shutdown |
| 1458 | //------------------------------------------------- |
| 1432 | 1459 | |
| 1433 | | if(colortable_entry_get_value(machine.colortable, pen) != mRoadTransparentColor) |
| 1434 | | { |
| 1435 | | if( clut ) |
| 1436 | | { |
| 1437 | | pen = (pen&~0xff)|clut[pen&0xff]; |
| 1438 | | } |
| 1439 | | pDest[screenx] = pen; |
| 1440 | | } |
| 1441 | | screenx++; |
| 1442 | | sourcex += dsourcex; |
| 1443 | | } |
| 1444 | | } |
| 1445 | | else |
| 1446 | | { |
| 1447 | | while( numpixels-- > 0 ) |
| 1448 | | { |
| 1449 | | int pen = pSourceGfx[sourcex>>16]; |
| 1450 | | if( clut ) |
| 1451 | | { |
| 1452 | | pen = (pen&~0xff)|clut[pen&0xff]; |
| 1453 | | } |
| 1454 | | pDest[screenx++] = pen; |
| 1455 | | sourcex += dsourcex; |
| 1456 | | } |
| 1457 | | } |
| 1458 | | } /* dsourcex!=0 */ |
| 1459 | | } /* zoomx!=0 */ |
| 1460 | | } /* priority */ |
| 1461 | | } /* next scanline */ |
| 1462 | | } /* namco_road_draw */ |
| 1460 | void namco_c45_road_device::device_stop() |
| 1461 | { |
| 1462 | gfx_element_free(m_gfx); |
| 1463 | } |
| 1464 | |
| 1465 | |
| 1466 | //------------------------------------------------- |
| 1467 | // get_road_info -- tilemap callback |
| 1468 | //------------------------------------------------- |
| 1469 | |
| 1470 | TILE_GET_INFO_MEMBER( namco_c45_road_device::get_road_info ) |
| 1471 | { |
| 1472 | // ------xx xxxxxxxx tile number |
| 1473 | // xxxxxx-- -------- palette select |
| 1474 | UINT16 data = m_ram[tile_index]; |
| 1475 | int tile = data & 0x3ff; |
| 1476 | int color = data >> 10; |
| 1477 | SET_TILE_INFO_MEMBER(*m_gfx, tile, color, 0); |
| 1478 | } |
| 1479 | |
trunk/src/mame/drivers/namcos2.c
| r17663 | r17664 | |
| 631 | 631 | AM_RANGE(0x300000, 0x33ffff) AM_READ_LEGACY(namcos2_flap_prot_r) |
| 632 | 632 | AM_RANGE(0x800000, 0x80ffff) AM_RAM AM_SHARE("spriteram") |
| 633 | 633 | AM_RANGE(0x840000, 0x840001) AM_READWRITE(gfx_ctrl_r, gfx_ctrl_w) |
| 634 | | AM_RANGE(0x880000, 0x89ffff) AM_READ_LEGACY(namco_road16_r) AM_WRITE_LEGACY(namco_road16_w) |
| 634 | AM_RANGE(0x880000, 0x89ffff) AM_DEVREADWRITE("c45_road", namco_c45_road_device, read, write) |
| 635 | 635 | AM_RANGE(0x8c0000, 0x8c0001) AM_WRITENOP |
| 636 | 636 | AM_IMPORT_FROM( namcos2_68k_default_cpu_board_am ) |
| 637 | 637 | ADDRESS_MAP_END |
| r17663 | r17664 | |
| 708 | 708 | AM_RANGE(0x81a000, 0x81a001) AM_WRITENOP /* enable? */ |
| 709 | 709 | AM_RANGE(0x840000, 0x840001) AM_READNOP |
| 710 | 710 | AM_RANGE(0x900000, 0x900007) AM_READWRITE(c355_obj_position_r,c355_obj_position_w) |
| 711 | | AM_RANGE(0xa00000, 0xa1ffff) AM_READWRITE_LEGACY(namco_road16_r,namco_road16_w) |
| 711 | AM_RANGE(0xa00000, 0xa1ffff) AM_DEVREADWRITE("c45_road", namco_c45_road_device, read, write) |
| 712 | 712 | AM_RANGE(0xc00000, 0xc0ffff) AM_READWRITE(c169_roz_videoram_r,c169_roz_videoram_w) AM_SHARE("rozvideoram") |
| 713 | 713 | AM_RANGE(0xd00000, 0xd0001f) AM_READWRITE(c169_roz_control_r,c169_roz_control_w) |
| 714 | 714 | AM_RANGE(0xf00000, 0xf00007) AM_READWRITE_LEGACY(namcos2_68k_key_r,namcos2_68k_key_w) |
| r17663 | r17664 | |
| 1760 | 1760 | MCFG_PALETTE_LENGTH(0x2000) |
| 1761 | 1761 | |
| 1762 | 1762 | MCFG_VIDEO_START_OVERRIDE(namcos2_state, video_start_finallap) |
| 1763 | |
| 1764 | MCFG_NAMCO_C45_ROAD_ADD("c45_road") |
| 1763 | 1765 | |
| 1764 | 1766 | MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker") |
| 1765 | 1767 | |
| r17663 | r17664 | |
| 1859 | 1861 | |
| 1860 | 1862 | MCFG_VIDEO_START_OVERRIDE(namcos2_state, video_start_luckywld) |
| 1861 | 1863 | |
| 1864 | MCFG_NAMCO_C45_ROAD_ADD("c45_road") |
| 1865 | |
| 1862 | 1866 | MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker") |
| 1863 | 1867 | |
| 1864 | 1868 | MCFG_SOUND_ADD("c140", C140, C140_SOUND_CLOCK) /* 21.333kHz */ |
| r17663 | r17664 | |
| 2509 | 2513 | ROM_REGION16_BE( 0x200000, "user1", ROMREGION_ERASEFF ) /* Shared data roms */ |
| 2510 | 2514 | /* No DAT files present in ZIP archive */ |
| 2511 | 2515 | |
| 2512 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2516 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2513 | 2517 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2514 | 2518 | |
| 2515 | 2519 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2564 | 2568 | ROM_REGION16_BE( 0x200000, "user1", ROMREGION_ERASEFF ) /* Shared data roms */ |
| 2565 | 2569 | /* No DAT files present in ZIP archive */ |
| 2566 | 2570 | |
| 2567 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2571 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2568 | 2572 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2569 | 2573 | |
| 2570 | 2574 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2619 | 2623 | ROM_REGION16_BE( 0x200000, "user1", ROMREGION_ERASEFF ) /* Shared data roms */ |
| 2620 | 2624 | /* No DAT files present in ZIP archive */ |
| 2621 | 2625 | |
| 2622 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2626 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2623 | 2627 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2624 | 2628 | |
| 2625 | 2629 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2674 | 2678 | ROM_REGION16_BE( 0x200000, "user1", ROMREGION_ERASEFF ) /* Shared data roms */ |
| 2675 | 2679 | /* No DAT files present in ZIP archive */ |
| 2676 | 2680 | |
| 2677 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2681 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2678 | 2682 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2679 | 2683 | |
| 2680 | 2684 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2729 | 2733 | ROM_REGION16_BE( 0x200000, "user1", ROMREGION_ERASEFF ) /* Shared data roms */ |
| 2730 | 2734 | /* No DAT files present in ZIP archive */ |
| 2731 | 2735 | |
| 2732 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2736 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2733 | 2737 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2734 | 2738 | |
| 2735 | 2739 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2788 | 2792 | NAMCOS2_DATA_LOAD_E_256K( "fls2dat0", 0x000000, CRC(f1af432c) SHA1(c514261a49ceb5c3ba0246519ba5d02e9a20d950) ) |
| 2789 | 2793 | NAMCOS2_DATA_LOAD_O_256K( "fls2dat1", 0x000000, CRC(8719533e) SHA1(98d2767da6f7f67da7af15e8cfed95adb04b7427) ) |
| 2790 | 2794 | |
| 2791 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2795 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2792 | 2796 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2793 | 2797 | |
| 2794 | 2798 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2845 | 2849 | NAMCOS2_DATA_LOAD_E_256K( "fls2dat0", 0x000000, CRC(f1af432c) SHA1(c514261a49ceb5c3ba0246519ba5d02e9a20d950) ) |
| 2846 | 2850 | NAMCOS2_DATA_LOAD_O_256K( "fls2dat1", 0x000000, CRC(8719533e) SHA1(98d2767da6f7f67da7af15e8cfed95adb04b7427) ) |
| 2847 | 2851 | |
| 2848 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2852 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2849 | 2853 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2850 | 2854 | |
| 2851 | 2855 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2902 | 2906 | NAMCOS2_DATA_LOAD_E_128K( "flt1d0", 0x000000, CRC(80004966) SHA1(112b2a9b0ea792d5dbff1b9cf904da788aeede29) ) |
| 2903 | 2907 | NAMCOS2_DATA_LOAD_O_128K( "flt1d1", 0x000000, CRC(a2e93e8c) SHA1(9c8a5431a79153a70eb6939d16e0a5a6be235e75) ) |
| 2904 | 2908 | |
| 2905 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2909 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2906 | 2910 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2907 | 2911 | |
| 2908 | 2912 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 2963 | 2967 | NAMCOS2_DATA_LOAD_E_128K( "flt1d0", 0x000000, CRC(80004966) SHA1(112b2a9b0ea792d5dbff1b9cf904da788aeede29) ) |
| 2964 | 2968 | NAMCOS2_DATA_LOAD_O_128K( "flt1d1", 0x000000, CRC(a2e93e8c) SHA1(9c8a5431a79153a70eb6939d16e0a5a6be235e75) ) |
| 2965 | 2969 | |
| 2966 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 2970 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 2967 | 2971 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 2968 | 2972 | |
| 2969 | 2973 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 3027 | 3031 | NAMCOS2_DATA_LOAD_E_128K( "flt1d0", 0x000000, CRC(80004966) SHA1(112b2a9b0ea792d5dbff1b9cf904da788aeede29) ) |
| 3028 | 3032 | NAMCOS2_DATA_LOAD_O_128K( "flt1d1", 0x000000, CRC(a2e93e8c) SHA1(9c8a5431a79153a70eb6939d16e0a5a6be235e75) ) |
| 3029 | 3033 | |
| 3030 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 3034 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 3031 | 3035 | ROM_LOAD( "fl1-3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 3032 | 3036 | |
| 3033 | 3037 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 3089 | 3093 | NAMCOS2_DATA_LOAD_E_128K( "flt1_d0.13s", 0x000000, CRC(80004966) SHA1(112b2a9b0ea792d5dbff1b9cf904da788aeede29) ) |
| 3090 | 3094 | NAMCOS2_DATA_LOAD_O_128K( "flt1_d1.13p", 0x000000, CRC(a2e93e8c) SHA1(9c8a5431a79153a70eb6939d16e0a5a6be235e75) ) |
| 3091 | 3095 | |
| 3092 | | ROM_REGION( 0x100, "user3", 0 ) /* PROM for road colors */ |
| 3096 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* PROM for road colors */ |
| 3093 | 3097 | ROM_LOAD( "fl1_3.5b", 0, 0x100, CRC(d179d99a) SHA1(4e64f284c74d2b77f893bd28aaa6489084056aa2) ) |
| 3094 | 3098 | |
| 3095 | 3099 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 3376 | 3380 | NAMCOS2_DATA_LOAD_E_256K( "fx_dat2.13p", 0x100000, CRC(71e4a5a0) SHA1(a0188c920a43c5e69e25464627094b6b6ed26a59) ) |
| 3377 | 3381 | NAMCOS2_DATA_LOAD_O_256K( "fx_dat3.13n", 0x100000, CRC(605725f7) SHA1(b94ce0ec37f879a5e46a097058cb2dd57e2281f1) ) |
| 3378 | 3382 | |
| 3379 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 3383 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 3380 | 3384 | ROM_LOAD( "fx1_1.5b", 0, 0x100, CRC(85ffd753) SHA1(7dbc8c295204877f41289141a146aa4f5f9f9c96) ) |
| 3381 | 3385 | |
| 3382 | 3386 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 4383 | 4387 | NAMCOS2_DATA_LOAD_O_256K( "eh1-d1.bin", 0x000000, CRC(9825D5BF) SHA1(720F0E90C69A2E0C48889D510A15102768226A67) ) |
| 4384 | 4388 | NAMCOS2_DATA_LOAD_O_256K( "eh1-d3.bin", 0x100000, CRC(F46D301F) SHA1(70797FD584735844539553EFCAD53E11239EC10E) ) |
| 4385 | 4389 | |
| 4386 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 4390 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 4387 | 4391 | ROM_LOAD( "ehs1_landdt.10w", 0, 0x100, CRC(cde7e8a6) SHA1(860273daf2e649418746adf50a67ae33f9f3740c) ) |
| 4388 | 4392 | |
| 4389 | 4393 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 4435 | 4439 | NAMCOS2_DATA_LOAD_O_256K( "eh1-d1.bin", 0x000000, CRC(9825d5bf) SHA1(720f0e90c69a2e0c48889d510a15102768226a67) ) |
| 4436 | 4440 | NAMCOS2_DATA_LOAD_O_256K( "eh1-d3.bin", 0x100000, CRC(f46d301f) SHA1(70797fd584735844539553efcad53e11239ec10e) ) |
| 4437 | 4441 | |
| 4438 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 4442 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 4439 | 4443 | ROM_LOAD( "ehs1_landdt.10w", 0, 0x100, CRC(cde7e8a6) SHA1(860273daf2e649418746adf50a67ae33f9f3740c) ) |
| 4440 | 4444 | |
| 4441 | 4445 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 4495 | 4499 | NAMCOS2_DATA_LOAD_E_512K( "ehs1-dat2.13p", 0x100000, CRC(087da1f3) SHA1(e9c4ba0383e883502c0f45ae6e6d5daba4eccb01) ) |
| 4496 | 4500 | NAMCOS2_DATA_LOAD_O_512K( "ehs1-dat3.13n", 0x100000, CRC(85aecb3f) SHA1(00ab6104dee0cd0fbdb0235b88b41e4d26794f98) ) |
| 4497 | 4501 | |
| 4498 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 4502 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 4499 | 4503 | ROM_LOAD( "ehs1-landdt.10w", 0, 0x100, CRC(cde7e8a6) SHA1(860273daf2e649418746adf50a67ae33f9f3740c) ) |
| 4500 | 4504 | |
| 4501 | 4505 | ROM_REGION( 0x100000, "c140", 0 ) /* Sound voices */ |
| r17663 | r17664 | |
| 4928 | 4932 | ROM_LOAD( "lw1voi1.3m", 0x000000, 0x080000, CRC(b3e57993) SHA1(ff7071fc2e2c00f0cf819860c2a9be353474920a) ) |
| 4929 | 4933 | ROM_LOAD( "lw1voi2.3l", 0x080000, 0x080000, CRC(cd8b86a2) SHA1(54bbc91e995ea0c33874ce6fe5c3f014e173da07) ) |
| 4930 | 4934 | |
| 4931 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 4935 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 4932 | 4936 | ROM_LOAD( "lw1ld8.10w", 0, 0x100, CRC(29058c73) SHA1(4916d6bdb7f78e6803698cab32d1586ea457dfc8) ) |
| 4933 | 4937 | |
| 4934 | 4938 | ROM_REGION( 0x2000, "nvram", 0 ) /* default settings, including calibration - see notes with inputs */ |
| r17663 | r17664 | |
| 4994 | 4998 | ROM_LOAD( "lw1voi1.3m", 0x000000, 0x080000, CRC(b3e57993) SHA1(ff7071fc2e2c00f0cf819860c2a9be353474920a) ) |
| 4995 | 4999 | ROM_LOAD( "lw1voi2.3l", 0x080000, 0x080000, CRC(cd8b86a2) SHA1(54bbc91e995ea0c33874ce6fe5c3f014e173da07) ) |
| 4996 | 5000 | |
| 4997 | | ROM_REGION( 0x100, "user3", 0 ) /* prom for road colors */ |
| 5001 | ROM_REGION( 0x100, "c45_road:clut", 0 ) /* prom for road colors */ |
| 4998 | 5002 | ROM_LOAD( "lw1ld8.10w", 0, 0x100, CRC(29058c73) SHA1(4916d6bdb7f78e6803698cab32d1586ea457dfc8) ) |
| 4999 | 5003 | |
| 5000 | 5004 | ROM_REGION( 0x2000, "nvram", 0 ) /* default settings, including calibration - see notes with inputs */ |