summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author Couriersud <couriersud@users.noreply.github.com>2008-07-05 19:12:21 +0000
committer Couriersud <couriersud@users.noreply.github.com>2008-07-05 19:12:21 +0000
commit096e611d42f0cc095c5e8b7eea980ec9e84841ef (patch)
treec2c21a52e2563ed30c6dbf43c2a9915ed339e765
parent3db9923247d3bab8b1ca03009e7bf597a18ae67b (diff)
01854: All sets in thepit.c: Player 2 in cocktail mode has screen reversed
-rw-r--r--src/mame/video/thepit.c32
1 files changed, 26 insertions, 6 deletions
diff --git a/src/mame/video/thepit.c b/src/mame/video/thepit.c
index 6b896359182..34ace50b590 100644
--- a/src/mame/video/thepit.c
+++ b/src/mame/video/thepit.c
@@ -186,19 +186,33 @@ WRITE8_HANDLER( thepit_colorram_w )
WRITE8_HANDLER( thepit_flip_screen_x_w )
{
+ int flip;
+
thepit_flip_screen_x = data & 0x01;
- tilemap_set_flip(thepit_tilemap, thepit_flip_screen_x ? TILEMAP_FLIPX : 0);
- tilemap_set_flip(thepit_solid_tilemap, thepit_flip_screen_x ? TILEMAP_FLIPX : 0);
+ flip = thepit_flip_screen_x ? TILEMAP_FLIPX : 0;
+ if (thepit_flip_screen_y)
+ flip |= TILEMAP_FLIPY ;
+
+ tilemap_set_flip(thepit_tilemap, flip);
+ tilemap_set_flip(thepit_solid_tilemap, flip);
+
}
WRITE8_HANDLER( thepit_flip_screen_y_w )
{
+ int flip;
+
thepit_flip_screen_y = data & 0x01;
- tilemap_set_flip(thepit_tilemap, thepit_flip_screen_y ? TILEMAP_FLIPY : 0);
- tilemap_set_flip(thepit_solid_tilemap, thepit_flip_screen_y ? TILEMAP_FLIPY : 0);
+ flip = thepit_flip_screen_x ? TILEMAP_FLIPX : 0;
+ if (thepit_flip_screen_y)
+ flip |= TILEMAP_FLIPY ;
+
+ tilemap_set_flip(thepit_tilemap, flip);
+ tilemap_set_flip(thepit_solid_tilemap, flip);
+
}
@@ -291,8 +305,14 @@ VIDEO_UPDATE( thepit )
for (offs = 0; offs < 32; offs++)
{
- tilemap_set_scrolly(thepit_tilemap, offs, thepit_attributesram[offs << 1]);
- tilemap_set_scrolly(thepit_solid_tilemap, offs, thepit_attributesram[offs << 1]);
+ int xshift = thepit_flip_screen_x ? 128 : 0;
+ int yshift = thepit_flip_screen_y ? -8 : 0;
+
+ tilemap_set_scrollx(thepit_tilemap, offs, xshift);
+ tilemap_set_scrollx(thepit_solid_tilemap, offs, xshift);
+
+ tilemap_set_scrolly(thepit_tilemap, offs, yshift + thepit_attributesram[offs << 1]);
+ tilemap_set_scrolly(thepit_solid_tilemap, offs, yshift + thepit_attributesram[offs << 1]);
}
/* low priority tiles */