Previous 15994 Revisions Next

r9041 Sunday 5th September, 2010 at 12:33:02 UTC by Angelo Salese
[MZ-2500]: Various priority related bug fixes, improves Dust Box, Tower of Druaga and Super MZ Demo. Also fixed a initialize bug with PCG
[src/mess/drivers]mz2500.c

src/mess/drivers/mz2500.c
r9040r9041
1111    - Add remaining missing peripherals, SIO, HDD and w1300a network;
1212    - FDC loading without the IPLPRO doesn't work at all, why?
1313    - reverse / blanking tvram attributes;
14    - there's a soft reset PCG init bug now (try for example Eiyuu Densetsu Saga then Excite Bike), MAME / MESS core bug?
1514    - clean-ups! ^^'
1615
1716    per-game/program specific TODO:
18    - Basic: vertical scrolling returns wrap-around that shouldn't wrap;
19    - Dust Box vol. n: they all dies after pressing a key on the 256 color CG layer shows up;
20    - Dust Box vol. n: three items returns "purple" text, presumably HW failures;
17    - Dust Box vol. 1-3: they die with text garbage;
2118    - Dust Box vol. 4: window effect transition is bugged;
19    - Dust Box vol. n: three items returns "purple" text, presumably HW failures (DFJustin: joystick "digital", mouse "not installed", HDD "not installed";
2220    - LayDock: hangs by reading the FDC status and expecting it to become 0x81;
2321    - Moon Child: needs mixed 3+3bpp tvram supported;
2422    - Moon Child: appears to be a network / system link game, obviously doesn't work with current MAME / MESS framework;
25    - Mugen no Shinzou: returns an HW error if you attempt to start a play, it seems to be a fdc writing issue;
23      - Marchen Veil I: doesn't load if you try to run it, it does if you load another game first (for example Mappy);
24      - Mugen no Shinzou: returns an HW error if you attempt to do a new game, it seems to be a fdc writing issue;
2625    - Mugen no Shinzou II - The Prince of Darkness: dies on IPLPRO loading, presumably a wd17xx core bug;
2726    - Multiplan: random hangs/crashes after you set the RTC, sometimes it loads properly;
2827    - Murder Club: has lots of CG artifacts;
r9040r9041
362361   UINT8 base_mask;
363362   int res_x,res_y;
364363   UINT8 cg_interlace;
364   UINT8 pen_mask;
365365
366366   base_mask = (x_size == 640) ? 0x3f : 0x1f;
367367
r9040r9041
370370   /* TODO: layer 2 scrolling */
371371   s_x = (cg_reg[0x0f] & 0xf);
372372   cg_interlace = text_font_reg ? 1 : 2;
373   pen_mask = (cg_reg[0x18] >> ((plane & 1) * 4)) & 0x0f;
373374
374375//   popmessage("%d %d %d %d",cg_hs,cg_he,cg_vs,cg_ve);
375376
r9040r9041
386387            if(res_x < cg_hs || res_x >= cg_he || res_y < cg_vs || res_y >= cg_ve)
387388               continue;
388389
389            pen_bit[0] = (vram[count+0x40000+(plane * 0x2000)]>>(xi)) & 1 ? 1 : 0; //B
390            pen_bit[1] = (vram[count+0x44000+(plane * 0x2000)]>>(xi)) & 1 ? 2 : 0; //R
391            pen_bit[2] = (vram[count+0x48000+(plane * 0x2000)]>>(xi)) & 1 ? 4 : 0; //G
392            pen_bit[3] = (vram[count+0x4c000+(plane * 0x2000)]>>(xi)) & 1 ? 8 : 0; //I
390            pen_bit[0] = (vram[count+0x40000+(plane * 0x2000)]>>(xi)) & 1 ? (pen_mask & 0x01) : 0; //B
391            pen_bit[1] = (vram[count+0x44000+(plane * 0x2000)]>>(xi)) & 1 ? (pen_mask & 0x02) : 0; //R
392            pen_bit[2] = (vram[count+0x48000+(plane * 0x2000)]>>(xi)) & 1 ? (pen_mask & 0x04) : 0; //G
393            pen_bit[3] = (vram[count+0x4c000+(plane * 0x2000)]>>(xi)) & 1 ? (pen_mask & 0x08) : 0; //I
393394
394395            pen = 0;
395396            for(pen_i=0;pen_i<4;pen_i++)
396397               pen |= pen_bit[pen_i];
397398
398            if(pri == ((clut16[pen] & 0x10) >> 4))
399            if(pri == ((clut16[pen] & 0x10) >> 4) && clut16[pen] != 0x00 && pen_mask) //correct?
399400               mz2500_draw_pixel(machine,bitmap,res_x,res_y,(clut16[pen] & 0x0f)+0x10,(x_size == 320 && scr_x_size == 640),cg_interlace == 2);
400401         }
401402         count++;
r9040r9041
489490
490491static void draw_cg_screen(running_machine *machine, bitmap_t *bitmap,const rectangle *cliprect,int pri)
491492{
493   //popmessage("%02x %02x",cg_reg[0x0e],cg_reg[0x18]);
494
492495   switch(cg_reg[0x0e])
493496   {
494497      case 0x00:
r9040r9041
790793            else
791794               gfx_element_mark_dirty(machine->gfx[4], (offset & 0x7ff) >> 3);
792795         }
796         break;
793797      }
794      break;
795798      case 0x3a:
796799      {
797800         // DIC ROM, WRITENOP
r9040r9041
16171620   /* disable IRQ */
16181621   for(i=0;i<4;i++)
16191622      irq_mask[i] = 0;
1623
1624   kanji_bank = 0;
16201625}
16211626
16221627static const gfx_layout mz2500_cg_layout =
r9040r9041
19761981ROM_START( mz2500 )
19771982   ROM_REGION( 0x80000, "maincpu", ROMREGION_ERASEFF )
19781983
1979   ROM_REGION( 0x2000, "pcg", ROMREGION_ERASEFF )
1984   ROM_REGION( 0x2000, "pcg", ROMREGION_ERASE00 )
19801985
19811986   ROM_REGION( 0x100000, "emm", ROMREGION_ERASEFF )
19821987

Previous 15994 Revisions Next


© 1998-2018 The MESS Team