mirror of
https://github.com/holub/mame
synced 2025-07-04 17:38:08 +03:00
yamato: improve background gradient
This commit is contained in:
parent
6859c3df98
commit
c84cf2e306
@ -873,14 +873,14 @@ ROM_START( bwidowp )
|
|||||||
/* Vector ROM */
|
/* Vector ROM */
|
||||||
ROM_LOAD( "vg4800", 0x4800, 0x0800, CRC(12c0e382) SHA1(b0a899d013ad00ff5f861da9897780c5f0c5d221) )
|
ROM_LOAD( "vg4800", 0x4800, 0x0800, CRC(12c0e382) SHA1(b0a899d013ad00ff5f861da9897780c5f0c5d221) )
|
||||||
ROM_LOAD( "vg5000", 0x5000, 0x1000, CRC(7009106a) SHA1(d41d147eccb2bb4e0a3e9bb184c2bfd09c80b92f) )
|
ROM_LOAD( "vg5000", 0x5000, 0x1000, CRC(7009106a) SHA1(d41d147eccb2bb4e0a3e9bb184c2bfd09c80b92f) )
|
||||||
ROM_RELOAD( 0x6000, 0x1000 )
|
ROM_RELOAD( 0x6000, 0x1000 )
|
||||||
/* Program ROM */
|
/* Program ROM */
|
||||||
ROM_LOAD( "a000", 0xa000, 0x1000, CRC(ebe0ace2) SHA1(fa919797c243d06761e3fa04b548679b310f0542) )
|
ROM_LOAD( "a000", 0xa000, 0x1000, CRC(ebe0ace2) SHA1(fa919797c243d06761e3fa04b548679b310f0542) )
|
||||||
ROM_LOAD( "b000", 0xb000, 0x1000, CRC(b14f33e2) SHA1(f8b2c6cc6907b379786e246ccd559316d3edffb3) )
|
ROM_LOAD( "b000", 0xb000, 0x1000, CRC(b14f33e2) SHA1(f8b2c6cc6907b379786e246ccd559316d3edffb3) )
|
||||||
ROM_LOAD( "c000", 0xc000, 0x1000, CRC(79b8af00) SHA1(53e31962d2124bfe06afc6374d5fb2d87bf9e952) )
|
ROM_LOAD( "c000", 0xc000, 0x1000, CRC(79b8af00) SHA1(53e31962d2124bfe06afc6374d5fb2d87bf9e952) )
|
||||||
ROM_LOAD( "d000", 0xd000, 0x1000, CRC(10ac77c3) SHA1(f7b832974c224341f67fc4c3d151d8978774b462) )
|
ROM_LOAD( "d000", 0xd000, 0x1000, CRC(10ac77c3) SHA1(f7b832974c224341f67fc4c3d151d8978774b462) )
|
||||||
ROM_LOAD( "e000", 0xe000, 0x1000, CRC(dfdda385) SHA1(ac77411722842033027b1717ac1b494507153e55) )
|
ROM_LOAD( "e000", 0xe000, 0x1000, CRC(dfdda385) SHA1(ac77411722842033027b1717ac1b494507153e55) )
|
||||||
ROM_RELOAD( 0xf000, 0x1000 ) /* for reset/interrupt vectors */
|
ROM_RELOAD( 0xf000, 0x1000 ) /* for reset/interrupt vectors */
|
||||||
|
|
||||||
/* AVG PROM */
|
/* AVG PROM */
|
||||||
ROM_REGION( 0x100, "avg:prom", 0 )
|
ROM_REGION( 0x100, "avg:prom", 0 )
|
||||||
|
@ -33,8 +33,8 @@ namespace {
|
|||||||
class srumbler_state : public driver_device
|
class srumbler_state : public driver_device
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
srumbler_state(const machine_config &mconfig, device_type type, const char *tag)
|
srumbler_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||||
: driver_device(mconfig, type, tag),
|
driver_device(mconfig, type, tag),
|
||||||
m_maincpu(*this,"maincpu"),
|
m_maincpu(*this,"maincpu"),
|
||||||
m_spriteram(*this,"spriteram"),
|
m_spriteram(*this,"spriteram"),
|
||||||
m_gfxdecode(*this, "gfxdecode"),
|
m_gfxdecode(*this, "gfxdecode"),
|
||||||
|
@ -15,9 +15,11 @@ graphics are 3bpp instead of 2)
|
|||||||
TODO:
|
TODO:
|
||||||
- verify timings of sound/music on Swimmer
|
- verify timings of sound/music on Swimmer
|
||||||
- add tms5110 support to bagmanf
|
- add tms5110 support to bagmanf
|
||||||
- yamato bg gradient color decode & table selection
|
|
||||||
- toprollr Coin_B 2C_1C doesn't work right, is it a BTANB?
|
- toprollr Coin_B 2C_1C doesn't work right, is it a BTANB?
|
||||||
|
|
||||||
|
BTANB:
|
||||||
|
- yamato shot and missile sound effects block the bg music
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
|
|
||||||
Crazy Climber memory map (preliminary)
|
Crazy Climber memory map (preliminary)
|
||||||
@ -127,34 +129,34 @@ I/O C ;AY-3-8910 Data Read Reg.
|
|||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
|
|
||||||
T.S. 17.12.2005:
|
|
||||||
|
|
||||||
Yamato:
|
Yamato:
|
||||||
-------
|
-------
|
||||||
Added temporary bg gradient (bad colors/offset).
|
Gradient tables are stored in two ROMs. Each table is 256 bytes
|
||||||
|
long: 128 for normal and 128 bytes for flipped screen.
|
||||||
|
Color format is direct RGB mapping of 16 bits.
|
||||||
|
|
||||||
Gradient table are stored in two(?) ROMs.
|
At the title screen, it's a solid dark-cyan. During gameplay,
|
||||||
Each table is 256 bytes long: 128 for normal
|
the sky is a cyan gradient, and the sea is a dark blue gradient.
|
||||||
and 128 bytes for flipped screen.
|
When the player ship explodes, the sky and sea briefly turn to a
|
||||||
Color format is unknown - probably direct RGB
|
lighter cyan gradient, followed by cyan-pink for the sky,
|
||||||
mapping of 8 or 16 (both roms) bits. Also table
|
and purple-red for the sea.
|
||||||
selection source is unknown.
|
|
||||||
|
|
||||||
At the title screen, it's a solid dark-cyan.
|
|
||||||
During gameplay, the sky is a cyan gradient, and
|
|
||||||
the sea is a dark blue gradient. When the player
|
|
||||||
ship explodes, the sky and sea briefly turn to a
|
|
||||||
lighter cyan gradient, followed by cyan-pink for
|
|
||||||
the sky, and purple-red for the sea.
|
|
||||||
|
|
||||||
|
|
||||||
Top Roller:
|
Top Roller:
|
||||||
----------
|
----------
|
||||||
It's made by the same developers as Yamato (apparently
|
It's made by the same developers as Yamato (apparently Falcon)
|
||||||
Falcon) and probably uses the same encrypted SEGA cpu.
|
and probably uses the same encrypted SEGA cpu.
|
||||||
|
|
||||||
lives - $6155
|
lives - $6155
|
||||||
|
|
||||||
|
Cannon Ball
|
||||||
|
-----------
|
||||||
|
The Cannon Ball bootlegs on this Falcon (Crazy Kong) hardware
|
||||||
|
don't correctly handle the protection device found on the original
|
||||||
|
pacman hardware conversion, this causes them to crash after the
|
||||||
|
a few rounds - confirmed on an original PCB. They clearly weren't
|
||||||
|
tested properly by the bootleggers.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
|
|
||||||
Top Roller
|
Top Roller
|
||||||
@ -220,13 +222,143 @@ Notes:
|
|||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
|
|
||||||
Cannon Ball
|
Donkey King
|
||||||
-----------
|
1981 (bootleg)
|
||||||
|
|
||||||
The Cannon Ball bootlegs on this Falcon (Crazy Kong) hardware don't correctly
|
This game runs on dedicated hardware.
|
||||||
handle the protection device found on the original pacman hardware conversion,
|
|
||||||
this causes them to crash after the a few rounds - confirmed on an original PCB.
|
Possibly bootlegged by Hafasonic?
|
||||||
They clearly weren't tested properly by the bootleggers.
|
|
||||||
|
CPU Board
|
||||||
|
---------
|
||||||
|
|
||||||
|
MTD-2
|
||||||
|
|-----------------------------------------|
|
||||||
|
|C1181 VOL D5.1K D7.1N |
|
||||||
|
| LM3900 D6.1M D8.1R |
|
||||||
|
| |
|
||||||
|
| 6116 D10.2N |
|
||||||
|
| D9.2M D11.2R|
|
||||||
|
| 4066 |
|
||||||
|
| AY3-8910 |
|
||||||
|
| PAL12L6|
|
||||||
|
| |
|
||||||
|
|1 |
|
||||||
|
|8 2114 2114 |
|
||||||
|
|W |
|
||||||
|
|A |
|
||||||
|
|Y |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| Z80A |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| DSW(8) 82S129.5G |
|
||||||
|
| |
|
||||||
|
|-----------------------------------------|
|
||||||
|
Notes:
|
||||||
|
Z80 clock - 3.072MHz [18.432/6]
|
||||||
|
AY3-8910 clock - 1.536MHz [18.432/12]
|
||||||
|
HSync - 15.5065kHz
|
||||||
|
VSync - 60.5608Hz
|
||||||
|
|
||||||
|
|
||||||
|
Video Board
|
||||||
|
-----------
|
||||||
|
|
||||||
|
MTD-2B
|
||||||
|
|-----------------------------------------|
|
||||||
|
| 18.432MHz 82S123.1T |
|
||||||
|
| 2114 82S123.1U |
|
||||||
|
| 2114 82S123.1V|
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
|2101 2101 2114 2114 |
|
||||||
|
| |
|
||||||
|
|D12.6A D1.6H D3.6L 2115 2115 2115|
|
||||||
|
| D13.6C D2.6K D4.6N |
|
||||||
|
| |
|
||||||
|
| |
|
||||||
|
| 2115 2115 2125|
|
||||||
|
| |
|
||||||
|
|-----------------------------------------|
|
||||||
|
|
||||||
|
|
||||||
|
18-way Pinout
|
||||||
|
-------------
|
||||||
|
|
||||||
|
Parts Solder
|
||||||
|
-------------------------
|
||||||
|
GND 1 GND
|
||||||
|
GND 2 GND
|
||||||
|
GND 3 GND
|
||||||
|
SPK- 4 SPK+
|
||||||
|
+12V 5 +12V
|
||||||
|
6 P1 UP
|
||||||
|
7 P2 UP
|
||||||
|
8 VIDEO GND
|
||||||
|
+5V 9 +5V
|
||||||
|
P1 DOWN 10
|
||||||
|
P2 DOWN 11
|
||||||
|
12 P2 START
|
||||||
|
COIN 13 P1 START
|
||||||
|
P1 JUMP 14 P1 RIGHT
|
||||||
|
RED 15 P1 LEFT
|
||||||
|
P2 RIGHT 16 BLUE
|
||||||
|
P2 LEFT 17 GREEN
|
||||||
|
P2 JUMP 18 SYNC
|
||||||
|
|
||||||
|
|
||||||
|
Dip Switch - Donkey King
|
||||||
|
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 |
|
||||||
|
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
|Life 3 | OFF | OFF | | | | | | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 4 | ON | OFF | | | | | | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 5 | OFF | ON | | | | | | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 6 | ON | ON | | | | | | |
|
||||||
|
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
|Bonus 7000 | | | OFF | OFF | | | | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 10000 | | | ON | OFF | | | | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 15000 | | | OFF | ON | | | | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 20000 | | | ON | ON | | | | |
|
||||||
|
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
|Credit 1C 1P | | | | | OFF | OFF | OFF | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 1C 2P | | | | | OFF | ON | OFF | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 1C 3P | | | | | OFF | OFF | ON | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 1C 4P | | | | | OFF | ON | ON | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 2C 1P | | | | | ON | OFF | OFF | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 3C 1P | | | | | ON | ON | OFF | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 4C 1P | | | | | ON | OFF | ON | |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| 5C 1P | | | | | ON | ON | ON | |
|
||||||
|
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
|Screen Table | | | | | | | | OFF |
|
||||||
|
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
| Upright | | | | | | | | ON |
|
||||||
|
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
||||||
|
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
@ -1435,7 +1567,7 @@ void cclimber_state::bagmanf(machine_config &config)
|
|||||||
// basic machine hardware
|
// basic machine hardware
|
||||||
m_maincpu->set_addrmap(AS_PROGRAM, &cclimber_state::bagmanf_map);
|
m_maincpu->set_addrmap(AS_PROGRAM, &cclimber_state::bagmanf_map);
|
||||||
|
|
||||||
subdevice<screen_device>("screen")->screen_vblank().set(FUNC(cclimber_state::bagmanf_vblank_irq));
|
m_screen->screen_vblank().set(FUNC(cclimber_state::bagmanf_vblank_irq));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1455,10 +1587,10 @@ void yamato_state::yamato(machine_config &config)
|
|||||||
m_audiocpu->set_addrmap(AS_IO, &yamato_state::yamato_audio_portmap);
|
m_audiocpu->set_addrmap(AS_IO, &yamato_state::yamato_audio_portmap);
|
||||||
|
|
||||||
// video hardware
|
// video hardware
|
||||||
m_palette->set_entries(16*4+8*4+256);
|
|
||||||
m_palette->set_init(FUNC(yamato_state::yamato_palette));
|
m_palette->set_init(FUNC(yamato_state::yamato_palette));
|
||||||
|
|
||||||
subdevice<screen_device>("screen")->set_screen_update(FUNC(yamato_state::screen_update_yamato));
|
m_screen->set_screen_update(FUNC(yamato_state::screen_update_yamato));
|
||||||
|
m_screen->set_no_palette();
|
||||||
|
|
||||||
// audio hardware
|
// audio hardware
|
||||||
GENERIC_LATCH_8(config, "soundlatch1");
|
GENERIC_LATCH_8(config, "soundlatch1");
|
||||||
@ -1492,7 +1624,7 @@ void toprollr_state::toprollr(machine_config &config)
|
|||||||
m_palette->set_entries(32*5);
|
m_palette->set_entries(32*5);
|
||||||
m_palette->set_init(FUNC(toprollr_state::toprollr_palette));
|
m_palette->set_init(FUNC(toprollr_state::toprollr_palette));
|
||||||
|
|
||||||
subdevice<screen_device>("screen")->set_screen_update(FUNC(toprollr_state::screen_update_toprollr));
|
m_screen->set_screen_update(FUNC(toprollr_state::screen_update_toprollr));
|
||||||
|
|
||||||
// audio hardware
|
// audio hardware
|
||||||
subdevice<cclimber_audio_device>("cclimber_audio")->set_clock(12_MHz_XTAL/8);
|
subdevice<cclimber_audio_device>("cclimber_audio")->set_clock(12_MHz_XTAL/8);
|
||||||
@ -2228,144 +2360,6 @@ ROM_START( monkeyd )
|
|||||||
ROM_END
|
ROM_END
|
||||||
|
|
||||||
|
|
||||||
/* Donkey King
|
|
||||||
1981 (bootleg)
|
|
||||||
|
|
||||||
This game runs on dedicated hardware.
|
|
||||||
|
|
||||||
Possibly bootlegged by Hafasonic?
|
|
||||||
|
|
||||||
CPU Board
|
|
||||||
---------
|
|
||||||
|
|
||||||
MTD-2
|
|
||||||
|-----------------------------------------|
|
|
||||||
|C1181 VOL D5.1K D7.1N |
|
|
||||||
| LM3900 D6.1M D8.1R |
|
|
||||||
| |
|
|
||||||
| 6116 D10.2N |
|
|
||||||
| D9.2M D11.2R|
|
|
||||||
| 4066 |
|
|
||||||
| AY3-8910 |
|
|
||||||
| PAL12L6|
|
|
||||||
| |
|
|
||||||
|1 |
|
|
||||||
|8 2114 2114 |
|
|
||||||
|W |
|
|
||||||
|A |
|
|
||||||
|Y |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| Z80A |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| DSW(8) 82S129.5G |
|
|
||||||
| |
|
|
||||||
|-----------------------------------------|
|
|
||||||
Notes:
|
|
||||||
Z80 clock - 3.072MHz [18.432/6]
|
|
||||||
AY3-8910 clock - 1.536MHz [18.432/12]
|
|
||||||
HSync - 15.5065kHz
|
|
||||||
VSync - 60.5608Hz
|
|
||||||
|
|
||||||
|
|
||||||
Video Board
|
|
||||||
-----------
|
|
||||||
|
|
||||||
MTD-2B
|
|
||||||
|-----------------------------------------|
|
|
||||||
| 18.432MHz 82S123.1T |
|
|
||||||
| 2114 82S123.1U |
|
|
||||||
| 2114 82S123.1V|
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
|2101 2101 2114 2114 |
|
|
||||||
| |
|
|
||||||
|D12.6A D1.6H D3.6L 2115 2115 2115|
|
|
||||||
| D13.6C D2.6K D4.6N |
|
|
||||||
| |
|
|
||||||
| |
|
|
||||||
| 2115 2115 2125|
|
|
||||||
| |
|
|
||||||
|-----------------------------------------|
|
|
||||||
|
|
||||||
|
|
||||||
18-way Pinout
|
|
||||||
-------------
|
|
||||||
|
|
||||||
Parts Solder
|
|
||||||
-------------------------
|
|
||||||
GND 1 GND
|
|
||||||
GND 2 GND
|
|
||||||
GND 3 GND
|
|
||||||
SPK- 4 SPK+
|
|
||||||
+12V 5 +12V
|
|
||||||
6 P1 UP
|
|
||||||
7 P2 UP
|
|
||||||
8 VIDEO GND
|
|
||||||
+5V 9 +5V
|
|
||||||
P1 DOWN 10
|
|
||||||
P2 DOWN 11
|
|
||||||
12 P2 START
|
|
||||||
COIN 13 P1 START
|
|
||||||
P1 JUMP 14 P1 RIGHT
|
|
||||||
RED 15 P1 LEFT
|
|
||||||
P2 RIGHT 16 BLUE
|
|
||||||
P2 LEFT 17 GREEN
|
|
||||||
P2 JUMP 18 SYNC
|
|
||||||
|
|
||||||
|
|
||||||
Dip Switch - Donkey King
|
|
||||||
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 |
|
|
||||||
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
|Life 3 | OFF | OFF | | | | | | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 4 | ON | OFF | | | | | | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 5 | OFF | ON | | | | | | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 6 | ON | ON | | | | | | |
|
|
||||||
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
|Bonus 7000 | | | OFF | OFF | | | | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 10000 | | | ON | OFF | | | | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 15000 | | | OFF | ON | | | | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 20000 | | | ON | ON | | | | |
|
|
||||||
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
|Credit 1C 1P | | | | | OFF | OFF | OFF | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 1C 2P | | | | | OFF | ON | OFF | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 1C 3P | | | | | OFF | OFF | ON | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 1C 4P | | | | | OFF | ON | ON | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 2C 1P | | | | | ON | OFF | OFF | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 3C 1P | | | | | ON | ON | OFF | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 4C 1P | | | | | ON | OFF | ON | |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| 5C 1P | | | | | ON | ON | ON | |
|
|
||||||
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
|Screen Table | | | | | | | | OFF |
|
|
||||||
| +-----+-----+-----+-----+-----+-----+-----+-----+
|
|
||||||
| Upright | | | | | | | | ON |
|
|
||||||
+----------------+-----+-----+-----+-----+-----+-----+-----+-----+ */
|
|
||||||
|
|
||||||
ROM_START( dking )
|
ROM_START( dking )
|
||||||
ROM_REGION( 0x6000, "maincpu", 0 )
|
ROM_REGION( 0x6000, "maincpu", 0 )
|
||||||
ROM_LOAD( "d11.r2", 0x0800, 0x0800, CRC(f7cace41) SHA1(981dbb1cddd66a0cbc8fe147172ffe7eb5b7fa21) )
|
ROM_LOAD( "d11.r2", 0x0800, 0x0800, CRC(f7cace41) SHA1(981dbb1cddd66a0cbc8fe147172ffe7eb5b7fa21) )
|
||||||
@ -2958,8 +2952,8 @@ ROM_START( yamato )
|
|||||||
ROM_LOAD( "8.11c", 0x0000, 0x1000, CRC(28024d9a) SHA1(c871c4d74be72a8bfea99e89d43f91922f4b734b) )
|
ROM_LOAD( "8.11c", 0x0000, 0x1000, CRC(28024d9a) SHA1(c871c4d74be72a8bfea99e89d43f91922f4b734b) )
|
||||||
ROM_LOAD( "7.11a", 0x1000, 0x1000, CRC(4a179790) SHA1(7fb6b033de939ff8bd13055c073311dca2c1a6fe) )
|
ROM_LOAD( "7.11a", 0x1000, 0x1000, CRC(4a179790) SHA1(7fb6b033de939ff8bd13055c073311dca2c1a6fe) )
|
||||||
|
|
||||||
ROM_REGION( 0x2000, "user1", 0 )
|
ROM_REGION( 0x2000, "gradient", 0 )
|
||||||
ROM_LOAD( "5.5lm", 0x0000, 0x1000, CRC(7761ad24) SHA1(98878b19addd142d35718080eece05eaaee0388d) ) // ??
|
ROM_LOAD( "5.5lm", 0x0000, 0x1000, CRC(7761ad24) SHA1(98878b19addd142d35718080eece05eaaee0388d) )
|
||||||
ROM_LOAD( "6.5n", 0x1000, 0x1000, CRC(da48444c) SHA1(a43e672ce262eb817fb4e5715ef4fb304a6a2815) )
|
ROM_LOAD( "6.5n", 0x1000, 0x1000, CRC(da48444c) SHA1(a43e672ce262eb817fb4e5715ef4fb304a6a2815) )
|
||||||
|
|
||||||
ROM_REGION( 0x00a0, "proms", 0 )
|
ROM_REGION( 0x00a0, "proms", 0 )
|
||||||
@ -2989,8 +2983,8 @@ ROM_START( yamato2 )
|
|||||||
ROM_LOAD( "8.11c", 0x0000, 0x1000, CRC(28024d9a) SHA1(c871c4d74be72a8bfea99e89d43f91922f4b734b) )
|
ROM_LOAD( "8.11c", 0x0000, 0x1000, CRC(28024d9a) SHA1(c871c4d74be72a8bfea99e89d43f91922f4b734b) )
|
||||||
ROM_LOAD( "7.11a", 0x1000, 0x1000, CRC(4a179790) SHA1(7fb6b033de939ff8bd13055c073311dca2c1a6fe) )
|
ROM_LOAD( "7.11a", 0x1000, 0x1000, CRC(4a179790) SHA1(7fb6b033de939ff8bd13055c073311dca2c1a6fe) )
|
||||||
|
|
||||||
ROM_REGION( 0x2000, "user1", 0 )
|
ROM_REGION( 0x2000, "gradient", 0 )
|
||||||
ROM_LOAD( "5.5lm", 0x0000, 0x1000, CRC(7761ad24) SHA1(98878b19addd142d35718080eece05eaaee0388d) ) // ??
|
ROM_LOAD( "5.5lm", 0x0000, 0x1000, CRC(7761ad24) SHA1(98878b19addd142d35718080eece05eaaee0388d) )
|
||||||
ROM_LOAD( "6.5n", 0x1000, 0x1000, CRC(da48444c) SHA1(a43e672ce262eb817fb4e5715ef4fb304a6a2815) )
|
ROM_LOAD( "6.5n", 0x1000, 0x1000, CRC(da48444c) SHA1(a43e672ce262eb817fb4e5715ef4fb304a6a2815) )
|
||||||
|
|
||||||
ROM_REGION( 0x00a0, "proms", 0 )
|
ROM_REGION( 0x00a0, "proms", 0 )
|
||||||
@ -3143,7 +3137,7 @@ GAME( 1983, guzzlers, guzzler, guzzler, guzzler, swimmer_state, empty_i
|
|||||||
|
|
||||||
GAME( 1983, au, 0, au, au, swimmer_state, empty_init, ROT90, "Tehkan", "Au (location test)", MACHINE_SUPPORTS_SAVE )
|
GAME( 1983, au, 0, au, au, swimmer_state, empty_init, ROT90, "Tehkan", "Au (location test)", MACHINE_SUPPORTS_SAVE )
|
||||||
|
|
||||||
GAME( 1983, yamato, 0, yamato, yamato, yamato_state, empty_init, ROT90, "Sega", "Yamato (US)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_SUPPORTS_SAVE )
|
GAME( 1983, yamato, 0, yamato, yamato, yamato_state, empty_init, ROT90, "Sega", "Yamato (US)", MACHINE_SUPPORTS_SAVE )
|
||||||
GAME( 1983, yamato2, yamato, yamato, yamato2, yamato_state, empty_init, ROT90, "Sega", "Yamato (World?)", MACHINE_IMPERFECT_GRAPHICS | MACHINE_SUPPORTS_SAVE )
|
GAME( 1983, yamato2, yamato, yamato, yamato2, yamato_state, empty_init, ROT90, "Sega", "Yamato (World?)", MACHINE_SUPPORTS_SAVE )
|
||||||
|
|
||||||
GAME( 1983, toprollr, 0, toprollr, toprollr, toprollr_state, init_toprollr, ROT90, "Jaleco", "Top Roller", MACHINE_SUPPORTS_SAVE )
|
GAME( 1983, toprollr, 0, toprollr, toprollr, toprollr_state, init_toprollr, ROT90, "Jaleco", "Top Roller", MACHINE_SUPPORTS_SAVE )
|
||||||
|
@ -57,7 +57,7 @@ protected:
|
|||||||
|
|
||||||
required_device<cpu_device> m_maincpu;
|
required_device<cpu_device> m_maincpu;
|
||||||
optional_device<cpu_device> m_audiocpu;
|
optional_device<cpu_device> m_audiocpu;
|
||||||
optional_device<screen_device> m_screen;
|
required_device<screen_device> m_screen;
|
||||||
required_device<gfxdecode_device> m_gfxdecode;
|
required_device<gfxdecode_device> m_gfxdecode;
|
||||||
required_device<palette_device> m_palette;
|
required_device<palette_device> m_palette;
|
||||||
required_device<ls259_device> m_mainlatch;
|
required_device<ls259_device> m_mainlatch;
|
||||||
@ -69,6 +69,12 @@ protected:
|
|||||||
|
|
||||||
std::unique_ptr<uint8_t[]> m_opcodes;
|
std::unique_ptr<uint8_t[]> m_opcodes;
|
||||||
|
|
||||||
|
bool m_flip_x = false;
|
||||||
|
bool m_flip_y = false;
|
||||||
|
|
||||||
|
tilemap_t *m_pf_tilemap = nullptr;
|
||||||
|
tilemap_t *m_bs_tilemap = nullptr;
|
||||||
|
|
||||||
void nmi_mask_w(int state);
|
void nmi_mask_w(int state);
|
||||||
void cclimber_colorram_w(offs_t offset, uint8_t data);
|
void cclimber_colorram_w(offs_t offset, uint8_t data);
|
||||||
void flip_screen_x_w(int state);
|
void flip_screen_x_w(int state);
|
||||||
@ -78,12 +84,6 @@ protected:
|
|||||||
|
|
||||||
void vblank_irq(int state);
|
void vblank_irq(int state);
|
||||||
|
|
||||||
bool m_flip_x = false;
|
|
||||||
bool m_flip_y = false;
|
|
||||||
|
|
||||||
tilemap_t *m_pf_tilemap = nullptr;
|
|
||||||
tilemap_t *m_bs_tilemap = nullptr;
|
|
||||||
|
|
||||||
TILE_GET_INFO_MEMBER(cclimber_get_pf_tile_info);
|
TILE_GET_INFO_MEMBER(cclimber_get_pf_tile_info);
|
||||||
TILE_GET_INFO_MEMBER(cclimber_get_bs_tile_info);
|
TILE_GET_INFO_MEMBER(cclimber_get_bs_tile_info);
|
||||||
|
|
||||||
@ -137,6 +137,12 @@ private:
|
|||||||
optional_shared_ptr<uint8_t> m_swimmer_background_color;
|
optional_shared_ptr<uint8_t> m_swimmer_background_color;
|
||||||
optional_device<generic_latch_8_device> m_soundlatch;
|
optional_device<generic_latch_8_device> m_soundlatch;
|
||||||
|
|
||||||
|
static constexpr int SWIMMER_BG_SPLIT = 0x18 * 8;
|
||||||
|
|
||||||
|
bool m_side_background_enabled = false;
|
||||||
|
bool m_palettebank = false;
|
||||||
|
uint16_t m_sidepen = 0;
|
||||||
|
|
||||||
uint8_t soundlatch_read_and_clear();
|
uint8_t soundlatch_read_and_clear();
|
||||||
void swimmer_sh_soundlatch_w(uint8_t data);
|
void swimmer_sh_soundlatch_w(uint8_t data);
|
||||||
void sidebg_enable_w(int state);
|
void sidebg_enable_w(int state);
|
||||||
@ -155,12 +161,6 @@ private:
|
|||||||
void set_background_pen();
|
void set_background_pen();
|
||||||
void set_sidepen(uint16_t pen) { m_sidepen = pen; }
|
void set_sidepen(uint16_t pen) { m_sidepen = pen; }
|
||||||
TILE_GET_INFO_MEMBER(swimmer_get_pf_tile_info);
|
TILE_GET_INFO_MEMBER(swimmer_get_pf_tile_info);
|
||||||
|
|
||||||
bool m_side_background_enabled = false;
|
|
||||||
bool m_palettebank = false;
|
|
||||||
uint16_t m_sidepen = 0;
|
|
||||||
|
|
||||||
static constexpr int SWIMMER_BG_SPLIT = 0x18 * 8;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class toprollr_state : public cclimber_state
|
class toprollr_state : public cclimber_state
|
||||||
@ -187,6 +187,8 @@ private:
|
|||||||
required_memory_bank m_bank1;
|
required_memory_bank m_bank1;
|
||||||
required_memory_bank m_bank1d;
|
required_memory_bank m_bank1d;
|
||||||
|
|
||||||
|
tilemap_t *m_bg_tilemap = nullptr;
|
||||||
|
|
||||||
void toprollr_decrypted_opcodes_map(address_map &map) ATTR_COLD;
|
void toprollr_decrypted_opcodes_map(address_map &map) ATTR_COLD;
|
||||||
void toprollr_map(address_map &map) ATTR_COLD;
|
void toprollr_map(address_map &map) ATTR_COLD;
|
||||||
|
|
||||||
@ -197,20 +199,26 @@ private:
|
|||||||
TILE_GET_INFO_MEMBER(toprollr_get_pf_tile_info);
|
TILE_GET_INFO_MEMBER(toprollr_get_pf_tile_info);
|
||||||
TILE_GET_INFO_MEMBER(toprollr_get_bs_tile_info);
|
TILE_GET_INFO_MEMBER(toprollr_get_bs_tile_info);
|
||||||
TILE_GET_INFO_MEMBER(toproller_get_bg_tile_info);
|
TILE_GET_INFO_MEMBER(toproller_get_bg_tile_info);
|
||||||
|
|
||||||
tilemap_t *m_bg_tilemap = nullptr;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
class yamato_state : public cclimber_state
|
class yamato_state : public cclimber_state
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
yamato_state(const machine_config &mconfig, device_type type, const char* tag) :
|
yamato_state(const machine_config &mconfig, device_type type, const char* tag) :
|
||||||
cclimber_state(mconfig, type, tag)
|
cclimber_state(mconfig, type, tag),
|
||||||
|
m_gradient_rom(*this, "gradient")
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
void yamato(machine_config &config);
|
void yamato(machine_config &config);
|
||||||
|
|
||||||
|
protected:
|
||||||
|
virtual void video_start() override ATTR_COLD;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
required_region_ptr<uint8_t> m_gradient_rom;
|
||||||
|
|
||||||
|
bitmap_ind16 m_dest_bitmap;
|
||||||
|
|
||||||
void yamato_map(address_map &map) ATTR_COLD;
|
void yamato_map(address_map &map) ATTR_COLD;
|
||||||
void yamato_decrypted_opcodes_map(address_map &map) ATTR_COLD;
|
void yamato_decrypted_opcodes_map(address_map &map) ATTR_COLD;
|
||||||
void yamato_portmap(address_map &map) ATTR_COLD;
|
void yamato_portmap(address_map &map) ATTR_COLD;
|
||||||
@ -218,9 +226,7 @@ private:
|
|||||||
void yamato_audio_portmap(address_map &map) ATTR_COLD;
|
void yamato_audio_portmap(address_map &map) ATTR_COLD;
|
||||||
|
|
||||||
void yamato_palette(palette_device &palette) const;
|
void yamato_palette(palette_device &palette) const;
|
||||||
uint32_t screen_update_yamato(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
uint32_t screen_update_yamato(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
|
||||||
|
|
||||||
static constexpr int YAMATO_SKY_PEN_BASE = 0x60;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // MAME_NICHIBUTSU_CCLIMBER_H
|
#endif // MAME_NICHIBUTSU_CCLIMBER_H
|
||||||
|
@ -229,10 +229,6 @@ void yamato_state::yamato_palette(palette_device &palette) const
|
|||||||
|
|
||||||
palette.set_pen_color(i + 0x40, rgb_t(r, g, b));
|
palette.set_pen_color(i + 0x40, rgb_t(r, g, b));
|
||||||
}
|
}
|
||||||
|
|
||||||
// fake colors for bg gradient
|
|
||||||
for (int i = 0; i < 0x100; i++)
|
|
||||||
palette.set_pen_color(YAMATO_SKY_PEN_BASE + i, rgb_t(0, 0, i));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -288,19 +284,19 @@ void swimmer_state::set_background_pen()
|
|||||||
{
|
{
|
||||||
int bit0, bit1, bit2;
|
int bit0, bit1, bit2;
|
||||||
|
|
||||||
/* red component */
|
// red component
|
||||||
bit0 = 0;
|
bit0 = 0;
|
||||||
bit1 = (*m_swimmer_background_color >> 6) & 0x01;
|
bit1 = (*m_swimmer_background_color >> 6) & 0x01;
|
||||||
bit2 = (*m_swimmer_background_color >> 7) & 0x01;
|
bit2 = (*m_swimmer_background_color >> 7) & 0x01;
|
||||||
int const r = 0x20 * bit0 + 0x40 * bit1 + 0x80 * bit2;
|
int const r = 0x20 * bit0 + 0x40 * bit1 + 0x80 * bit2;
|
||||||
|
|
||||||
/* green component */
|
// green component
|
||||||
bit0 = (*m_swimmer_background_color >> 3) & 0x01;
|
bit0 = (*m_swimmer_background_color >> 3) & 0x01;
|
||||||
bit1 = (*m_swimmer_background_color >> 4) & 0x01;
|
bit1 = (*m_swimmer_background_color >> 4) & 0x01;
|
||||||
bit2 = (*m_swimmer_background_color >> 5) & 0x01;
|
bit2 = (*m_swimmer_background_color >> 5) & 0x01;
|
||||||
int const g = 0x20 * bit0 + 0x40 * bit1 + 0x80 * bit2;
|
int const g = 0x20 * bit0 + 0x40 * bit1 + 0x80 * bit2;
|
||||||
|
|
||||||
/* blue component */
|
// blue component
|
||||||
bit0 = (*m_swimmer_background_color >> 0) & 0x01;
|
bit0 = (*m_swimmer_background_color >> 0) & 0x01;
|
||||||
bit1 = (*m_swimmer_background_color >> 1) & 0x01;
|
bit1 = (*m_swimmer_background_color >> 1) & 0x01;
|
||||||
bit2 = (*m_swimmer_background_color >> 2) & 0x01;
|
bit2 = (*m_swimmer_background_color >> 2) & 0x01;
|
||||||
@ -312,7 +308,7 @@ void swimmer_state::set_background_pen()
|
|||||||
|
|
||||||
void cclimber_state::cclimber_colorram_w(offs_t offset, uint8_t data)
|
void cclimber_state::cclimber_colorram_w(offs_t offset, uint8_t data)
|
||||||
{
|
{
|
||||||
/* A5 is not connected, there is only 0x200 bytes of RAM */
|
// A5 is not connected, there is only 0x200 bytes of RAM
|
||||||
m_colorram[offset & ~0x20] = data;
|
m_colorram[offset & ~0x20] = data;
|
||||||
m_colorram[offset | 0x20] = data;
|
m_colorram[offset | 0x20] = data;
|
||||||
}
|
}
|
||||||
@ -346,7 +342,7 @@ TILE_GET_INFO_MEMBER(cclimber_state::cclimber_get_pf_tile_info)
|
|||||||
{
|
{
|
||||||
const int flags = TILE_FLIPYX(m_colorram[tile_index] >> 6);
|
const int flags = TILE_FLIPYX(m_colorram[tile_index] >> 6);
|
||||||
|
|
||||||
/* vertical flipping flips two adjacent characters */
|
// vertical flipping flips two adjacent characters
|
||||||
if (flags & 0x02)
|
if (flags & 0x02)
|
||||||
tile_index = tile_index ^ 0x20;
|
tile_index = tile_index ^ 0x20;
|
||||||
|
|
||||||
@ -363,7 +359,7 @@ TILE_GET_INFO_MEMBER(swimmer_state::swimmer_get_pf_tile_info)
|
|||||||
{
|
{
|
||||||
const int flags = TILE_FLIPYX(m_colorram[tile_index] >> 6);
|
const int flags = TILE_FLIPYX(m_colorram[tile_index] >> 6);
|
||||||
|
|
||||||
/* vertical flipping flips two adjacent characters */
|
// vertical flipping flips two adjacent characters
|
||||||
if (flags & 0x02)
|
if (flags & 0x02)
|
||||||
tile_index = tile_index ^ 0x20;
|
tile_index = tile_index ^ 0x20;
|
||||||
|
|
||||||
@ -386,10 +382,10 @@ TILE_GET_INFO_MEMBER(toprollr_state::toprollr_get_pf_tile_info)
|
|||||||
|
|
||||||
TILE_GET_INFO_MEMBER(cclimber_state::cclimber_get_bs_tile_info)
|
TILE_GET_INFO_MEMBER(cclimber_state::cclimber_get_bs_tile_info)
|
||||||
{
|
{
|
||||||
/* only the lower right is visible */
|
// only the lower right is visible
|
||||||
tileinfo.group = ((tile_index & 0x210) == 0x210) ? 0 : 1;
|
tileinfo.group = ((tile_index & 0x210) == 0x210) ? 0 : 1;
|
||||||
|
|
||||||
/* the address doesn't use A4 of the coordinates, giving a 16x16 map */
|
// the address doesn't use A4 of the coordinates, giving a 16x16 map
|
||||||
tile_index = ((tile_index & 0x1e0) >> 1) | (tile_index & 0x0f);
|
tile_index = ((tile_index & 0x1e0) >> 1) | (tile_index & 0x0f);
|
||||||
|
|
||||||
const int code = ((m_bigsprite_control[1] & 0x08) << 5) | m_bigsprite_videoram[tile_index];
|
const int code = ((m_bigsprite_control[1] & 0x08) << 5) | m_bigsprite_videoram[tile_index];
|
||||||
@ -401,10 +397,10 @@ TILE_GET_INFO_MEMBER(cclimber_state::cclimber_get_bs_tile_info)
|
|||||||
|
|
||||||
TILE_GET_INFO_MEMBER(toprollr_state::toprollr_get_bs_tile_info)
|
TILE_GET_INFO_MEMBER(toprollr_state::toprollr_get_bs_tile_info)
|
||||||
{
|
{
|
||||||
/* only the lower right is visible */
|
// only the lower right is visible
|
||||||
tileinfo.group = ((tile_index & 0x210) == 0x210) ? 0 : 1;
|
tileinfo.group = ((tile_index & 0x210) == 0x210) ? 0 : 1;
|
||||||
|
|
||||||
/* the address doesn't use A4 of the coordinates, giving a 16x16 map */
|
// the address doesn't use A4 of the coordinates, giving a 16x16 map
|
||||||
tile_index = ((tile_index & 0x1e0) >> 1) | (tile_index & 0x0f);
|
tile_index = ((tile_index & 0x1e0) >> 1) | (tile_index & 0x0f);
|
||||||
|
|
||||||
const int code = ((m_bigsprite_control[1] & 0x18) << 5) | m_bigsprite_videoram[tile_index];
|
const int code = ((m_bigsprite_control[1] & 0x18) << 5) | m_bigsprite_videoram[tile_index];
|
||||||
@ -439,6 +435,12 @@ void cclimber_state::video_start()
|
|||||||
save_item(NAME(m_flip_y));
|
save_item(NAME(m_flip_y));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void yamato_state::video_start()
|
||||||
|
{
|
||||||
|
cclimber_state::video_start();
|
||||||
|
m_screen->register_screen_bitmap(m_dest_bitmap);
|
||||||
|
}
|
||||||
|
|
||||||
void swimmer_state::video_start()
|
void swimmer_state::video_start()
|
||||||
{
|
{
|
||||||
m_pf_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(swimmer_state::swimmer_get_pf_tile_info)), TILEMAP_SCAN_ROWS, 8, 8, 32, 32);
|
m_pf_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(swimmer_state::swimmer_get_pf_tile_info)), TILEMAP_SCAN_ROWS, 8, 8, 32, 32);
|
||||||
@ -543,8 +545,8 @@ void cclimber_state::cclimber_draw_sprites(bitmap_ind16 &bitmap, const rectangle
|
|||||||
int y = 240 - m_spriteram[offs + 2];
|
int y = 240 - m_spriteram[offs + 2];
|
||||||
|
|
||||||
int code = ((m_spriteram[offs + 1] & 0x10) << 3) |
|
int code = ((m_spriteram[offs + 1] & 0x10) << 3) |
|
||||||
((m_spriteram[offs + 1] & 0x20) << 1) |
|
((m_spriteram[offs + 1] & 0x20) << 1) |
|
||||||
( m_spriteram[offs + 0] & 0x3f);
|
(m_spriteram[offs + 0] & 0x3f);
|
||||||
|
|
||||||
int color = m_spriteram[offs + 1] & 0x0f;
|
int color = m_spriteram[offs + 1] & 0x0f;
|
||||||
|
|
||||||
@ -578,8 +580,8 @@ void cclimber_state::toprollr_draw_sprites(bitmap_ind16 &bitmap, const rectangle
|
|||||||
int y = 240 - m_spriteram[offs + 2];
|
int y = 240 - m_spriteram[offs + 2];
|
||||||
|
|
||||||
const int code = ((m_spriteram[offs + 1] & 0x10) << 3) |
|
const int code = ((m_spriteram[offs + 1] & 0x10) << 3) |
|
||||||
((m_spriteram[offs + 1] & 0x20) << 1) |
|
((m_spriteram[offs + 1] & 0x20) << 1) |
|
||||||
( m_spriteram[offs + 0] & 0x3f);
|
(m_spriteram[offs + 0] & 0x3f);
|
||||||
|
|
||||||
const int color = m_spriteram[offs + 1] & 0x0f;
|
const int color = m_spriteram[offs + 1] & 0x0f;
|
||||||
|
|
||||||
@ -613,10 +615,10 @@ void swimmer_state::swimmer_draw_sprites(bitmap_ind16 &bitmap, const rectangle &
|
|||||||
int y = 240 - m_spriteram[offs + 2];
|
int y = 240 - m_spriteram[offs + 2];
|
||||||
|
|
||||||
const int code = ((m_spriteram[offs + 1] & 0x30) << 2) |
|
const int code = ((m_spriteram[offs + 1] & 0x30) << 2) |
|
||||||
(m_spriteram[offs + 0] & 0x3f);
|
(m_spriteram[offs + 0] & 0x3f);
|
||||||
|
|
||||||
const int color = (m_palettebank << 4) |
|
const int color = (m_palettebank << 4) |
|
||||||
(m_spriteram[offs + 1] & 0x0f);
|
(m_spriteram[offs + 1] & 0x0f);
|
||||||
|
|
||||||
int flipx = m_spriteram[offs + 0] & 0x40;
|
int flipx = m_spriteram[offs + 0] & 0x40;
|
||||||
int flipy = m_spriteram[offs + 0] & 0x80;
|
int flipy = m_spriteram[offs + 0] & 0x80;
|
||||||
@ -660,31 +662,61 @@ uint32_t cclimber_state::screen_update_cclimber(screen_device &screen, bitmap_in
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
uint32_t yamato_state::screen_update_yamato(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
uint32_t yamato_state::screen_update_yamato(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
|
||||||
{
|
{
|
||||||
uint8_t const *const sky_rom = memregion("user1")->base() + 0x1200;
|
bitmap.fill(0, cliprect);
|
||||||
|
|
||||||
for (int i = 0; i < 0x100; i++)
|
// gradient bank from 74259
|
||||||
|
uint16_t bank = bitswap<3>(m_mainlatch->output_state(),3,5,6) << 8;
|
||||||
|
bank |= m_flip_x ? 0x80 : 0;
|
||||||
|
|
||||||
|
// fill in the gradient
|
||||||
|
for (int i = 0; i < 0x80; i++)
|
||||||
{
|
{
|
||||||
pen_t pen = YAMATO_SKY_PEN_BASE + sky_rom[(m_flip_x ? 0x80 : 0) + (i >> 1)];
|
const uint8_t data0 = m_gradient_rom[0x0000 | bank | i];
|
||||||
|
const uint8_t data1 = m_gradient_rom[0x1000 | bank | i];
|
||||||
|
|
||||||
for (int j = 0; j < 0x100; j++)
|
uint8_t r = pal5bit(data0 & 0x1f);
|
||||||
bitmap.pix(j, (i - 8) & 0xff) = pen;
|
uint8_t g = pal5bit(data0 >> 5 | (data1 << 3 & 0x18));
|
||||||
|
uint8_t b = pal6bit(data1 >> 2);
|
||||||
|
uint32_t color = r << 16 | g << 8 | b;
|
||||||
|
|
||||||
|
for (int y = cliprect.min_y; y <= cliprect.max_y; y++)
|
||||||
|
{
|
||||||
|
int start = (i * 2 - 8) & 0xff;
|
||||||
|
for (int x = start; x < start + 2; x++)
|
||||||
|
{
|
||||||
|
if (cliprect.contains(x, y))
|
||||||
|
bitmap.pix(y, x) = color;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
draw_playfield(screen, bitmap, cliprect);
|
m_dest_bitmap.fill(0xff, cliprect);
|
||||||
|
draw_playfield(screen, m_dest_bitmap, cliprect);
|
||||||
|
|
||||||
if (m_bigsprite_control[0] & 0x01)
|
if (m_bigsprite_control[0] & 0x01)
|
||||||
{
|
{
|
||||||
// draw the "big sprite" under the regular sprites
|
// draw the "big sprite" under the regular sprites
|
||||||
cclimber_draw_bigsprite(screen, bitmap, cliprect);
|
cclimber_draw_bigsprite(screen, m_dest_bitmap, cliprect);
|
||||||
toprollr_draw_sprites(bitmap, cliprect, m_gfxdecode->gfx(1));
|
toprollr_draw_sprites(m_dest_bitmap, cliprect, m_gfxdecode->gfx(1));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// draw the "big sprite" over the regular sprites
|
// draw the "big sprite" over the regular sprites
|
||||||
toprollr_draw_sprites(bitmap, cliprect, m_gfxdecode->gfx(1));
|
toprollr_draw_sprites(m_dest_bitmap, cliprect, m_gfxdecode->gfx(1));
|
||||||
cclimber_draw_bigsprite(screen, bitmap, cliprect);
|
cclimber_draw_bigsprite(screen, m_dest_bitmap, cliprect);
|
||||||
|
}
|
||||||
|
|
||||||
|
// copy the tilemap/sprites
|
||||||
|
for (int y = cliprect.min_y; y <= cliprect.max_y; y++)
|
||||||
|
{
|
||||||
|
for (int x = cliprect.min_x; x <= cliprect.max_x; x++)
|
||||||
|
{
|
||||||
|
const pen_t pen = m_dest_bitmap.pix(y, x);
|
||||||
|
if (pen != 0xff)
|
||||||
|
bitmap.pix(y, x) = m_palette->pen(pen);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user