Previous 199869 Revisions Next

r36337 Monday 9th March, 2015 at 07:55:58 UTC by Vasantha Crabb
Untangle some cherry master code
[src/mame/drivers]goldstar.c
[src/mame/includes]goldstar.h
[src/mame/video]goldstar.c

trunk/src/mame/drivers/goldstar.c
r244848r244849
614614*/
615615
616616
617WRITE8_MEMBER(goldstar_state::cm_outport1_w)
617WRITE8_MEMBER(cmaster_state::outport1_w)
618618{
619619   /* lamps? */
620   //popmessage("outport1: %02X", data);
620621}
621622
622623static ADDRESS_MAP_START( cm_map, AS_PROGRAM, 8, goldstar_state )
r244848r244849
666667
667668
668669
669static ADDRESS_MAP_START( cm_portmap, AS_IO, 8, goldstar_state )
670static ADDRESS_MAP_START( cm_portmap, AS_IO, 8, cmaster_state )
670671   ADDRESS_MAP_GLOBAL_MASK(0xff)
671672   AM_RANGE(0x01, 0x01) AM_DEVREAD("aysnd", ay8910_device, data_r)
672673   AM_RANGE(0x02, 0x03) AM_DEVWRITE("aysnd", ay8910_device, data_address_w)
673674   AM_RANGE(0x04, 0x07) AM_DEVREADWRITE("ppi8255_0", i8255_device, read, write)    /* Inputs */
674675   AM_RANGE(0x08, 0x0b) AM_DEVREADWRITE("ppi8255_1", i8255_device, read, write)    /* DIP switches */
675   AM_RANGE(0x10, 0x10) AM_WRITE(cm_outport0_w)    /* output port */
676   AM_RANGE(0x10, 0x10) AM_WRITE(outport0_w)       /* output port */
676677   AM_RANGE(0x11, 0x11) AM_WRITENOP
677   AM_RANGE(0x12, 0x12) AM_WRITE(cm_outport1_w)    /* output port */
678   AM_RANGE(0x13, 0x13) AM_WRITE(cm_background_col_w)
679   AM_RANGE(0x14, 0x14) AM_WRITE(cm_girl_scroll_w)
678   AM_RANGE(0x12, 0x12) AM_WRITE(outport1_w)       /* output port */
679   AM_RANGE(0x13, 0x13) AM_WRITE(background_col_w)
680   AM_RANGE(0x14, 0x14) AM_WRITE(girl_scroll_w)
680681ADDRESS_MAP_END
681682
682683
r244848r244849
733734ADDRESS_MAP_END
734735
735736
736static ADDRESS_MAP_START( amcoe1_portmap, AS_IO, 8, goldstar_state )
737static ADDRESS_MAP_START( amcoe1_portmap, AS_IO, 8, cmaster_state )
737738   ADDRESS_MAP_GLOBAL_MASK(0xff)
738739   AM_RANGE(0x01, 0x01) AM_DEVREAD("aysnd", ay8910_device, data_r)
739740   AM_RANGE(0x02, 0x03) AM_DEVWRITE("aysnd", ay8910_device, data_address_w)
740741   AM_RANGE(0x04, 0x07) AM_DEVREADWRITE("ppi8255_0", i8255_device, read, write)    /* Input Ports */
741742   AM_RANGE(0x08, 0x0b) AM_DEVREADWRITE("ppi8255_1", i8255_device, read, write)    /* DIP switches */
742   AM_RANGE(0x10, 0x10) AM_WRITE(cm_outport0_w)    /* output port */
743   AM_RANGE(0x10, 0x10) AM_WRITE(outport0_w)       /* output port */
743744   AM_RANGE(0x11, 0x11) AM_WRITENOP
744   AM_RANGE(0x12, 0x12) AM_WRITE(cm_outport1_w)    /* output port */
745   AM_RANGE(0x13, 0x13) AM_WRITE(cm_background_col_w)
745   AM_RANGE(0x12, 0x12) AM_WRITE(outport1_w)       /* output port */
746   AM_RANGE(0x13, 0x13) AM_WRITE(background_col_w)
746747   AM_RANGE(0x20, 0x20) AM_DEVREADWRITE("oki", okim6295_device, read, write)
747748ADDRESS_MAP_END
748749
749static ADDRESS_MAP_START( amcoe2_portmap, AS_IO, 8, goldstar_state )
750static ADDRESS_MAP_START( amcoe2_portmap, AS_IO, 8, cmaster_state )
750751   ADDRESS_MAP_GLOBAL_MASK(0xff)
751752   AM_RANGE(0x01, 0x01) AM_DEVREAD("aysnd", ay8910_device, data_r)
752753   AM_RANGE(0x02, 0x03) AM_DEVWRITE("aysnd", ay8910_device, data_address_w)
753754   AM_RANGE(0x04, 0x07) AM_DEVREADWRITE("ppi8255_0", i8255_device, read, write)    /* Input Ports */
754755   AM_RANGE(0x08, 0x0b) AM_DEVREADWRITE("ppi8255_1", i8255_device, read, write)    /* DIP switches */
755   AM_RANGE(0x10, 0x10) AM_WRITE(cm_outport0_w)    /* output port */
756   AM_RANGE(0x10, 0x10) AM_WRITE(outport0_w)       /* output port */
756757   AM_RANGE(0x11, 0x11) AM_WRITENOP
757   AM_RANGE(0x12, 0x12) AM_WRITE(cm_outport1_w)    /* output port */
758   AM_RANGE(0x13, 0x13) AM_WRITE(cm_background_col_w)
758   AM_RANGE(0x12, 0x12) AM_WRITE(outport1_w)       /* output port */
759   AM_RANGE(0x13, 0x13) AM_WRITE(background_col_w)
759760ADDRESS_MAP_END
760761
761762
r244848r244849
80478048
80488049
80498050
8050static MACHINE_CONFIG_START( cm, goldstar_state )
8051static MACHINE_CONFIG_START( cm, cmaster_state )
80518052
80528053   /* basic machine hardware */
80538054   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
r244848r244849
80918092
80928093static MACHINE_CONFIG_DERIVED( cmasterc, cm )
80938094   MCFG_GFXDECODE_MODIFY("gfxdecode", cmasterc)
8094
80958095MACHINE_CONFIG_END
80968096
80978097#ifdef UNUSED_CODE
8098static MACHINE_CONFIG_START( cmnobmp, goldstar_state )
8099
8100   /* basic machine hardware */
8101   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
8102   MCFG_CPU_PROGRAM_MAP(cm_map)
8103   MCFG_CPU_IO_MAP(cm_portmap)
8104   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state,  irq0_line_hold)
8105
8106   MCFG_DEVICE_ADD("ppi8255_0", I8255A, 0)
8107   MCFG_I8255_IN_PORTA_CB(IOPORT("IN0"))
8108   MCFG_I8255_IN_PORTB_CB(IOPORT("IN1"))
8109   MCFG_I8255_IN_PORTC_CB(IOPORT("IN2"))
8110
8111   MCFG_DEVICE_ADD("ppi8255_1", I8255A, 0)
8112   MCFG_I8255_IN_PORTA_CB(IOPORT("DSW1"))
8113   MCFG_I8255_IN_PORTB_CB(IOPORT("DSW2"))
8114   MCFG_I8255_IN_PORTC_CB(IOPORT("DSW3"))
8115
8116   /* video hardware */
8117   MCFG_SCREEN_ADD("screen", RASTER)
8118   MCFG_SCREEN_REFRESH_RATE(60)
8119//  MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0))
8120   MCFG_SCREEN_SIZE(64*8, 32*8)
8121   MCFG_SCREEN_VISIBLE_AREA(0*8, 64*8-1, 2*8, 30*8-1)
8122   MCFG_SCREEN_UPDATE_DRIVER(goldstar_state, screen_update_goldstar)
8123   MCFG_SCREEN_PALETTE("palette")
8124
8125   MCFG_GFXDECODE_ADD("gfxdecode", "palette", cm)
8126   MCFG_PALETTE_ADD("palette", 256)
8127   MCFG_PALETTE_INIT_OWNER(goldstar_state,cm)
8128   MCFG_NVRAM_ADD_1FILL("nvram")
8129
8130   MCFG_VIDEO_START_OVERRIDE(goldstar_state,cherrym)
8131
8132   /* sound hardware */
8133   MCFG_SPEAKER_STANDARD_MONO("mono")
8134   MCFG_SOUND_ADD("aysnd", AY8910, AY_CLOCK)
8135   MCFG_AY8910_PORT_A_READ_CB(IOPORT("DSW4"))
8136   MCFG_AY8910_PORT_B_READ_CB(IOPORT("DSW5"))
8137   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
8098static MACHINE_CONFIG_DERIVED( cmasterc, cmnobmp )
8099   MCFG_GFXDECODE_MODIFY("gfxdecode", cm)
81388100MACHINE_CONFIG_END
81398101#endif
81408102
r244848r244849
85158477
85168478
85178479/* diff with cm machine driver: gfxdecode, OKI & portmap */
8518static MACHINE_CONFIG_START( amcoe1, goldstar_state )
8480static MACHINE_CONFIG_START( amcoe1, cmaster_state )
85198481
85208482   /* basic machine hardware */
85218483   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
r244848r244849
85478509   MCFG_PALETTE_INIT_OWNER(goldstar_state,cm)
85488510   MCFG_NVRAM_ADD_1FILL("nvram")
85498511
8550   MCFG_VIDEO_START_OVERRIDE(goldstar_state,cherrym)
8512   MCFG_VIDEO_START_OVERRIDE(goldstar_state, cherrym)
85518513
85528514   /* sound hardware */
85538515   MCFG_SPEAKER_STANDARD_MONO("mono")
r244848r244849
85628524
85638525
85648526/* diff with cm machine driver: gfxdecode, OKI, portmap & tilemaps rect size/position */
8565static MACHINE_CONFIG_START( amcoe1a, goldstar_state )
8527static MACHINE_CONFIG_DERIVED( amcoe1a, amcoe1 )
85668528
8567   /* basic machine hardware */
8568   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
8569   MCFG_CPU_PROGRAM_MAP(cm_map)
8570   MCFG_CPU_IO_MAP(amcoe1_portmap)
8571   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state,  irq0_line_hold)
8572
8573   MCFG_DEVICE_ADD("ppi8255_0", I8255A, 0)
8574   MCFG_I8255_IN_PORTA_CB(IOPORT("IN0"))
8575   MCFG_I8255_IN_PORTB_CB(IOPORT("IN1"))
8576   MCFG_I8255_IN_PORTC_CB(IOPORT("IN2"))
8577
8578   MCFG_DEVICE_ADD("ppi8255_1", I8255A, 0)
8579   MCFG_I8255_IN_PORTA_CB(IOPORT("DSW1"))
8580   MCFG_I8255_IN_PORTB_CB(IOPORT("DSW2"))
8581   MCFG_I8255_IN_PORTC_CB(IOPORT("DSW3"))
8582
85838529   /* video hardware */
8584   MCFG_SCREEN_ADD("screen", RASTER)
8585   MCFG_SCREEN_REFRESH_RATE(60)
8586//  MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0))
8587   MCFG_SCREEN_SIZE(64*8, 32*8)
8588   MCFG_SCREEN_VISIBLE_AREA(0*8, 64*8-1, 2*8, 30*8-1)
8589   MCFG_SCREEN_UPDATE_DRIVER(goldstar_state, screen_update_amcoe1a)
8590   MCFG_SCREEN_PALETTE("palette")
8591
8592   MCFG_GFXDECODE_ADD("gfxdecode", "palette", cm)
8593   MCFG_PALETTE_ADD("palette", 256)
8594   MCFG_PALETTE_INIT_OWNER(goldstar_state,cm)
8595   MCFG_NVRAM_ADD_1FILL("nvram")
8596
8597   MCFG_VIDEO_START_OVERRIDE(goldstar_state,cherrym)
8598
8599   /* sound hardware */
8600   MCFG_SPEAKER_STANDARD_MONO("mono")
8601   MCFG_SOUND_ADD("aysnd", AY8910, AY_CLOCK)
8602   MCFG_AY8910_PORT_A_READ_CB(IOPORT("DSW4"))
8603   MCFG_AY8910_PORT_B_READ_CB(IOPORT("DSW5"))
8604   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
8605
8606   MCFG_OKIM6295_ADD("oki", OKI_CLOCK, OKIM6295_PIN7_HIGH) /* clock frequency & pin 7 not verified */
8607   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
8530   MCFG_SCREEN_MODIFY("screen")
8531   MCFG_SCREEN_UPDATE_DRIVER(cmaster_state, screen_update_amcoe1a)
86088532MACHINE_CONFIG_END
86098533
86108534
86118535/* diff with cm machine driver: gfxdecode, AY8910 volume & portmap */
8612static MACHINE_CONFIG_START( amcoe2, goldstar_state )
8536static MACHINE_CONFIG_START( amcoe2, cmaster_state )
86138537
86148538   /* basic machine hardware */
86158539   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
86168540   MCFG_CPU_PROGRAM_MAP(cm_map)
86178541   MCFG_CPU_IO_MAP(amcoe2_portmap)
8618   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
8542   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
86198543
86208544   MCFG_DEVICE_ADD("ppi8255_0", I8255A, 0)
86218545   MCFG_I8255_IN_PORTA_CB(IOPORT("IN0"))
r244848r244849
86518575   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 2.00) /* analyzed for clips */
86528576MACHINE_CONFIG_END
86538577
8654static MACHINE_CONFIG_START( nfm, goldstar_state )
8578static MACHINE_CONFIG_DERIVED( nfm, amcoe2 )
86558579
86568580   /* basic machine hardware */
8657   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
8581   MCFG_CPU_MODIFY("maincpu")
86588582   MCFG_CPU_PROGRAM_MAP(nfm_map)
8659   MCFG_CPU_IO_MAP(amcoe2_portmap)
8660   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state,  irq0_line_hold)
86618583
8662   MCFG_DEVICE_ADD("ppi8255_0", I8255A, 0)
8663   MCFG_I8255_IN_PORTA_CB(IOPORT("IN0"))
8664   MCFG_I8255_IN_PORTB_CB(IOPORT("IN1"))
8665   MCFG_I8255_IN_PORTC_CB(IOPORT("IN2"))
8666
8667   MCFG_DEVICE_ADD("ppi8255_1", I8255A, 0)
8668   MCFG_I8255_IN_PORTA_CB(IOPORT("DSW1"))
8669   MCFG_I8255_IN_PORTB_CB(IOPORT("DSW2"))
8670   MCFG_I8255_IN_PORTC_CB(IOPORT("DSW3"))
8671
8672   /* video hardware */
8673   MCFG_SCREEN_ADD("screen", RASTER)
8674   MCFG_SCREEN_REFRESH_RATE(60)
8675//  MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0))
8676   MCFG_SCREEN_SIZE(64*8, 32*8)
8677   MCFG_SCREEN_VISIBLE_AREA(0*8, 64*8-1, 2*8, 30*8-1)
8678   MCFG_SCREEN_UPDATE_DRIVER(goldstar_state, screen_update_goldstar)
8679   MCFG_SCREEN_PALETTE("palette")
8680
8681   MCFG_GFXDECODE_ADD("gfxdecode", "palette", nfm)
8682   MCFG_PALETTE_ADD("palette", 256)
8683   MCFG_PALETTE_INIT_OWNER(goldstar_state,cm)
8684   MCFG_NVRAM_ADD_1FILL("nvram")
8685
8686   MCFG_VIDEO_START_OVERRIDE(goldstar_state,cherrym)
8687
8688   /* sound hardware */
8689   MCFG_SPEAKER_STANDARD_MONO("mono")
8690   MCFG_SOUND_ADD("aysnd", AY8910, AY_CLOCK)
8691   MCFG_AY8910_PORT_A_READ_CB(IOPORT("DSW4"))
8692   MCFG_AY8910_PORT_B_READ_CB(IOPORT("DSW5"))
8693   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 2.00) /* analyzed for clips */
8584   MCFG_GFXDECODE_MODIFY("gfxdecode", nfm)
86948585MACHINE_CONFIG_END
86958586
86968587static MACHINE_CONFIG_START( unkch, unkch_state )
r244848r244849
1208911980ROM_END
1209011981
1209111982
12092READ8_MEMBER(goldstar_state::fixedval7d_r )
11983DRIVER_INIT_MEMBER(cmaster_state, fb2010)
1209311984{
12094   return ~0x7d;
12095}
12096
12097
12098DRIVER_INIT_MEMBER(goldstar_state,fb2010)
12099{
1210011985   int i;
1210111986   UINT8 *ROM = memregion("maincpu")->base();
1210211987   for (i = 0;i < 0x10000;i++)
r244848r244849
1211411999      ROM[i] = x;
1211512000   }
1211612001
12117   m_maincpu->space(AS_IO).install_read_handler(0x1e, 0x1e, read8_delegate(FUNC(goldstar_state::fixedval7d_r),this));
12118
12002   m_maincpu->space(AS_IO).install_read_handler(0x1e, 0x1e, read8_delegate(FUNC(cmaster_state::fixedval7d_r),this));
1211912003}
1212012004
1212112005
r244848r244849
1351813402   dump_to_file(ROM);
1351913403}
1352013404
13521DRIVER_INIT_MEMBER(goldstar_state,cm)
13405DRIVER_INIT_MEMBER(cmaster_state,cm)
1352213406{
1352313407   UINT8 *ROM = memregion("maincpu")->base();
1352413408
r244848r244849
1352913413   ROM[0x0025] = 0x9b;
1353013414}
1353113415
13532DRIVER_INIT_MEMBER(goldstar_state,cmv4)
13416DRIVER_INIT_MEMBER(cmaster_state, cmv4)
1353313417{
1353413418   UINT8 *ROM = memregion("maincpu")->base();
1353513419
r244848r244849
1355813442   ROM[0x0010] = 0x21;
1355913443}
1356013444
13561DRIVER_INIT_MEMBER(goldstar_state,nfb96sea)
13445DRIVER_INIT_MEMBER(cmaster_state, nfb96sea)
1356213446{
1356313447   int i;
1356413448   UINT8 *ROM = memregion("maincpu")->base();
r244848r244849
1358313467}
1358413468
1358513469
13586READ8_MEMBER(goldstar_state::fixedvalb4_r)
13470DRIVER_INIT_MEMBER(cmaster_state, schery97)
1358713471{
13588   return 0xb4;
13589}
13590READ8_MEMBER(goldstar_state::fixedvala8_r)
13591{
13592   return 0xa8;
13593}
13594DRIVER_INIT_MEMBER(goldstar_state,schery97)
13595{
1359613472   int i;
1359713473   UINT8 *ROM = memregion("maincpu")->base();
1359813474   for (i = 0;i < 0x10000;i++)
r244848r244849
1360813484
1360913485      ROM[i] = x;
1361013486   }
13611   m_maincpu->space(AS_IO).install_read_handler(0x1d, 0x1d, read8_delegate(FUNC(goldstar_state::fixedvala8_r),this));
13612   m_maincpu->space(AS_IO).install_read_handler(0x2a, 0x2a, read8_delegate(FUNC(goldstar_state::fixedvalb4_r),this));
13487   m_maincpu->space(AS_IO).install_read_handler(0x1d, 0x1d, read8_delegate(FUNC(cmaster_state::fixedvala8_r),this));
13488   m_maincpu->space(AS_IO).install_read_handler(0x2a, 0x2a, read8_delegate(FUNC(cmaster_state::fixedvalb4_r),this));
1361313489   /* Oki 6295 at 0x20 */
1361413490}
1361513491
13616READ8_MEMBER(goldstar_state::fixedval38_r)
13492DRIVER_INIT_MEMBER(cmaster_state, schery97a)
1361713493{
13618   return 0x38;
13619}
13620
13621DRIVER_INIT_MEMBER(goldstar_state,schery97a)
13622{
1362313494   int i;
1362413495   UINT8 *ROM = memregion("maincpu")->base();
1362513496   for (i = 0;i < 0x10000;i++)
r244848r244849
1363713508   }
1363813509
1363913510
13640   m_maincpu->space(AS_IO).install_read_handler(0x16, 0x16, read8_delegate(FUNC(goldstar_state::fixedval38_r),this));
13511   m_maincpu->space(AS_IO).install_read_handler(0x16, 0x16, read8_delegate(FUNC(cmaster_state::fixedval38_r),this));
1364113512   /* Oki 6295 at 0x20 */
1364213513}
1364313514
13644READ8_MEMBER(goldstar_state::fixedvalea_r)
13515DRIVER_INIT_MEMBER(cmaster_state, skill98)
1364513516{
13646   return 0xea;
13647}
13648
13649DRIVER_INIT_MEMBER(goldstar_state,skill98)
13650{
1365113517   int i;
1365213518   UINT8 *ROM = memregion("maincpu")->base();
1365313519   for (i = 0;i < 0x10000;i++)
r244848r244849
1366313529
1366413530      ROM[i] = x;
1366513531   }
13666   m_maincpu->space(AS_IO).install_read_handler(0x1e, 0x1e, read8_delegate(FUNC(goldstar_state::fixedvalea_r),this));
13532   m_maincpu->space(AS_IO).install_read_handler(0x1e, 0x1e, read8_delegate(FUNC(cmaster_state::fixedvalea_r),this));
1366713533   /* Oki 6295 at 0x20 */
1366813534}
1366913535
13670READ8_MEMBER(goldstar_state::fixedval68_r)
13536DRIVER_INIT_MEMBER(cmaster_state, nfb96_c1)
1367113537{
13672   return 0x68;
13673}
13674
13675DRIVER_INIT_MEMBER(goldstar_state,nfb96_c1)
13676{
1367713538   int i;
1367813539   UINT8 *ROM = memregion("maincpu")->base();
1367913540   for (i = 0;i < 0x10000;i++)
r244848r244849
1368913550      }
1369013551      ROM[i] = x;
1369113552   }
13692   m_maincpu->space(AS_IO).install_read_handler(0x31, 0x31, read8_delegate(FUNC(goldstar_state::fixedval68_r),this));
13553   m_maincpu->space(AS_IO).install_read_handler(0x31, 0x31, read8_delegate(FUNC(cmaster_state::fixedval68_r),this));
1369313554
1369413555}
1369513556
13696READ8_MEMBER(goldstar_state::fixedval58_r)
13557DRIVER_INIT_MEMBER(cmaster_state, nfb96_c2)
1369713558{
13698   return 0x58;
13699}
13700
13701DRIVER_INIT_MEMBER(goldstar_state,nfb96_c2)
13702{
1370313559   int i;
1370413560   UINT8 *ROM = memregion("maincpu")->base();
1370513561   for (i = 0;i < 0x10000;i++)
r244848r244849
1371613572
1371713573      ROM[i] = x;
1371813574   }
13719   m_maincpu->space(AS_IO).install_read_handler(0x21, 0x21, read8_delegate(FUNC(goldstar_state::fixedval58_r),this));
13575   m_maincpu->space(AS_IO).install_read_handler(0x21, 0x21, read8_delegate(FUNC(cmaster_state::fixedval58_r),this));
1372013576}
1372113577
13722READ8_MEMBER(goldstar_state::fixedval80_r)
13578DRIVER_INIT_MEMBER(cmaster_state, nfb96_d)
1372313579{
13724   return 0x80;
13725}
13726
13727READ8_MEMBER(goldstar_state::fixedval96_r)
13728{
13729   return 0x96;
13730}
13731
13732READ8_MEMBER(goldstar_state::fixedvalaa_r)
13733{
13734   return 0xaa;
13735}
13736
13737DRIVER_INIT_MEMBER(goldstar_state,nfb96_d)
13738{
1373913580   int i;
1374013581   UINT8 *ROM = memregion("maincpu")->base();
1374113582   for (i = 0;i < 0x10000;i++)
r244848r244849
1375213593      ROM[i] = x;
1375313594   }
1375413595   // nfb96b needs both of these
13755   m_maincpu->space(AS_IO).install_read_handler(0x23, 0x23, read8_delegate(FUNC(goldstar_state::fixedval80_r),this));
13756   m_maincpu->space(AS_IO).install_read_handler(0x5a, 0x5a, read8_delegate(FUNC(goldstar_state::fixedvalaa_r),this));
13596   m_maincpu->space(AS_IO).install_read_handler(0x23, 0x23, read8_delegate(FUNC(cmaster_state::fixedval80_r),this));
13597   m_maincpu->space(AS_IO).install_read_handler(0x5a, 0x5a, read8_delegate(FUNC(cmaster_state::fixedvalaa_r),this));
1375713598
1375813599   // csel96b
13759   m_maincpu->space(AS_IO).install_read_handler(0x6e, 0x6e, read8_delegate(FUNC(goldstar_state::fixedval96_r),this));
13600   m_maincpu->space(AS_IO).install_read_handler(0x6e, 0x6e, read8_delegate(FUNC(cmaster_state::fixedval96_r),this));
1376013601
1376113602}
1376213603
13763READ8_MEMBER(goldstar_state::fixedvalbe_r)
13764{
13765   return 0xbe;
13766}
1376713604
13768
13769DRIVER_INIT_MEMBER(goldstar_state,nfb96_dk)
13605DRIVER_INIT_MEMBER(cmaster_state, nfb96_dk)
1377013606{
1377113607   int i;
1377213608   UINT8 *ROM = memregion("maincpu")->base();
r244848r244849
1378313619      }
1378413620      ROM[i] = x;
1378513621   }
13786   m_maincpu->space(AS_IO).install_read_handler(0x2e, 0x2e, read8_delegate(FUNC(goldstar_state::fixedvalbe_r),this));
13622   m_maincpu->space(AS_IO).install_read_handler(0x2e, 0x2e, read8_delegate(FUNC(cmaster_state::fixedvalbe_r),this));
1378713623
1378813624}
1378913625
13790READ8_MEMBER(goldstar_state::fixedval90_r)
13626DRIVER_INIT_MEMBER(cmaster_state, rp35)
1379113627{
13792   return 0x90;
13793}
13794
13795READ8_MEMBER(goldstar_state::fixedval84_r)
13796{
13797   return 0x84;
13798}
13799
13800DRIVER_INIT_MEMBER(goldstar_state,rp35)
13801{
1380213628   int i;
1380313629   UINT8 *ROM = memregion("maincpu")->base();
1380413630   for (i = 0;i < 0x10000;i++)
r244848r244849
1381513641      ROM[i] = x;
1381613642   }
1381713643
13818   m_maincpu->space(AS_IO).install_read_handler(0x5e, 0x5e, read8_delegate(FUNC(goldstar_state::fixedval84_r),this));
13819   m_maincpu->space(AS_IO).install_read_handler(0x36, 0x36, read8_delegate(FUNC(goldstar_state::fixedval90_r),this));
13644   m_maincpu->space(AS_IO).install_read_handler(0x5e, 0x5e, read8_delegate(FUNC(cmaster_state::fixedval84_r),this));
13645   m_maincpu->space(AS_IO).install_read_handler(0x36, 0x36, read8_delegate(FUNC(cmaster_state::fixedval90_r),this));
1382013646}
1382113647
13822READ8_MEMBER(goldstar_state::fixedvalb2_r)
13648DRIVER_INIT_MEMBER(cmaster_state, rp36)
1382313649{
13824   return 0xb2;
13825}
13826
13827DRIVER_INIT_MEMBER(goldstar_state,rp36)
13828{
1382913650   int i;
1383013651   UINT8 *ROM = memregion("maincpu")->base();
1383113652   for (i = 0;i < 0x10000;i++)
r244848r244849
1384313664      ROM[i] = x;
1384413665   }
1384513666
13846   m_maincpu->space(AS_IO).install_read_handler(0x34, 0x34, read8_delegate(FUNC(goldstar_state::fixedvalb2_r),this));
13667   m_maincpu->space(AS_IO).install_read_handler(0x34, 0x34, read8_delegate(FUNC(cmaster_state::fixedvalb2_r),this));
1384713668}
1384813669
13849READ8_MEMBER(goldstar_state::fixedval48_r)
13670DRIVER_INIT_MEMBER(cmaster_state, rp36c3)
1385013671{
13851   return 0x48;
13852}
13853
13854DRIVER_INIT_MEMBER(goldstar_state,rp36c3)
13855{
1385613672   int i;
1385713673   UINT8 *ROM = memregion("maincpu")->base();
1385813674   for (i = 0;i < 0x10000;i++)
r244848r244849
1387013686      ROM[i] = x;
1387113687   }
1387213688
13873   m_maincpu->space(AS_IO).install_read_handler(0x17, 0x17, read8_delegate(FUNC(goldstar_state::fixedval48_r),this));
13689   m_maincpu->space(AS_IO).install_read_handler(0x17, 0x17, read8_delegate(FUNC(cmaster_state::fixedval48_r),this));
1387413690}
1387513691
13876READ8_MEMBER(goldstar_state::fixedval09_r)
13877{
13878   return 0x09;
13879}
1388013692
13881READ8_MEMBER(goldstar_state::fixedval74_r)
13693DRIVER_INIT_MEMBER(cmaster_state, po33)
1388213694{
13883   return 0x74;
13884}
13885
13886
13887DRIVER_INIT_MEMBER(goldstar_state,po33)
13888{
1388913695   int i;
1389013696   UINT8 *ROM = memregion("maincpu")->base();
1389113697   for (i = 0;i < 0x10000;i++)
r244848r244849
1390213708
1390313709      ROM[i] = x;
1390413710   }
13905   m_maincpu->space(AS_IO).install_read_handler(0x32, 0x32, read8_delegate(FUNC(goldstar_state::fixedval74_r),this));
13906   m_maincpu->space(AS_IO).install_read_handler(0x12, 0x12, read8_delegate(FUNC(goldstar_state::fixedval09_r),this));
13711   m_maincpu->space(AS_IO).install_read_handler(0x32, 0x32, read8_delegate(FUNC(cmaster_state::fixedval74_r),this));
13712   m_maincpu->space(AS_IO).install_read_handler(0x12, 0x12, read8_delegate(FUNC(cmaster_state::fixedval09_r),this));
1390713713   /* oki6295 at 0x20 */
1390813714}
1390913715
13910READ8_MEMBER(goldstar_state::fixedvale4_r)
13716DRIVER_INIT_MEMBER(cmaster_state, match133)
1391113717{
13912   return 0xe4;
13913}
13914
13915READ8_MEMBER(goldstar_state::fixedvalc7_r)
13916{
13917   return 0xc7;
13918}
13919
13920DRIVER_INIT_MEMBER(goldstar_state,match133)
13921{
1392213718   int i;
1392313719   UINT8 *ROM = memregion("maincpu")->base();
1392413720   for (i = 0;i < 0x10000;i++)
r244848r244849
1393613732      ROM[i] = x;
1393713733   }
1393813734
13939   m_maincpu->space(AS_IO).install_read_handler(0x16, 0x16, read8_delegate(FUNC(goldstar_state::fixedvalc7_r),this));
13940   m_maincpu->space(AS_IO).install_read_handler(0x1a, 0x1a, read8_delegate(FUNC(goldstar_state::fixedvale4_r),this));
13735   m_maincpu->space(AS_IO).install_read_handler(0x16, 0x16, read8_delegate(FUNC(cmaster_state::fixedvalc7_r),this));
13736   m_maincpu->space(AS_IO).install_read_handler(0x1a, 0x1a, read8_delegate(FUNC(cmaster_state::fixedvale4_r),this));
1394113737}
1394213738
1394313739DRIVER_INIT_MEMBER(cb3_state, cherrys)
r244848r244849
1399913795   ROM[0x9a6f] = 0x00;
1400013796}
1400113797
14002DRIVER_INIT_MEMBER(goldstar_state,tonypok)
13798DRIVER_INIT_MEMBER(cmaster_state, tonypok)
1400313799{
1400413800   // the ppi doesn't seem to work properly, so just install the inputs directly
1400513801   address_space &io = m_maincpu->space(AS_IO);
r244848r244849
1409313889GAME(  2001, super9,    goldstar, super9,   goldstar, goldstar_state, super9,    ROT0, "Playmark",          "Super Nove (Playmark)",                       GAME_NOT_WORKING )   // need to decode gfx and see the program loops/reset...
1409413890GAME(  2001, wcherry,   0,        wcherry,  chrygld,  goldstar_state, wcherry,   ROT0, "bootleg",           "Win Cherry (ver 0.16 - 19990219)",            GAME_NOT_WORKING )
1409513891GAME(  199?, star100,   0,        star100,  star100,  driver_device,  0,         ROT0, "Sang Ho",           "Ming Xing 100 (Star 100)",                    GAME_IMPERFECT_COLORS )
14096GAMEL( 1997, crazybon,  0,        pkrmast,  crazybon, goldstar_state, cmv4,      ROT0, "bootleg (Crazy Co.)", "Crazy Bonus 2002",                          GAME_IMPERFECT_COLORS, layout_crazybon )
13892GAMEL( 1997, crazybon,  0,        pkrmast,  crazybon, driver_device, 0,         ROT0, "bootleg (Crazy Co.)", "Crazy Bonus 2002",                          GAME_IMPERFECT_COLORS, layout_crazybon )
1409713893
1409813894
1409913895// are these really dyna, or bootlegs?
r244848r244849
1410813904GAME(  1996, cmast97,   ncb3,     cm97,     chrygld,  driver_device,  0,         ROT0, "Dyna",              "Cherry Master '97",                           GAME_NOT_WORKING) // fix prom decode
1410913905
1411013906// looks like a hack of Cherry Bonus 3
14111GAME(  199?, chryangl,  ncb3,     cm,       chryangl, goldstar_state, cmv4,      ROT0, "<unknown>",         "Cherry Angel",                                GAME_NOT_WORKING )
13907GAME(  199?, chryangl,  ncb3,     cm,       chryangl, cmaster_state, cmv4,      ROT0, "<unknown>",         "Cherry Angel",                                GAME_NOT_WORKING )
1411213908
1411313909
1411413910// cherry master hardware has a rather different mem map, but is basically the same
14115GAME(  198?, cmv801,    0,        cm,       cmv801,   goldstar_state, cm,        ROT0, "Corsica",           "Cherry Master (Corsica, ver.8.01)",           0 ) /* says ED-96 where the manufacturer is on some games.. */
13911GAME(  198?, cmv801,    0,        cm,       cmv801,   cmaster_state, cm,        ROT0, "Corsica",           "Cherry Master (Corsica, ver.8.01)",           0 ) /* says ED-96 where the manufacturer is on some games.. */
1411613912
1411713913
1411813914
r244848r244849
1412013916// most of these are almost certainly bootlegs, with added features, hacked payouts etc. identifying which are
1412113917// the original, unmodified dyna versions is almost impossible due to lack of documentation from back in the day,
1412213918// even original boards almost always run modified sets
14123GAME(  1992, cmv4,      0,        cm,       cmv4,     goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master (ver.4, set 1)",                0 )
14124GAME(  1992, cmv4a,     cmv4,     cm,       cmv4,     goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master (ver.4, set 2)",                GAME_NOT_WORKING ) // stealth game?
14125GAME(  199?, cmwm,      cmv4,     cm,       cmv4,     goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master (Watermelon bootleg / hack)",   0 ) // CM Fruit Bonus ver.2 T bootleg/hack
14126GAME(  1995, cmfun,     cmv4,     cm,       cmv4,     goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master (Fun USA v2.5 bootleg / hack)", 0 )
13919GAME(  1992, cmv4,      0,        cm,       cmv4,     cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master (ver.4, set 1)",                0 )
13920GAME(  1992, cmv4a,     cmv4,     cm,       cmv4,     cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master (ver.4, set 2)",                GAME_NOT_WORKING ) // stealth game?
13921GAME(  199?, cmwm,      cmv4,     cm,       cmv4,     cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master (Watermelon bootleg / hack)",   0 ) // CM Fruit Bonus ver.2 T bootleg/hack
13922GAME(  1995, cmfun,     cmv4,     cm,       cmv4,     cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master (Fun USA v2.5 bootleg / hack)", 0 )
1412713923GAME(  1991, cmaster,   0,        cm,       cmaster,  driver_device,  0,         ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 1)",           0 )
14128GAME(  1991, cmasterb,  cmaster,  cm,       cmasterb, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 2)",           0 )
14129GAME(  1991, cmezspin,  cmaster,  cm,       cmasterb, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (E-Z Spin bootleg / hack)",   0 ) // CM Fruit Bonus 55 ver.2 bootleg/hack
14130GAME(  1991, cmasterc,  cmaster,  cmasterc, cmasterc, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 3)",           0 )
14131GAME(  1991, cmasterbv, cmaster,  cm,       cmasterb, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 4, with Blitz Poker ROM?)", GAME_NOT_WORKING ) // Cherry Master works, but no idea how to use the Blitz ROM
14132GAME(  1991, cmasterd,  cmaster,  cm,       cmasterb, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 5)",           0 )
14133GAME(  1991, cmastere,  cmaster,  cm,       cmasterb, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 6)",           0 )
14134GAME(  1991, cmasterf,  cmaster,  cm,       cmasterb, goldstar_state, cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 7)",           0 )
13924GAME(  1991, cmasterb,  cmaster,  cm,       cmasterb, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 2)",           0 )
13925GAME(  1991, cmezspin,  cmaster,  cm,       cmasterb, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (E-Z Spin bootleg / hack)",   0 ) // CM Fruit Bonus 55 ver.2 bootleg/hack
13926GAME(  1991, cmasterc,  cmaster,  cmasterc, cmasterc, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 3)",           0 )
13927GAME(  1991, cmasterbv, cmaster,  cm,       cmasterb, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 4, with Blitz Poker ROM?)", GAME_NOT_WORKING ) // Cherry Master works, but no idea how to use the Blitz ROM
13928GAME(  1991, cmasterd,  cmaster,  cm,       cmasterb, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 5)",           0 )
13929GAME(  1991, cmastere,  cmaster,  cm,       cmasterb, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 6)",           0 )
13930GAME(  1991, cmasterf,  cmaster,  cm,       cmasterb, cmaster_state,  cmv4,      ROT0, "Dyna",              "Cherry Master I (ver.1.01, set 7)",           0 )
1413513931
1413613932
14137GAME(  1991, tonypok,   0,        cm,       tonypok,  goldstar_state, tonypok,   ROT0, "Corsica",           "Poker Master (Tony-Poker V3.A, hack?)",       0 )
14138GAME(  199?, jkrmast,   0,        pkrmast,  pkrmast,  goldstar_state, cmv4,      ROT0, "<unknown>",         "Joker Master",                                GAME_NOT_WORKING ) // encrypted?
14139GAME(  199?, pkrmast,   jkrmast,  pkrmast,  pkrmast,  goldstar_state, cmv4,      ROT0, "<unknown>",         "Poker Master (ED-1993 set 1)",                GAME_NOT_WORKING ) // incomplete dump + encrypted?
14140GAME(  1993, pkrmasta,  jkrmast,  pkrmast,  pkrmast,  goldstar_state, cmv4,      ROT0, "<unknown>",         "Poker Master (ED-1993 set 2)",                GAME_NOT_WORKING ) // incomplete dump + encrypted?
13933GAME(  1991, tonypok,   0,        cm,       tonypok,  cmaster_state,  tonypok,   ROT0, "Corsica",           "Poker Master (Tony-Poker V3.A, hack?)",       0 )
13934GAME(  199?, jkrmast,   0,        pkrmast,  pkrmast,  driver_device,  0,         ROT0, "<unknown>",         "Joker Master",                                GAME_NOT_WORKING ) // encrypted?
13935GAME(  199?, pkrmast,   jkrmast,  pkrmast,  pkrmast,  driver_device,  0,         ROT0, "<unknown>",         "Poker Master (ED-1993 set 1)",                GAME_NOT_WORKING ) // incomplete dump + encrypted?
13936GAME(  1993, pkrmasta,  jkrmast,  pkrmast,  pkrmast,  driver_device,  0,         ROT0, "<unknown>",         "Poker Master (ED-1993 set 2)",                GAME_NOT_WORKING ) // incomplete dump + encrypted?
1414113937
1414213938
1414313939GAME(  1991, cmast91,   0,        cmast91,  cmast91,  goldstar_state, cmast91,   ROT0, "Dyna",              "Cherry Master '91 (ver.1.30)",                0 )
r244848r244849
1417613972
1417713973/*    YEAR  NAME       PARENT    MACHINE   INPUT      STATE           INIT       ROT    COMPANY    FULLNAME                                                FLAGS  */
1417813974
14179GAME( 1997, schery97,  0,        amcoe1,   schery97,  goldstar_state, schery97,  ROT0, "Amcoe",   "Skill Cherry '97 (Talking ver. sc3.52)",                0 )  /* running in CB hardware */
14180GAME( 1997, schery97a, schery97, amcoe1,   schery97,  goldstar_state, schery97a, ROT0, "Amcoe",   "Skill Cherry '97 (Talking ver. sc3.52c4)",              0 )  /* running in C4 hardware */
14181GAME( 1998, skill98,   0,        amcoe1,   schery97,  goldstar_state, skill98,   ROT0, "Amcoe",   "Skill '98 (Talking ver. s98-1.33)",                     0 )
14182GAME( 1997, pokonl97,  0,        amcoe1,   pokonl97,  goldstar_state, po33,      ROT0, "Amcoe",   "Poker Only '97 (Talking ver. 3.3)",                     0 )
14183GAME( 1998, match98,   0,        amcoe1a,  match98,   goldstar_state, match133,  ROT0, "Amcoe",   "Match '98 (ver. 1.33)",                                 0 )
13975GAME( 1997, schery97,  0,        amcoe1,   schery97,  cmaster_state,  schery97,  ROT0, "Amcoe",   "Skill Cherry '97 (Talking ver. sc3.52)",                0 )  /* running in CB hardware */
13976GAME( 1997, schery97a, schery97, amcoe1,   schery97,  cmaster_state,  schery97a, ROT0, "Amcoe",   "Skill Cherry '97 (Talking ver. sc3.52c4)",              0 )  /* running in C4 hardware */
13977GAME( 1998, skill98,   0,        amcoe1,   schery97,  cmaster_state,  skill98,   ROT0, "Amcoe",   "Skill '98 (Talking ver. s98-1.33)",                     0 )
13978GAME( 1997, pokonl97,  0,        amcoe1,   pokonl97,  cmaster_state,  po33,      ROT0, "Amcoe",   "Poker Only '97 (Talking ver. 3.3)",                     0 )
13979GAME( 1998, match98,   0,        amcoe1a,  match98,   cmaster_state,  match133,  ROT0, "Amcoe",   "Match '98 (ver. 1.33)",                                 0 )
1418413980
1418513981
1418613982/* The Sub-PCB has a printed sticker denoting C1, C2, D or DK for the type of FPGA decryption chip used */
1418713983/* There is known to be a special IOWA version running on the Texas C2 hardware with roms FB96P IA, FB96L IA & FB96H IA with a (c) 2000 Amcoe */
14188GAME( 1996, nfb96,     0,        amcoe2,   nfb96,     goldstar_state, nfb96_c1,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.63, C1 PCB)",          0 ) /* ver. 02-3.63 C1 Sub-PCB */
14189GAME( 1996, nfb96a,    nfb96,    amcoe2,   nfb96,     goldstar_state, nfb96_c1,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.62, C1 PCB)",          0 ) /* ver. 00-3.62 C1 Sub-PCB */
14190GAME( 1996, nfb96b,    nfb96,    amcoe2,   nfb96,     goldstar_state, nfb96_d,   ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.54, D PCB)",           0 ) /* ver. 00-3.54 D Sub-PCB */
14191GAME( 1996, nfb96c,    nfb96,    amcoe2,   nfb96,     goldstar_state, nfb96_dk,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.62, DK PCB)",          0 ) /* ver. 00-3.62 DK Sub-PCB */
14192GAME( 2000, nfb96txt,  nfb96,    amcoe2,   nfb96tx,   goldstar_state, nfb96_c2,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v1.22 Texas XT, C2 PCB)", 0 ) /* ver. tf1.22axt C2 Sub-PCB */
13984GAME( 1996, nfb96,     0,        amcoe2,   nfb96,     cmaster_state,  nfb96_c1,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.63, C1 PCB)",          0 ) /* ver. 02-3.63 C1 Sub-PCB */
13985GAME( 1996, nfb96a,    nfb96,    amcoe2,   nfb96,     cmaster_state,  nfb96_c1,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.62, C1 PCB)",          0 ) /* ver. 00-3.62 C1 Sub-PCB */
13986GAME( 1996, nfb96b,    nfb96,    amcoe2,   nfb96,     cmaster_state,  nfb96_d,   ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.54, D PCB)",           0 ) /* ver. 00-3.54 D Sub-PCB */
13987GAME( 1996, nfb96c,    nfb96,    amcoe2,   nfb96,     cmaster_state,  nfb96_dk,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v3.62, DK PCB)",          0 ) /* ver. 00-3.62 DK Sub-PCB */
13988GAME( 2000, nfb96txt,  nfb96,    amcoe2,   nfb96tx,   cmaster_state,  nfb96_c2,  ROT0, "Amcoe",   "New Fruit Bonus '96 Special Edition (v1.22 Texas XT, C2 PCB)", 0 ) /* ver. tf1.22axt C2 Sub-PCB */
1419313989
14194GAME( 1996, nc96,      0,        amcoe2,   nfb96,     goldstar_state, nfb96_c1,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.63, C1 PCB)",          0 ) /* C1 Sub-PCB */
14195GAME( 1996, nc96a,     nc96,     amcoe2,   nfb96,     goldstar_state, nfb96_c1,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.62, C1 PCB)",          0 ) /* C1 Sub-PCB */
14196GAME( 1996, nc96b,     nc96,     amcoe2,   nfb96,     goldstar_state, nfb96_d,   ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.54, D PCB)",           0 ) /* D  Sub-PCB */
14197GAME( 1996, nc96c,     nc96,     amcoe2,   nfb96,     goldstar_state, nfb96_dk,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.62, DK PCB)",          0 ) /* DK Sub-PCB */
14198GAME( 2000, nc96txt,   nc96,     amcoe2,   nfb96tx,   goldstar_state, nfb96_c2,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v1.32 Texas XT, C2 PCB)", 0 ) /* ver. tc1.32axt C2 Sub-PCB */
13990GAME( 1996, nc96,      0,        amcoe2,   nfb96,     cmaster_state,  nfb96_c1,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.63, C1 PCB)",          0 ) /* C1 Sub-PCB */
13991GAME( 1996, nc96a,     nc96,     amcoe2,   nfb96,     cmaster_state,  nfb96_c1,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.62, C1 PCB)",          0 ) /* C1 Sub-PCB */
13992GAME( 1996, nc96b,     nc96,     amcoe2,   nfb96,     cmaster_state,  nfb96_d,   ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.54, D PCB)",           0 ) /* D  Sub-PCB */
13993GAME( 1996, nc96c,     nc96,     amcoe2,   nfb96,     cmaster_state,  nfb96_dk,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v3.62, DK PCB)",          0 ) /* DK Sub-PCB */
13994GAME( 2000, nc96txt,   nc96,     amcoe2,   nfb96tx,   cmaster_state,  nfb96_c2,  ROT0, "Amcoe",   "New Cherry '96 Special Edition (v1.32 Texas XT, C2 PCB)", 0 ) /* ver. tc1.32axt C2 Sub-PCB */
1419913995
14200GAME( 2009, fb2010,    0,        amcoe2,   nfb96tx,   goldstar_state, fb2010,    ROT0, "Amcoe",   "Fruit Bonus 2010", GAME_NOT_WORKING ) // no gfx dumped
13996GAME( 2009, fb2010,    0,        amcoe2,   nfb96tx,   cmaster_state, fb2010,    ROT0, "Amcoe",   "Fruit Bonus 2010", GAME_NOT_WORKING ) // no gfx dumped
1420113997
14202GAME( 1996, roypok96,  0,        amcoe2,   roypok96,  goldstar_state, rp35,      ROT0, "Amcoe",   "Royal Poker '96 (set 1, v97-3.5)",                         0 )
14203GAME( 1996, roypok96a, roypok96, amcoe2,   roypok96a, goldstar_state, rp36,      ROT0, "Amcoe",   "Royal Poker '96 (set 2, v98-3.6)",                         0 )
14204GAME( 1996, roypok96b, roypok96, amcoe2,   roypok96a, goldstar_state, rp36c3,    ROT0, "Amcoe",   "Royal Poker '96 (set 3, v98-3.6?)",                        0 )
13998GAME( 1996, roypok96,  0,        amcoe2,   roypok96,  cmaster_state,  rp35,      ROT0, "Amcoe",   "Royal Poker '96 (set 1, v97-3.5)",                         0 )
13999GAME( 1996, roypok96a, roypok96, amcoe2,   roypok96a, cmaster_state,  rp36,      ROT0, "Amcoe",   "Royal Poker '96 (set 2, v98-3.6)",                         0 )
14000GAME( 1996, roypok96b, roypok96, amcoe2,   roypok96a, cmaster_state,  rp36c3,    ROT0, "Amcoe",   "Royal Poker '96 (set 3, v98-3.6?)",                        0 )
1420514001
1420614002
1420714003/* these all appear to be graphic hacks of 'New Fruit Bonus '96', they can run with the same program rom
r244848r244849
1420914005*/
1421014006/*    YEAR  NAME       PARENT    MACHINE   INPUT      STATE           INIT       ROT    COMPANY    FULLNAME                                                FLAGS  */
1421114007GAME( 1996, nfb96se,   nfb96,    amcoe2,   nfb96bl,   driver_device,  0,         ROT0, "bootleg", "New Fruit Bonus '96 Special Edition (bootleg set 1, v97-3.3c Portuguese)", 0 )
14212GAME( 1996, nfb96sea,  nfb96,    amcoe2,   nfb96bl,   goldstar_state, nfb96sea,  ROT0, "bootleg", "New Fruit Bonus '96 Special Edition (bootleg set 2, v97-3.3c English)",    GAME_WRONG_COLORS ) // encrypted program
14008GAME( 1996, nfb96sea,  nfb96,    amcoe2,   nfb96bl,   cmaster_state, nfb96sea,  ROT0, "bootleg", "New Fruit Bonus '96 Special Edition (bootleg set 2, v97-3.3c English)",    GAME_WRONG_COLORS ) // encrypted program
1421314009GAME( 1996, nfb96seb,  nfb96,    amcoe2,   nfb96bl,   driver_device,  0,         ROT0, "bootleg", "New Fruit Bonus '96 Special Edition (bootleg set 3, v97-3.3c Portuguese)", GAME_WRONG_COLORS )
1421414010GAME( 2002, carb2002,  nfb96,    amcoe2,   nfb96bl,   driver_device,  0,         ROT0, "bootleg", "Carriage Bonus 2002 (bootleg)",                         GAME_WRONG_COLORS )
1421514011GAME( 2003, carb2003,  nfb96,    amcoe2,   nfb96bl,   driver_device,  0,         ROT0, "bootleg", "Carriage Bonus 2003 (bootleg)",                         GAME_WRONG_COLORS )
r244848r244849
1422714023   These have hidden games inside that can be switched to avoid inspections, police or whatever purposes)... */
1422814024
1422914025/*    YEAR  NAME       PARENT    MACHINE   INPUT      STATE           INIT       ROT    COMPANY      FULLNAME                                                 FLAGS  */
14230GAME( 198?, cmpacman,  0,        cm,       cmpacman,  goldstar_state, cm,        ROT0, "<unknown>", "Super Pacman (v1.2) + Cherry Master (Corsica, v8.31)",   0 ) /* need to press K to switch between games... */
14231GAME( 198?, cmtetris,  0,        cm,       cmtetris,  goldstar_state, cm,        ROT0, "<unknown>", "Tetris + Cherry Master (Corsica, v8.01, set 1)",         0 ) /* need to press K/L to switch between games... */
14232GAME( 198?, cmtetrsa,  0,        cm,       cmtetris,  goldstar_state, cm,        ROT0, "<unknown>", "Tetris + Cherry Master (Corsica, v8.01, set 2)",         GAME_NOT_WORKING)     // seems banked...
14233GAME( 198?, cmtetrsb,  0,        cm,       cmtetris,  goldstar_state, cm,        ROT0, "<unknown>", "Tetris + Cherry Master (+K, Canada Version, encrypted)", GAME_NOT_WORKING)     // different Tetris game
14026GAME( 198?, cmpacman,  0,        cm,       cmpacman,  cmaster_state,  cm,        ROT0, "<unknown>", "Super Pacman (v1.2) + Cherry Master (Corsica, v8.31)",   0 ) /* need to press K to switch between games... */
14027GAME( 198?, cmtetris,  0,        cm,       cmtetris,  cmaster_state,  cm,        ROT0, "<unknown>", "Tetris + Cherry Master (Corsica, v8.01, set 1)",         0 ) /* need to press K/L to switch between games... */
14028GAME( 198?, cmtetrsa,  0,        cm,       cmtetris,  cmaster_state,  cm,        ROT0, "<unknown>", "Tetris + Cherry Master (Corsica, v8.01, set 2)",         GAME_NOT_WORKING)     // seems banked...
14029GAME( 198?, cmtetrsb,  0,        cm,       cmtetris,  cmaster_state,  cm,        ROT0, "<unknown>", "Tetris + Cherry Master (+K, Canada Version, encrypted)", GAME_NOT_WORKING)     // different Tetris game
1423414030
1423514031/* other possible stealth sets:
1423614032 - cmv4a    ---> see the 1fxx zone. put a bp in 1f9f to see the loop.
trunk/src/mame/includes/goldstar.h
r244848r244849
1919   {
2020   }
2121
22   DECLARE_WRITE8_MEMBER(protection_w);
23   DECLARE_READ8_MEMBER(protection_r);
24   DECLARE_WRITE8_MEMBER(lucky8_outport_w);
25   DECLARE_WRITE8_MEMBER(ncb3_port81_w);
26   DECLARE_WRITE8_MEMBER(goldstar_lamps_w);
27   DECLARE_WRITE8_MEMBER(cb3_lamps_w);
28   DECLARE_WRITE8_MEMBER(pkrmast_lamps_w);
29   DECLARE_WRITE8_MEMBER(ladylinr_outport_w);
30   DECLARE_WRITE8_MEMBER(goldstar_fg_vidram_w);
31   DECLARE_WRITE8_MEMBER(goldstar_fg_atrram_w);
32   DECLARE_WRITE8_MEMBER(goldstar_reel1_ram_w);
33   DECLARE_WRITE8_MEMBER(goldstar_reel2_ram_w);
34   DECLARE_WRITE8_MEMBER(goldstar_reel3_ram_w);
35   DECLARE_WRITE8_MEMBER(goldstar_fa00_w);
36   DECLARE_WRITE8_MEMBER(ay8910_outputa_w);
37   DECLARE_WRITE8_MEMBER(ay8910_outputb_w);
38   DECLARE_DRIVER_INIT(goldstar);
39   DECLARE_DRIVER_INIT(cmast91);
40   DECLARE_DRIVER_INIT(wcherry);
41   DECLARE_DRIVER_INIT(super9);
42   DECLARE_VIDEO_START(goldstar);
43   DECLARE_PALETTE_INIT(cm);
44   DECLARE_VIDEO_START(cherrym);
45   DECLARE_PALETTE_INIT(cmast91);
46   DECLARE_PALETTE_INIT(lucky8);
47   UINT32 screen_update_goldstar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
48   UINT32 screen_update_cmast91(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49
50protected:
51   TILE_GET_INFO_MEMBER(get_goldstar_fg_tile_info);
52   TILE_GET_INFO_MEMBER(get_cherrym_fg_tile_info);
53   TILE_GET_INFO_MEMBER(get_goldstar_reel1_tile_info);
54   TILE_GET_INFO_MEMBER(get_goldstar_reel2_tile_info);
55   TILE_GET_INFO_MEMBER(get_goldstar_reel3_tile_info);
56
57   void do_blockswaps(UINT8* ROM);
58   void dump_to_file(UINT8* ROM);
59
2260   int m_dataoffset;
2361
24   UINT8 *m_atrram;
2562   required_shared_ptr<UINT8> m_fg_vidram;
2663   required_shared_ptr<UINT8> m_fg_atrram;
2764
r244848r244849
3673   optional_shared_ptr<UINT8> m_reel2_scroll;
3774   optional_shared_ptr<UINT8> m_reel3_scroll;
3875
39
4076   tilemap_t *m_reel1_tilemap;
4177   tilemap_t *m_reel2_tilemap;
4278   tilemap_t *m_reel3_tilemap;
r244848r244849
4884   UINT8 m_cmaster_girl_pal;
4985   UINT8 m_cm_enable_reg;
5086   UINT8 m_cm_girl_scroll;
51   int m_tile_bank;
5287
53   DECLARE_WRITE8_MEMBER(protection_w);
54   DECLARE_READ8_MEMBER(protection_r);
55   DECLARE_WRITE8_MEMBER(lucky8_outport_w);
56   DECLARE_WRITE8_MEMBER(ncb3_port81_w);
57   DECLARE_WRITE8_MEMBER(goldstar_lamps_w);
58   DECLARE_WRITE8_MEMBER(cb3_lamps_w);
59   DECLARE_WRITE8_MEMBER(cm_outport1_w);
60   DECLARE_WRITE8_MEMBER(pkrmast_lamps_w);
61   DECLARE_WRITE8_MEMBER(ladylinr_outport_w);
62   DECLARE_READ8_MEMBER(fixedvalb4_r);
63   DECLARE_READ8_MEMBER(fixedvala8_r);
64   DECLARE_READ8_MEMBER(fixedval38_r);
65   DECLARE_READ8_MEMBER(fixedvalea_r);
66   DECLARE_READ8_MEMBER(fixedval68_r);
67   DECLARE_READ8_MEMBER(fixedval58_r);
68   DECLARE_READ8_MEMBER(fixedval80_r);
69   DECLARE_READ8_MEMBER(fixedval96_r);
70   DECLARE_READ8_MEMBER(fixedvalaa_r);
71   DECLARE_READ8_MEMBER(fixedvalbe_r);
72   DECLARE_READ8_MEMBER(fixedval90_r);
73   DECLARE_READ8_MEMBER(fixedval84_r);
74   DECLARE_READ8_MEMBER(fixedvalb2_r);
75   DECLARE_READ8_MEMBER(fixedval48_r);
76   DECLARE_READ8_MEMBER(fixedval09_r);
77   DECLARE_READ8_MEMBER(fixedval74_r);
78   DECLARE_READ8_MEMBER(fixedvale4_r);
79   DECLARE_READ8_MEMBER(fixedvalc7_r);
80   DECLARE_READ8_MEMBER(fixedval7d_r);
81   DECLARE_WRITE8_MEMBER(cm_girl_scroll_w);
82   DECLARE_WRITE8_MEMBER(cm_outport0_w);
83   DECLARE_WRITE8_MEMBER(goldstar_fg_vidram_w);
84   DECLARE_WRITE8_MEMBER(goldstar_fg_atrram_w);
85   DECLARE_WRITE8_MEMBER(goldstar_reel1_ram_w);
86   DECLARE_WRITE8_MEMBER(goldstar_reel2_ram_w);
87   DECLARE_WRITE8_MEMBER(goldstar_reel3_ram_w);
88   DECLARE_WRITE8_MEMBER(goldstar_fa00_w);
89   DECLARE_WRITE8_MEMBER(cm_background_col_w);
90   DECLARE_WRITE8_MEMBER(ay8910_outputa_w);
91   DECLARE_WRITE8_MEMBER(ay8910_outputb_w);
92   DECLARE_DRIVER_INIT(goldstar);
93   DECLARE_DRIVER_INIT(cmast91);
94   DECLARE_DRIVER_INIT(nfb96_dk);
88   required_device<cpu_device> m_maincpu;
89   required_device<gfxdecode_device> m_gfxdecode;
90   required_device<palette_device> m_palette;
91};
92
93
94class cmaster_state : public goldstar_state
95{
96public:
97   cmaster_state(const machine_config &mconfig, device_type type, const char *tag) :
98      goldstar_state(mconfig, type, tag)
99   {
100   }
101
102   DECLARE_WRITE8_MEMBER(outport0_w);
103   DECLARE_WRITE8_MEMBER(outport1_w);
104   DECLARE_WRITE8_MEMBER(girl_scroll_w);
105   DECLARE_WRITE8_MEMBER(background_col_w);
106
95107   DECLARE_DRIVER_INIT(cm);
96   DECLARE_DRIVER_INIT(nfb96sea);
97   DECLARE_DRIVER_INIT(schery97a);
98   DECLARE_DRIVER_INIT(rp35);
99   DECLARE_DRIVER_INIT(wcherry);
100108   DECLARE_DRIVER_INIT(cmv4);
101   DECLARE_DRIVER_INIT(nfb96_c2);
102   DECLARE_DRIVER_INIT(rp36);
109   DECLARE_DRIVER_INIT(tonypok);
103110   DECLARE_DRIVER_INIT(schery97);
104   DECLARE_DRIVER_INIT(nfb96_d);
105   DECLARE_DRIVER_INIT(tonypok);
111   DECLARE_DRIVER_INIT(schery97a);
106112   DECLARE_DRIVER_INIT(skill98);
107113   DECLARE_DRIVER_INIT(po33);
108114   DECLARE_DRIVER_INIT(match133);
109   DECLARE_DRIVER_INIT(rp36c3);
115   DECLARE_DRIVER_INIT(nfb96_dk);
116   DECLARE_DRIVER_INIT(nfb96_c2);
117   DECLARE_DRIVER_INIT(nfb96_d);
110118   DECLARE_DRIVER_INIT(nfb96_c1);
119   DECLARE_DRIVER_INIT(nfb96sea);
111120   DECLARE_DRIVER_INIT(fb2010);
112   DECLARE_DRIVER_INIT(super9);
113   TILE_GET_INFO_MEMBER(get_goldstar_fg_tile_info);
114   TILE_GET_INFO_MEMBER(get_magical_fg_tile_info);
115   TILE_GET_INFO_MEMBER(get_cherrym_fg_tile_info);
116   TILE_GET_INFO_MEMBER(get_goldstar_reel1_tile_info);
117   TILE_GET_INFO_MEMBER(get_goldstar_reel2_tile_info);
118   TILE_GET_INFO_MEMBER(get_goldstar_reel3_tile_info);
119   DECLARE_VIDEO_START(goldstar);
120   DECLARE_PALETTE_INIT(cm);
121   DECLARE_VIDEO_START(cherrym);
122   DECLARE_PALETTE_INIT(cmast91);
123   DECLARE_PALETTE_INIT(lucky8);
124   UINT32 screen_update_goldstar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
125   UINT32 screen_update_cmast91(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
121   DECLARE_DRIVER_INIT(rp35);
122   DECLARE_DRIVER_INIT(rp36);
123   DECLARE_DRIVER_INIT(rp36c3);
124
126125   UINT32 screen_update_amcoe1a(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
127   void do_blockswaps(UINT8* ROM);
128   void dump_to_file( UINT8* ROM);
129   required_device<cpu_device> m_maincpu;
130   required_device<gfxdecode_device> m_gfxdecode;
131   required_device<palette_device> m_palette;
126
127protected:
128   // installed by various driver init handlers to get stuff to work
129   READ8_MEMBER(fixedval09_r) { return 0x09; }
130   READ8_MEMBER(fixedval38_r) { return 0x38; }
131   READ8_MEMBER(fixedval48_r) { return 0x48; }
132   READ8_MEMBER(fixedval58_r) { return 0x58; }
133   READ8_MEMBER(fixedval68_r) { return 0x68; }
134   READ8_MEMBER(fixedval74_r) { return 0x74; }
135   READ8_MEMBER(fixedval7d_r) { return 0x7d; }
136   READ8_MEMBER(fixedval80_r) { return 0x80; }
137   READ8_MEMBER(fixedval84_r) { return 0x84; }
138   READ8_MEMBER(fixedval90_r) { return 0x90; }
139   READ8_MEMBER(fixedval96_r) { return 0x96; }
140   READ8_MEMBER(fixedvala8_r) { return 0xa8; }
141   READ8_MEMBER(fixedvalaa_r) { return 0xaa; }
142   READ8_MEMBER(fixedvalb2_r) { return 0xb2; }
143   READ8_MEMBER(fixedvalb4_r) { return 0xb4; }
144   READ8_MEMBER(fixedvalbe_r) { return 0xbe; }
145   READ8_MEMBER(fixedvalc7_r) { return 0xc7; }
146   READ8_MEMBER(fixedvalea_r) { return 0xea; }
147   READ8_MEMBER(fixedvale4_r) { return 0xe4; }
132148};
133149
134150
r244848r244849
157173
158174   INTERRUPT_GEN_MEMBER(masked_irq);
159175
176protected:
177   TILE_GET_INFO_MEMBER(get_magical_fg_tile_info);
178
160179private:
161180   UINT8 m_nmi_enable;
162181   UINT8 m_vidreg;
182
183   int m_tile_bank;
163184};
164185
165186
trunk/src/mame/video/goldstar.c
r244848r244849
1919***************************************************************************/
2020
2121
22WRITE8_MEMBER(goldstar_state::cm_girl_scroll_w)
23{
24   m_cm_girl_scroll = data;
25   /*
26       xxxx ----  yscroll
27       ---- xxxx  xscroll
28
29       this isn't very fine scrolling, but i see no other registers.
30       1000 1000 is the center of the screen.
31   */
32}
33
34WRITE8_MEMBER(goldstar_state::cm_outport0_w)
35{
36   m_cm_enable_reg = data;
37   /*
38       ---- ---x  (global enable or irq enable?)
39       ---- --x-  (fg enable)
40       ---- -x--  (girl enable?)
41       ---- x---  (reels enable)
42
43       xxxx ----  unused?
44
45   */
46   //popmessage("%02x",data);
47}
48
4922WRITE8_MEMBER(goldstar_state::goldstar_fg_vidram_w)
5023{
5124   m_fg_vidram[offset] = data;
r244848r244849
7043         0);
7144}
7245
73TILE_GET_INFO_MEMBER(goldstar_state::get_magical_fg_tile_info)
74{
75   int code = m_fg_vidram[tile_index];
76   int attr = m_fg_atrram[tile_index];
7746
78   SET_TILE_INFO_MEMBER(0,
79         (code | (attr & 0xf0)<<4)+m_tile_bank*0x1000,
80         attr&0x0f,
81         0);
82}
83
84
8547// colour / high tile bits are swapped around
8648TILE_GET_INFO_MEMBER(goldstar_state::get_cherrym_fg_tile_info)
8749{
r244848r244849
193155   m_reel3_tilemap->mark_all_dirty();
194156}
195157
196WRITE8_MEMBER(goldstar_state::cm_background_col_w)
197{
198   //printf("cm_background_col_w %02x\n",data);
199158
200   /* cherry master writes
201159
202   so it's probably
203
204   0ggg cc00
205
206   where g is which girl to display and c is the colour palette
207
208   (note, this doesn't apply to the amcoe games which have no girls, I'm unsure how the priority/positioning works)
209
210
211   */
212   m_cmaster_girl_num = (data >> 4)&0x7;
213   m_cmaster_girl_pal = (data >> 2)&0x3;
214
215   //bgcolor = (data & 0x03) >> 0;
216
217   // apparently some boards have this colour scheme?
218   // i'm not convinced it isn't just a different prom on them
219   #if 0
220   m_bgcolor = 0;
221   m_bgcolor |= (data & 0x01) << 1;
222   m_bgcolor |= (data & 0x02) >> 1;
223   #else
224   m_bgcolor = (data & 0x03) >> 0;
225   #endif
226
227   m_reel1_tilemap->mark_all_dirty();
228   m_reel2_tilemap->mark_all_dirty();
229   m_reel3_tilemap->mark_all_dirty();
230}
231
232
233
234160UINT32 goldstar_state::screen_update_goldstar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
235161{
236162   int i;
r244848r244849
316242   return 0;
317243}
318244
319UINT32 goldstar_state::screen_update_amcoe1a(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
245
246
247WRITE8_MEMBER(cmaster_state::outport0_w)
320248{
249   m_cm_enable_reg = data;
250   /*
251       ---- ---x  (global enable or irq enable?)
252       ---- --x-  (fg enable)
253       ---- -x--  (girl enable?)
254       ---- x---  (reels enable)
255
256       xxxx ----  unused?
257
258   */
259   //popmessage("%02x",data);
260}
261
262WRITE8_MEMBER(cmaster_state::girl_scroll_w)
263{
264   m_cm_girl_scroll = data;
265   /*
266       xxxx ----  yscroll
267       ---- xxxx  xscroll
268
269       this isn't very fine scrolling, but i see no other registers.
270       1000 1000 is the center of the screen.
271   */
272}
273
274WRITE8_MEMBER(cmaster_state::background_col_w)
275{
276   //printf("cm_background_col_w %02x\n",data);
277
278   /* cherry master writes
279
280   so it's probably
281
282   0ggg cc00
283
284   where g is which girl to display and c is the colour palette
285
286   (note, this doesn't apply to the amcoe games which have no girls, I'm unsure how the priority/positioning works)
287
288
289   */
290   m_cmaster_girl_num = (data >> 4)&0x7;
291   m_cmaster_girl_pal = (data >> 2)&0x3;
292
293   //bgcolor = (data & 0x03) >> 0;
294
295   // apparently some boards have this colour scheme?
296   // i'm not convinced it isn't just a different prom on them
297   #if 0
298   m_bgcolor = 0;
299   m_bgcolor |= (data & 0x01) << 1;
300   m_bgcolor |= (data & 0x02) >> 1;
301   #else
302   m_bgcolor = (data & 0x03) >> 0;
303   #endif
304
305   m_reel1_tilemap->mark_all_dirty();
306   m_reel2_tilemap->mark_all_dirty();
307   m_reel3_tilemap->mark_all_dirty();
308}
309
310
311UINT32 cmaster_state::screen_update_amcoe1a(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
312{
321313   int i;
322314
323315   bitmap.fill(m_palette->black_pen(), cliprect);
r244848r244849
358350
359351
360352
353TILE_GET_INFO_MEMBER(wingco_state::get_magical_fg_tile_info)
354{
355   int code = m_fg_vidram[tile_index];
356   int attr = m_fg_atrram[tile_index];
357
358   SET_TILE_INFO_MEMBER(0,
359         (code | (attr & 0xf0)<<4)+m_tile_bank*0x1000,
360         attr&0x0f,
361         0);
362}
363
364
361365VIDEO_START_MEMBER(wingco_state, bingowng)
362366{
363   m_reel1_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_goldstar_reel1_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
367   m_reel1_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(wingco_state::get_goldstar_reel1_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
364368
365369   m_reel1_tilemap->set_scroll_cols(64);
366370
367   m_fg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_goldstar_fg_tile_info),this),TILEMAP_SCAN_ROWS,8,8, 64, 32);
371   m_fg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(wingco_state::get_goldstar_fg_tile_info),this),TILEMAP_SCAN_ROWS,8,8, 64, 32);
368372   m_fg_tilemap->set_transparent_pen(0);
369373
370374   // is there an enable reg for this game?
r244848r244849
373377
374378VIDEO_START_MEMBER(wingco_state, magical)
375379{
376   m_reel1_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_goldstar_reel1_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
377   m_reel2_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_goldstar_reel2_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
378   m_reel3_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_goldstar_reel3_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
380   m_reel1_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(wingco_state::get_goldstar_reel1_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
381   m_reel2_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(wingco_state::get_goldstar_reel2_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
382   m_reel3_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(wingco_state::get_goldstar_reel3_tile_info),this),TILEMAP_SCAN_ROWS,8,32, 64, 8);
379383
380384   m_reel1_tilemap->set_scroll_cols(32);
381385   m_reel2_tilemap->set_scroll_cols(32);
382386   m_reel3_tilemap->set_scroll_cols(32);
383387
384   m_fg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_magical_fg_tile_info),this),TILEMAP_SCAN_ROWS,8,8, 64, 32);
388   m_fg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(wingco_state::get_magical_fg_tile_info),this),TILEMAP_SCAN_ROWS,8,8, 64, 32);
385389   m_fg_tilemap->set_transparent_pen(0);
386390
387391   // is there an enable reg for this game?
r244848r244849
718722   m_cmaster_girl_pal = 0;
719723   m_vidreg = 0x00;
720724
721   m_fg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(goldstar_state::get_cherrym_fg_tile_info),this),TILEMAP_SCAN_ROWS,8,8, 64, 32);
725   m_fg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(unkch_state::get_cherrym_fg_tile_info),this),TILEMAP_SCAN_ROWS,8,8, 64, 32);
722726   m_fg_tilemap->set_transparent_pen(0);
723727
724728   m_cm_enable_reg = 0x0b;


Previous 199869 Revisions Next


© 1997-2024 The MAME Team