diff options
author | Angelo Salese <angelosa@users.noreply.github.com> | 2009-06-17 19:58:00 +0000 |
---|---|---|
committer | Angelo Salese <angelosa@users.noreply.github.com> | 2009-06-17 19:58:00 +0000 |
commit | cdb30239860c597bbc55a4974fb0367632386d32 (patch) | |
tree | 7353251d6d521c575f4dc4b8d07f395f8041cb89 /src | |
parent | 925bc598e75e577c8d56b21b2e006620a1b2d49a (diff) |
Fixed Pro Tennis gameplay and added basic background hook-up.
Diffstat (limited to 'src')
-rw-r--r-- | src/mame/drivers/liberate.c | 37 | ||||
-rw-r--r-- | src/mame/video/liberate.c | 53 |
2 files changed, 82 insertions, 8 deletions
diff --git a/src/mame/drivers/liberate.c b/src/mame/drivers/liberate.c index dfa50a3fddc..7235676d272 100644 --- a/src/mame/drivers/liberate.c +++ b/src/mame/drivers/liberate.c @@ -31,6 +31,7 @@ VIDEO_START( liberate ); static int deco16_bank; static UINT8 *scratchram; UINT8 *prosoccr_charram; +UINT8 *prosport_bg_vram; WRITE8_HANDLER( deco16_io_w ); WRITE8_HANDLER( prosoccr_io_w ); @@ -184,6 +185,26 @@ static WRITE8_HANDLER( prosoccr_io_bank_w ) } +static READ8_HANDLER( prosport_charram_r ) +{ + UINT8 *FG_GFX = memory_region(space->machine, "progolf_fg_gfx"); + + switch(offset & 0x1800) + { + case 0x0000: + return FG_GFX[(offset & 0x7ff)+(0x0800)+0x0000]; + //FG_GFX[(offset & 0x7ff)+(0x1800)+0x0000] = data; + case 0x0800: + return FG_GFX[(offset & 0x7ff)+(0x0800)+0x2000]; + //FG_GFX[(offset & 0x7ff)+(0x1800)+0x2000] = data; + case 0x1000: + return FG_GFX[(offset & 0x7ff)+(0x0800)+0x4000]; + //FG_GFX[(offset & 0x7ff)+(0x1800)+0x4000] = data; + } + + return 0; +} + static WRITE8_HANDLER( prosport_charram_w ) { UINT8 *FG_GFX = memory_region(space->machine, "progolf_fg_gfx"); @@ -220,11 +241,15 @@ static WRITE8_HANDLER( prosport_charram_w ) static ADDRESS_MAP_START( prosport_map, ADDRESS_SPACE_PROGRAM, 8 ) AM_RANGE(0x0200, 0x021f) AM_RAM_WRITE(prosport_paletteram_w) AM_BASE(&paletteram) - AM_RANGE(0x0000, 0x07ff) AM_SHARE(2) AM_RAM - AM_RANGE(0x0800, 0x1fff) AM_RAM_WRITE(prosport_charram_w) //0x1e00-0x1ff isn't charram! + AM_RANGE(0x0400, 0x07ff) AM_RAM AM_BASE(&prosport_bg_vram) + AM_RANGE(0x0000, 0x03ff) AM_SHARE(2) AM_RAM +// AM_RANGE(0x0e00, 0x0fff) AM_RAM +// AM_RANGE(0x1600, 0x17ff) AM_RAM +// AM_RANGE(0x1e00, 0x1fff) AM_RAM + AM_RANGE(0x0800, 0x1fff) AM_READWRITE(prosport_charram_r,prosport_charram_w) //0x1e00-0x1ff isn't charram! // AM_RANGE(0x2000, 0x2fff) AM_RAM //likely i/o - AM_RANGE(0x2000, 0x27ff) AM_SHARE(2) AM_RAM - AM_RANGE(0x2800, 0x281f) AM_SHARE(1) AM_RAM AM_BASE(&spriteram) + AM_RANGE(0x2000, 0x23ff) AM_SHARE(2) AM_RAM + AM_RANGE(0x2800, 0x283f) AM_SHARE(1) AM_RAM AM_BASE(&spriteram) // AM_RANGE(0x2800, 0x2fff) AM_SHARE(2) AM_RAM AM_RANGE(0x3000, 0x33ff) AM_RAM_WRITE(liberate_colorram_w) AM_BASE(&colorram) AM_RANGE(0x3400, 0x37ff) AM_RAM_WRITE(liberate_videoram_w) AM_BASE(&videoram) @@ -1321,8 +1346,8 @@ static DRIVER_INIT( liberate ) *************************************/ GAME( 1983, prosoccr, 0, prosoccr, prosoccr, prosport, ROT270, "Data East Corporation", "Pro Soccer", 0 ) -GAME( 1983, prosport, 0, prosport, liberate, prosport, ROT270, "Data East Corporation", "Pro. Sports", GAME_NOT_WORKING | GAME_IMPERFECT_SOUND ) -GAME( 1983, prosporta, prosport, prosport, liberate, prosport, ROT270, "Data East Corporation", "Pro. Sports (alternate)", GAME_NOT_WORKING | GAME_IMPERFECT_SOUND ) +GAME( 1983, prosport, 0, prosport, liberate, prosport, ROT270, "Data East Corporation", "Pro. Sports", GAME_NOT_WORKING | GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND ) +GAME( 1983, prosporta, prosport, prosport, liberate, prosport, ROT270, "Data East Corporation", "Pro. Sports (alternate)", GAME_NOT_WORKING | GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND ) GAME( 1983, boomrang, 0, boomrang, boomrang, prosport, ROT270, "Data East Corporation", "Boomer Rang'r / Genesis (set 1)", 0 ) GAME( 1983, boomranga, boomrang, boomrang, boomrang, prosport, ROT270, "Data East Corporation", "Boomer Rang'r / Genesis (set 2)", 0 ) GAME( 1984, kamikcab, 0, boomrang, kamikcab, prosport, ROT270, "Data East Corporation", "Kamikaze Cabbie", 0 ) diff --git a/src/mame/video/liberate.c b/src/mame/video/liberate.c index f55a21e0657..525c96acb97 100644 --- a/src/mame/video/liberate.c +++ b/src/mame/video/liberate.c @@ -16,6 +16,7 @@ static int background_color, background_disable; static tilemap *background_tilemap, *fix_tilemap; static UINT8 deco16_io_ram[16]; extern UINT8 *prosoccr_charram; +extern UINT8 *prosport_bg_vram; #if 0 void debug_print(bitmap_t *bitmap) @@ -480,8 +481,56 @@ VIDEO_UPDATE( prosport ) bitmap_fill(bitmap,cliprect,0); - popmessage("%02x %02x %02x %02x %02x %02x %02x %02x",deco16_io_ram[0],deco16_io_ram[1],deco16_io_ram[2],deco16_io_ram[3] - ,deco16_io_ram[4],deco16_io_ram[5],deco16_io_ram[6],deco16_io_ram[7]); + offs = 0; + + /* TODO: enough for showing something for Pro Bowling, not enough at all for Pro Golf...*/ + for(mx = 0;mx < 32;mx++) + { + for(my = 0;my < 16;my++) + { +// #if 0 + tile = (prosport_bg_vram[offs] & 0xf0)>>4; + tile+=0x20; + + drawgfx(bitmap,screen->machine->gfx[8], + tile,0,0,0,248-16*(mx+0),16*(my+0), + cliprect,TRANSPARENCY_NONE,0); +//#endif + #if 0 + tile = (prosport_bg_vram[offs] & 0x0f); + tile+=0x20; + + drawgfx(bitmap,screen->machine->gfx[8], + tile,0,0,0,248-16*(mx+0),16*(my), + cliprect,TRANSPARENCY_NONE,0); + #endif + offs++; + } + } + + #if 0 + offs = 0; + + for(mx = 0;mx < 32;mx++) + { + for(my = 0;my < 16;my++) + { + tile = (prosport_bg_vram[offs] & 0x0f); + //tile+=0x20; + + drawgfx(bitmap,screen->machine->gfx[8], + tile,0,0,0,248-16*(mx+0),16*(my), + cliprect,TRANSPARENCY_PEN,0); + + offs++; + } + } + #endif + + //return 0; + +// popmessage("%02x %02x %02x %02x %02x %02x %02x %02x",deco16_io_ram[0],deco16_io_ram[1],deco16_io_ram[2],deco16_io_ram[3] +// ,deco16_io_ram[4],deco16_io_ram[5],deco16_io_ram[6],deco16_io_ram[7]); for (offs = 0;offs < 0x400;offs++) { |