From b829afddc98c34949acce52a8b31d4fd3b7e306a Mon Sep 17 00:00:00 2001 From: Angelo Salese Date: Fri, 1 Mar 2013 04:21:39 +0000 Subject: [PATCH] Added height & width --- src/mame/drivers/gunpey.c | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/src/mame/drivers/gunpey.c b/src/mame/drivers/gunpey.c index 430ed11833f..5fb9a286aca 100644 --- a/src/mame/drivers/gunpey.c +++ b/src/mame/drivers/gunpey.c @@ -236,6 +236,9 @@ UINT32 gunpey_state::screen_update_gunpey(screen_device &screen, bitmap_ind16 &b //UINT16 *blit_buffer = m_blit_buffer; int x,y; int count; + int bpp_sel; + int height; + int width; UINT16 vram_bank = m_vram_bank & 0x7fff; UINT8 *vram = memregion("vram")->base(); @@ -243,12 +246,16 @@ UINT32 gunpey_state::screen_update_gunpey(screen_device &screen, bitmap_ind16 &b vram_bank ^= 0x2000; - for(count = vram_bank/2;count<(vram_bank+0x2000)/2;count+=0x10/2) + /* last 4 entries are special, skip them for now. */ + for(count = vram_bank/2;count<(vram_bank+0x2000-0x40)/2;count+=0x10/2) { if(!(m_wram[count+0] & 1)) { x = (m_wram[count+3] >> 8) | ((m_wram[count+4] & 0x03) << 8); y = (m_wram[count+4] >> 8) | ((m_wram[count+4] & 0x30) << 4); + width = (m_wram[count+5] >> 8); + height = (m_wram[count+5] & 0xff); + bpp_sel = (m_wram[count+0] & 0x18); x-=0x160; y-=0x188; @@ -321,10 +328,11 @@ SOUND TEST drawgfx_opaque(bitmap,cliprect,machine().gfx[1],letter,1,0,0,x,y); else #endif + if(bpp_sel == 0x00) { - for(int yi=0;yi<8;yi++) + for(int yi=0;yi