Previous 199869 Revisions Next

r21810 Tuesday 12th March, 2013 at 16:47:37 UTC by hap
fixed video regression with bucky clones + added imperfect gfx flag
[src/mame/drivers]moo.c
[src/mame/includes]moo.h
[src/mame/video]moo.c

trunk/src/mame/drivers/moo.c
r21809r21810
9191}
9292
9393
94static void moo_objdma( running_machine &machine, int type )
94void moo_state::moo_objdma()
9595{
96   moo_state *state = machine.driver_data<moo_state>();
9796   int num_inactive;
98   UINT16 *src, *dst, zmask;
99   int counter = k053247_get_dy(state->m_k053246);
97   UINT16 *src, *dst;
98   int counter = k053247_get_dy(m_k053246);
10099
101   k053247_get_ram(state->m_k053246, &dst);
102   src = state->m_spriteram;
100   k053247_get_ram(m_k053246, &dst);
101   src = m_spriteram;
103102   num_inactive = counter = 256;
104103
105   zmask = (type) ? 0x00ff : 0xffff;
106
107   do {
108      if ((*src & 0x8000) && (*src & zmask))
104   do
105   {
106      if ((*src & 0x8000) && (*src & m_zmask))
109107      {
110108         memcpy(dst, src, 0x10);
111109         dst += 8;
r21809r21810
115113   }
116114   while (--counter);
117115
118   if (num_inactive) do { *dst = 0; dst += 8; } while (--num_inactive);
116   if (num_inactive)
117   {
118      do
119      {
120         *dst = 0;
121         dst += 8;
122      }
123      while (--num_inactive);
124   }
119125}
120126
121127TIMER_CALLBACK_MEMBER(moo_state::dmaend_callback)
r21809r21810
128134{
129135   if (k053246_is_irq_enabled(m_k053246))
130136   {
131      moo_objdma(machine(), m_game_type);
137      moo_objdma();
132138
133139      // schedule DMA end interrupt (delay shortened to catch up with V-blank)
134140      m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY));
r21809r21810
141147
142148INTERRUPT_GEN_MEMBER(moo_state::moobl_interrupt)
143149{
144   moo_objdma(machine(), m_game_type);
150   moo_objdma();
145151
146152   // schedule DMA end interrupt (delay shortened to catch up with V-blank)
147153   m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY));
r21809r21810
603609
604610   /* video hardware */
605611   MCFG_PALETTE_LENGTH(4096)
612   
613   MCFG_VIDEO_START_OVERRIDE(moo_state,bucky)
606614MACHINE_CONFIG_END
607615
608616
r21809r21810
909917   ROM_LOAD( "moo.nv", 0x0000, 0x080, CRC(7bd904a8) SHA1(8747c5c62d1832e290be8ace73c61b1f228c0bec) )
910918ROM_END
911919
912DRIVER_INIT_MEMBER(moo_state,moo)
913{
914   m_game_type = (!strcmp(machine().system().name, "bucky") || !strcmp(machine().system().name, "buckyua"));
915}
916920
917
918GAME( 1992, moomesa,    0,       moo,     moo, moo_state,     moo,      ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver EAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
919GAME( 1992, moomesauac, moomesa, moo,     moo, moo_state,     moo,      ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver UAC)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
920GAME( 1992, moomesauab, moomesa, moo,     moo, moo_state,     moo,      ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver UAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
921GAME( 1992, moomesaaab, moomesa, moo,     moo, moo_state,     moo,      ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver AAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
922GAME( 1992, moomesabl,  moomesa, moobl,   moo, moo_state,     moo,      ROT0, "bootleg", "Wild West C.O.W.-Boys of Moo Mesa (bootleg)", GAME_NOT_WORKING | GAME_SUPPORTS_SAVE ) // based on Version AA
923GAME( 1992, bucky,      0,       bucky,   bucky, moo_state,   moo,      ROT0, "Konami", "Bucky O'Hare (ver EAB)", GAME_SUPPORTS_SAVE )
924GAME( 1992, buckyuab,   bucky,   bucky,   bucky, moo_state,   moo,      ROT0, "Konami", "Bucky O'Hare (ver UAB)", GAME_SUPPORTS_SAVE )
925GAME( 1992, buckyaab,   bucky,   bucky,   bucky, moo_state,   moo,      ROT0, "Konami", "Bucky O'Hare (ver AAB)", GAME_SUPPORTS_SAVE )
921GAME( 1992, moomesa,    0,       moo,     moo,   driver_device, 0, ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver EAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
922GAME( 1992, moomesauac, moomesa, moo,     moo,   driver_device, 0, ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver UAC)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
923GAME( 1992, moomesauab, moomesa, moo,     moo,   driver_device, 0, ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver UAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
924GAME( 1992, moomesaaab, moomesa, moo,     moo,   driver_device, 0, ROT0, "Konami", "Wild West C.O.W.-Boys of Moo Mesa (ver AAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
925GAME( 1992, moomesabl,  moomesa, moobl,   moo,   driver_device, 0, ROT0, "bootleg", "Wild West C.O.W.-Boys of Moo Mesa (bootleg)", GAME_NOT_WORKING | GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE ) // based on Version AA
926GAME( 1992, bucky,      0,       bucky,   bucky, driver_device, 0, ROT0, "Konami", "Bucky O'Hare (ver EAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
927GAME( 1992, buckyuab,   bucky,   bucky,   bucky, driver_device, 0, ROT0, "Konami", "Bucky O'Hare (ver UAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
928GAME( 1992, buckyaab,   bucky,   bucky,   bucky, driver_device, 0, ROT0, "Konami", "Bucky O'Hare (ver AAB)", GAME_IMPERFECT_GRAPHICS | GAME_SUPPORTS_SAVE )
trunk/src/mame/includes/moo.h
r21809r21810
2222   int         m_layer_colorbase[4];
2323   int         m_layerpri[3];
2424   int         m_alpha_enabled;
25   UINT16      m_zmask;
2526
2627   /* misc */
27   int         m_game_type;
2828   UINT16      m_protram[16];
2929   UINT16      m_cur_control2;
3030
r21809r21810
4949   DECLARE_WRITE16_MEMBER(K053247_scattered_word_w);
5050   DECLARE_WRITE16_MEMBER(moo_prot_w);
5151   DECLARE_WRITE16_MEMBER(moobl_oki_bank_w);
52   DECLARE_DRIVER_INIT(moo);
5352   DECLARE_MACHINE_START(moo);
5453   DECLARE_MACHINE_RESET(moo);
5554   DECLARE_VIDEO_START(moo);
55   DECLARE_VIDEO_START(bucky);
5656   UINT32 screen_update_moo(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
5757   INTERRUPT_GEN_MEMBER(moo_interrupt);
5858   INTERRUPT_GEN_MEMBER(moobl_interrupt);
5959   TIMER_CALLBACK_MEMBER(dmaend_callback);
60   void moo_objdma();
6061};
6162
6263/*----------- defined in video/moo.c -----------*/
trunk/src/mame/video/moo.c
r21809r21810
4040   assert(machine().primary_screen->format() == BITMAP_FORMAT_RGB32);
4141
4242   m_alpha_enabled = 0;
43   m_zmask = 0xffff;
4344
44   if (!strcmp(machine().system().name, "bucky") || !strcmp(machine().system().name, "buckyua") || !strcmp(machine().system().name, "buckyaa"))
45   {
46      // Bucky doesn't chain tilemaps
47      k056832_set_layer_association(m_k056832, 0);
45   // other than the intro showing one blank line alignment is good through the game
46   k056832_set_layer_offs(m_k056832, 0, -2 + 1, 0);
47   k056832_set_layer_offs(m_k056832, 1,  2 + 1, 0);
48   k056832_set_layer_offs(m_k056832, 2,  4 + 1, 0);
49   k056832_set_layer_offs(m_k056832, 3,  6 + 1, 0);
50}
4851
49      k056832_set_layer_offs(m_k056832, 0, -2, 0);
50      k056832_set_layer_offs(m_k056832, 1,  2, 0);
51      k056832_set_layer_offs(m_k056832, 2,  4, 0);
52      k056832_set_layer_offs(m_k056832, 3,  6, 0);
53   }
54   else
55   {
56      // other than the intro showing one blank line alignment is good through the game
57      k056832_set_layer_offs(m_k056832, 0, -2 + 1, 0);
58      k056832_set_layer_offs(m_k056832, 1,  2 + 1, 0);
59      k056832_set_layer_offs(m_k056832, 2,  4 + 1, 0);
60      k056832_set_layer_offs(m_k056832, 3,  6 + 1, 0);
61   }
52VIDEO_START_MEMBER(moo_state,bucky)
53{
54   assert(machine().primary_screen->format() == BITMAP_FORMAT_RGB32);
55
56   m_alpha_enabled = 0;
57   m_zmask = 0x00ff;
58
59   // Bucky doesn't chain tilemaps
60   k056832_set_layer_association(m_k056832, 0);
61
62   k056832_set_layer_offs(m_k056832, 0, -2, 0);
63   k056832_set_layer_offs(m_k056832, 1,  2, 0);
64   k056832_set_layer_offs(m_k056832, 2,  4, 0);
65   k056832_set_layer_offs(m_k056832, 3,  6, 0);
6266}
6367
6468UINT32 moo_state::screen_update_moo(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)

Previous 199869 Revisions Next


© 1997-2024 The MAME Team