trunk/src/mame/drivers/8080bw.c
r18038 | r18039 | |
2216 | 2216 | |
2217 | 2217 | |
2218 | 2218 | |
2219 | | /* unknown gun game by Model Racing, possibly Gun Champ? |
| 2219 | /* unlabeled gun game by Model Racing, almost certainly Gun Champ |
2220 | 2220 | |
2221 | 2221 | BOARD 1: |
2222 | 2222 | _________________________________________________________________________________________________________________________________ |
r18038 | r18039 | |
2336 | 2336 | | P R S T U V W X | |
2337 | 2337 | |_________________________________________________________________________________________________________________________________| |
2338 | 2338 | |
| 2339 | |
| 2340 | Claybuster is probably the same hardware |
| 2341 | |
2339 | 2342 | */ |
2340 | 2343 | |
| 2344 | TIMER_DEVICE_CALLBACK( claybust_gun_callback ) |
| 2345 | { |
| 2346 | _8080bw_state *state = timer.machine().driver_data<_8080bw_state>(); |
| 2347 | |
| 2348 | // reset gun latch |
| 2349 | state->m_claybust_gun_pos = 0; |
| 2350 | } |
2341 | 2351 | |
2342 | | // the invaders shifter stuff doesn't seem correct for this, if i hook up the count_w the gfx are corrupt, otherwise they're incorrectly offset? |
2343 | | // might need custom implementation |
| 2352 | CUSTOM_INPUT_MEMBER(_8080bw_state::claybust_gun_on_r) |
| 2353 | { |
| 2354 | return (m_claybust_gun_pos != 0) ? 1 : 0; |
| 2355 | } |
2344 | 2356 | |
2345 | | static ADDRESS_MAP_START( modelr_io_map, AS_IO, 8, _8080bw_state ) |
2346 | | // AM_RANGE(0x00, 0x00) AM_DEVWRITE_LEGACY("mb14241", mb14241_shift_count_w) |
2347 | | // AM_RANGE(0x01, 0x01) AM_DEVREAD_LEGACY("mb14241", mb14241_shift_result_r) |
2348 | | AM_RANGE(0x02, 0x02) AM_DEVWRITE_LEGACY("mb14241", mb14241_shift_data_w) |
2349 | | AM_RANGE(0x03, 0x03) AM_DEVREAD_LEGACY("mb14241", mb14241_shift_result_r) |
2350 | | // AM_RANGE(0x04, 0x04) AM_DEVWRITE_LEGACY("mb14241", mb14241_shift_count_w) |
2351 | | AM_RANGE(0x05, 0x05) AM_WRITE(watchdog_reset_w) |
| 2357 | INPUT_CHANGED_MEMBER(_8080bw_state::claybust_gun_trigger) |
| 2358 | { |
| 2359 | if (newval) |
| 2360 | { |
| 2361 | /* |
| 2362 | The game registers a valid shot after the gun trigger is pressed. |
| 2363 | It latches the gun position and then compares it with VRAM contents: 1 byte/8 pixels, 0 means miss. |
| 2364 | IN1 d0 probably indicates if the latch is ready or not (glitches happen otherwise) |
| 2365 | |
| 2366 | in $06 |
| 2367 | cpi $04 |
| 2368 | rc |
| 2369 | mov h,a |
| 2370 | in $02 |
| 2371 | mov l,a |
| 2372 | lxi d,$1ffe <-- this is where the +2 comes from |
| 2373 | dad d |
| 2374 | out $00 |
| 2375 | mov a,m |
| 2376 | ana a |
| 2377 | rz |
| 2378 | */ |
| 2379 | UINT8 gunx = ioport("GUNX")->read_safe(0x00); |
| 2380 | UINT8 guny = ioport("GUNY")->read_safe(0x20); |
| 2381 | m_claybust_gun_pos = ((gunx >> 3) | (guny << 5)) + 2; |
| 2382 | m_claybust_gun_on->adjust(attotime::from_msec(250)); // timing is a guess |
| 2383 | } |
| 2384 | } |
| 2385 | |
| 2386 | READ8_MEMBER(_8080bw_state::claybust_gun_lo_r) |
| 2387 | { |
| 2388 | return m_claybust_gun_pos & 0xff; |
| 2389 | } |
| 2390 | |
| 2391 | READ8_MEMBER(_8080bw_state::claybust_gun_hi_r) |
| 2392 | { |
| 2393 | return m_claybust_gun_pos >> 8; |
| 2394 | } |
| 2395 | |
| 2396 | static ADDRESS_MAP_START( claybust_io_map, AS_IO, 8, _8080bw_state ) |
| 2397 | //AM_RANGE(0x00, 0x00) AM_WRITENOP // ? |
| 2398 | AM_RANGE(0x01, 0x01) AM_READ_PORT("IN1") AM_DEVWRITE_LEGACY("mb14241", mb14241_shift_count_w) |
| 2399 | AM_RANGE(0x02, 0x02) AM_READ(claybust_gun_lo_r) AM_DEVWRITE_LEGACY("mb14241", mb14241_shift_data_w) |
| 2400 | AM_RANGE(0x03, 0x03) AM_DEVREAD_LEGACY("mb14241", mb14241_shift_result_r) //AM_WRITENOP // port3 write looks sound-related |
| 2401 | AM_RANGE(0x04, 0x04) AM_WRITE(watchdog_reset_w) |
| 2402 | //AM_RANGE(0x05, 0x05) AM_WRITENOP // ? |
| 2403 | AM_RANGE(0x06, 0x06) AM_READ(claybust_gun_hi_r) |
2352 | 2404 | ADDRESS_MAP_END |
2353 | 2405 | |
2354 | | MACHINE_CONFIG_DERIVED_CLASS( modelr, invaders, _8080bw_state ) |
2355 | 2406 | |
| 2407 | static INPUT_PORTS_START( claybust ) |
| 2408 | PORT_START("IN1") |
| 2409 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM_MEMBER(DEVICE_SELF, _8080bw_state, claybust_gun_on_r, NULL) |
| 2410 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_IMPULSE(2) PORT_CHANGED_MEMBER(DEVICE_SELF, _8080bw_state, claybust_gun_trigger, NULL) |
| 2411 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 2412 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) |
| 2413 | |
| 2414 | PORT_DIPNAME( 0x10, 0x10, "Shots" ) |
| 2415 | PORT_DIPSETTING( 0x10, "4" ) |
| 2416 | PORT_DIPSETTING( 0x00, "2" ) |
| 2417 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) |
| 2418 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) |
| 2419 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 2420 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) |
| 2421 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) |
| 2422 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 2423 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) |
| 2424 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) |
| 2425 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 2426 | |
| 2427 | PORT_START( "GUNX" ) |
| 2428 | PORT_BIT( 0xff, 0x80, IPT_LIGHTGUN_X ) PORT_MINMAX(0x00, 0xff) PORT_CROSSHAIR(X, 1.0 - (MW8080BW_HPIXCOUNT-256)/256.0, (MW8080BW_HPIXCOUNT-256)/256.0, 0) PORT_SENSITIVITY(56) PORT_KEYDELTA(5) |
| 2429 | PORT_START( "GUNY" ) |
| 2430 | PORT_BIT( 0xff, 0xa0, IPT_LIGHTGUN_Y ) PORT_MINMAX(0x20, 0xff) PORT_CROSSHAIR(Y, 1.0, 0.0, 0) PORT_SENSITIVITY(64) PORT_KEYDELTA(5) |
| 2431 | INPUT_PORTS_END |
| 2432 | |
| 2433 | static INPUT_PORTS_START( gunchamp ) |
| 2434 | PORT_INCLUDE( claybust ) |
| 2435 | |
| 2436 | PORT_MODIFY("IN1") |
| 2437 | PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) ) |
| 2438 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) |
| 2439 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 2440 | PORT_DIPNAME( 0xe0, 0x40, DEF_STR( Coinage ) ) |
| 2441 | PORT_DIPSETTING( 0xa0, DEF_STR( 4C_1C ) ) |
| 2442 | PORT_DIPSETTING( 0xc0, DEF_STR( 3C_1C ) ) |
| 2443 | PORT_DIPSETTING( 0xe0, DEF_STR( 2C_1C ) ) |
| 2444 | PORT_DIPSETTING( 0x40, DEF_STR( 1C_1C ) ) |
| 2445 | PORT_DIPSETTING( 0x20, DEF_STR( 1C_2C ) ) |
| 2446 | PORT_DIPSETTING( 0x00, DEF_STR( 2C_3C ) ) |
| 2447 | PORT_DIPSETTING( 0x60, DEF_STR( 1C_3C ) ) |
| 2448 | PORT_DIPSETTING( 0x80, DEF_STR( 1C_4C ) ) |
| 2449 | INPUT_PORTS_END |
| 2450 | |
| 2451 | |
| 2452 | MACHINE_START_MEMBER(_8080bw_state, claybust) |
| 2453 | { |
| 2454 | m_claybust_gun_pos = 0; |
| 2455 | save_item(NAME(m_claybust_gun_pos)); |
| 2456 | |
| 2457 | MACHINE_START_CALL_MEMBER(mw8080bw); |
| 2458 | } |
| 2459 | |
| 2460 | MACHINE_CONFIG_DERIVED_CLASS( claybust, invaders, _8080bw_state ) |
| 2461 | |
2356 | 2462 | /* basic machine hardware */ |
2357 | 2463 | MCFG_CPU_MODIFY("maincpu") |
2358 | | MCFG_CPU_IO_MAP(modelr_io_map) |
2359 | | |
2360 | | MCFG_WATCHDOG_TIME_INIT(attotime::never) |
| 2464 | MCFG_CPU_IO_MAP(claybust_io_map) |
2361 | 2465 | |
| 2466 | MCFG_TIMER_ADD("claybust_gun", claybust_gun_callback) |
| 2467 | |
| 2468 | MCFG_MACHINE_START_OVERRIDE(_8080bw_state, claybust) |
| 2469 | |
| 2470 | /* sound hardware */ |
| 2471 | // TODO: discrete sound |
| 2472 | |
2362 | 2473 | MACHINE_CONFIG_END |
2363 | 2474 | |
2364 | 2475 | |
2365 | 2476 | |
2366 | 2477 | /* Taito Galactica / Space Missile |
2367 | 2478 | This game was officially only distributed in Brazil. |
2368 | | Not much information is avaliable. It is speculated that the original is "Space Missile", whose manufacturer was sued by Taito in Japan. |
2369 | | Release date is unknown, maybe even before Galaxian?! |
| 2479 | Regarding release data, not much information is available online. |
2370 | 2480 | |
2371 | 2481 | ROM dump came from a collection of old 5 1/4 disks (Apple II) that used to be in the possession of an arcade operator in the early 80s. |
2372 | 2482 | |
r18038 | r18039 | |
2533 | 2643 | |
2534 | 2644 | MACHINE_RESET_MEMBER(_8080bw_state,invmulti) |
2535 | 2645 | { |
2536 | | |
2537 | 2646 | invmulti_bank_w(m_maincpu->space(AS_PROGRAM), 0, 0); |
2538 | 2647 | |
2539 | 2648 | MACHINE_RESET_CALL_MEMBER(mw8080bw); |
r18038 | r18039 | |
3789 | 3898 | GAME( 1979, yosakdona,yosakdon, yosakdon, yosakdon, driver_device, 0, ROT270, "Wing", "Yosaku To Donbei (set 2)", GAME_SUPPORTS_SAVE | GAME_IMPERFECT_SOUND ) /* bootleg? */ |
3790 | 3899 | GAMEL(1979, shuttlei, 0, shuttlei, shuttlei, driver_device, 0, ROT270, "Omori Electric Co., Ltd.", "Shuttle Invader", GAME_SUPPORTS_SAVE | GAME_IMPERFECT_SOUND | GAME_NO_COCKTAIL, layout_shuttlei ) |
3791 | 3900 | GAMEL(1979, skylove, 0, shuttlei, skylove, driver_device, 0, ROT270, "Omori Electric Co., Ltd.", "Sky Love", GAME_SUPPORTS_SAVE | GAME_IMPERFECT_SOUND | GAME_NO_COCKTAIL, layout_shuttlei ) |
3792 | | GAME (1978, claybust, 0, modelr, invadrmr, driver_device, 0, ROT0, "Model Racing", "Claybuster", GAME_NOT_WORKING | GAME_SUPPORTS_SAVE ) // no titlescreen, Claybuster according to flyers |
3793 | | GAME (1980, gunchamp, 0, modelr, invadrmr, driver_device, 0, ROT0, "Model Racing", "Gun Champ", GAME_NOT_WORKING | GAME_SUPPORTS_SAVE ) // no titlescreen, but very likely this is Gun Champ |
| 3901 | GAME (1978, claybust, 0, claybust, claybust, driver_device, 0, ROT0, "Model Racing", "Claybuster", GAME_SUPPORTS_SAVE | GAME_NO_SOUND ) // no titlescreen, Claybuster according to flyers |
| 3902 | GAME (1980, gunchamp, 0, claybust, gunchamp, driver_device, 0, ROT0, "Model Racing", "Gun Champ", GAME_SUPPORTS_SAVE | GAME_NO_SOUND ) // no titlescreen, but very likely this is Gun Champ |
3794 | 3903 | |
3795 | 3904 | GAME( 2002, invmulti, 0, invmulti, invmulti, _8080bw_state, invmulti, ROT270, "hack (Braze Technologies)", "Space Invaders Multigame (M8.03D)", GAME_IMPERFECT_SOUND | GAME_SUPPORTS_SAVE ) |
3796 | 3905 | GAME( 2002, invmultim3a, invmulti, invmulti, invmulti, _8080bw_state, invmulti, ROT270, "hack (Braze Technologies)", "Space Invaders Multigame (M8.03A)", GAME_IMPERFECT_SOUND | GAME_SUPPORTS_SAVE ) |