mirror of
https://github.com/holub/mame
synced 2025-04-21 07:52:35 +03:00
- jaleco/bigstrkb.cpp, misc/pass.cpp: consolidated drivers in one file, very minor cleanups
- a few drivers: removed some custom GFX decodes in favor of the ones provided in emu/video/generic.cpp
This commit is contained in:
parent
2b06874b86
commit
c52873ab29
@ -7776,10 +7776,10 @@ void galaxian_state::bmxstunts(machine_config &config)
|
||||
{
|
||||
galaxian_base(config);
|
||||
|
||||
M6502(config.replace(), m_maincpu, 3'072'000); // TODO: verify clock
|
||||
M6502(config.replace(), m_maincpu, 3'072'000); // TODO: verify clock, actually 6502A
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &galaxian_state::bmxstunts_map);
|
||||
|
||||
SN76489(config, "snsnd", 3'072'000).add_route(ALL_OUTPUTS, "speaker", 0.5); // TODO: verify clock
|
||||
SN76489A(config, "snsnd", 3'072'000).add_route(ALL_OUTPUTS, "speaker", 0.5); // TODO: verify clock, actually SN76489AN
|
||||
}
|
||||
|
||||
void galaxian_state::ckongg(machine_config &config)
|
||||
@ -12283,9 +12283,9 @@ ROM_END
|
||||
/*
|
||||
BMX Stunts by Jetsoft on Galaxian bootleg PCB.
|
||||
|
||||
6502A CPU in epoxy block with one 6331 prom (not dumped)
|
||||
6502A CPU in epoxy block with one 6331 PROM (not dumped)
|
||||
One 74LS74 and one 74LS273 logic.
|
||||
One SN76489 Digital Complex Sound Generator.
|
||||
One SN76489AN Digital Complex Sound Generator.
|
||||
There was a wire lead coming out of the epoxy and soldered
|
||||
to the sound/amplifier section on the PCB.
|
||||
|
||||
@ -12295,7 +12295,7 @@ this riser board has eight sockets instead of the normal five and
|
||||
is printed with the words "MOON PROGRAM", was possibly a bootleg
|
||||
Moon Cresta PCB before conversion to BMX Stunts.
|
||||
|
||||
Color prom is unique to this game and doesn't match any others.
|
||||
Color PROM is unique to this game and doesn't match any others.
|
||||
|
||||
Main program EPROMs are all 2716 type by different manufacturers.
|
||||
Graphics ROMs are 2732 EPROMs soldered directly to the main PCB
|
||||
@ -12358,7 +12358,7 @@ ROM_START( bmxstuntsa )
|
||||
ROM_LOAD16_WORD_SWAP( "b-mx.8", 0x3800, 0x0800, CRC(8bc26d4d) SHA1(c01be14d7cd402a524b61bd845c1ae6b09967bfa) ) // bmx8.pr8 99.267578%
|
||||
|
||||
ROM_REGION( 0x2000, "gfx1", 0 ) // not dumped for this set, taken from above
|
||||
ROM_LOAD( "bmxh.1h", 0x0000, 0x1000, BAD_DUMP CRC(b049f648) SHA1(06c5a8b15f876cb6e4798cb5f8b1351cc6c12877) ) // 1ST AND 2ND HALF IDENTICAL)
|
||||
ROM_LOAD( "bmxh.1h", 0x0000, 0x1000, BAD_DUMP CRC(b049f648) SHA1(06c5a8b15f876cb6e4798cb5f8b1351cc6c12877) ) // 1ST AND 2ND HALF IDENTICAL
|
||||
ROM_LOAD( "bmxl.1l", 0x1000, 0x1000, BAD_DUMP CRC(a0f44f47) SHA1(b9d40ff82bb90125f0d9ad2d9590ddd7cc600805) )
|
||||
|
||||
ROM_REGION( 0x0020, "proms", 0 ) // not dumped for this set, taken from above
|
||||
@ -15985,7 +15985,7 @@ GAME( 1982, guttangt, locomotn, guttangt, guttangt, guttangt_state, init_
|
||||
GAME( 1982, guttangts3, locomotn, guttangts3, guttangt, guttangt_state, init_guttangts3, ROT90, "bootleg (Sede 3)", "Guttang Gottong (Sede 3 bootleg on Galaxian hardware)", MACHINE_SUPPORTS_SAVE ) // still has Konami copyright on screen
|
||||
|
||||
|
||||
// Basic hardware with epoxy block containing a M6502, SN76489, PROM and logic
|
||||
// Basic hardware with epoxy block containing a 6502A, SN76489AN, PROM and logic
|
||||
GAME( 1985, bmxstunts, 0, bmxstunts, bmxstunts, galaxian_state, init_bmxstunts, ROT90, "Jetsoft", "BMX Stunts (set 1)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // not working due to bad program ROMs
|
||||
GAME( 1985, bmxstuntsa, bmxstunts, bmxstunts, bmxstunts, galaxian_state, init_bmxstunts, ROT90, "Jetsoft", "BMX Stunts (set 2)", MACHINE_NOT_WORKING | MACHINE_IMPERFECT_GRAPHICS | MACHINE_IMPERFECT_SOUND ) // could be considered working if not for bad GFX and sound
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
|
||||
maybe it could be merged with megasys1.cpp, could be messy
|
||||
|
||||
todo:
|
||||
TODO:
|
||||
|
||||
complete sound (YM2151 like megasys1?)
|
||||
sprite lag (buffers spriteram?)
|
||||
@ -15,12 +15,186 @@
|
||||
*/
|
||||
|
||||
#include "emu.h"
|
||||
#include "bigstrkb.h"
|
||||
|
||||
#include "cpu/m68000/m68000.h"
|
||||
#include "sound/okim6295.h"
|
||||
|
||||
#include "emupal.h"
|
||||
#include "screen.h"
|
||||
#include "speaker.h"
|
||||
#include "tilemap.h"
|
||||
|
||||
|
||||
// configurable logging
|
||||
#define LOG_VIDREG (1U << 1)
|
||||
|
||||
//#define VERBOSE (LOG_GENERAL | LOG_VIDREG)
|
||||
|
||||
#include "logmacro.h"
|
||||
|
||||
#define LOGVIDREG(...) LOGMASKED(LOG_VIDREG, __VA_ARGS__)
|
||||
|
||||
|
||||
namespace {
|
||||
|
||||
class bigstrkb_state : public driver_device
|
||||
{
|
||||
public:
|
||||
bigstrkb_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette"),
|
||||
m_videoram(*this, "videoram%u", 1U),
|
||||
m_spriteram(*this, "spriteram"),
|
||||
m_vidreg(*this, "vidreg%u", 1U)
|
||||
{ }
|
||||
|
||||
void bigstrkb(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
required_device<palette_device> m_palette;
|
||||
|
||||
required_shared_ptr_array<uint16_t, 3> m_videoram;
|
||||
required_shared_ptr<uint16_t> m_spriteram;
|
||||
required_shared_ptr_array<uint16_t, 2> m_vidreg;
|
||||
|
||||
tilemap_t *m_tilemap[3]{};
|
||||
|
||||
template <uint8_t Which> void videoram_w(offs_t offset, uint16_t data);
|
||||
|
||||
TILEMAP_MAPPER_MEMBER(bg_scan);
|
||||
TILE_GET_INFO_MEMBER(get_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_tile2_info);
|
||||
TILE_GET_INFO_MEMBER(get_tile3_info);
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void prg_map(address_map &map);
|
||||
};
|
||||
|
||||
|
||||
// video
|
||||
|
||||
// Sprites
|
||||
|
||||
void bigstrkb_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
{
|
||||
/*- SPR RAM Format -**
|
||||
|
||||
16 bytes per sprite
|
||||
|
||||
nnnn nnnn nnnn nnnn aaaa aaaa aaaa aaaa xxxx xxxx xxxx xxxx yyyy yyyy yyyy yyyy
|
||||
( rest unused )
|
||||
**- End of Comments -*/
|
||||
|
||||
gfx_element *gfx = m_gfxdecode->gfx(2);
|
||||
uint16_t *source = m_spriteram;
|
||||
uint16_t *finish = source + 0x800 / 2;
|
||||
|
||||
while (source < finish)
|
||||
{
|
||||
int xpos = source[2];
|
||||
int ypos = source[3];
|
||||
const int num = source[0];
|
||||
const int attr = source[1];
|
||||
|
||||
ypos = 0xffff - ypos;
|
||||
|
||||
|
||||
xpos -= 126;
|
||||
ypos -= 16;
|
||||
|
||||
const int flipx = attr & 0x0100;
|
||||
const int col = attr & 0x000f;
|
||||
|
||||
gfx->transpen(bitmap, cliprect, num, col, flipx, 0, xpos,ypos, 15);
|
||||
source += 8;
|
||||
}
|
||||
}
|
||||
|
||||
// Tilemaps
|
||||
|
||||
TILEMAP_MAPPER_MEMBER(bigstrkb_state::bg_scan)
|
||||
{
|
||||
int offset = ((col & 0xf) * 16) + (row & 0xf);
|
||||
offset += (col >> 4) * 0x100;
|
||||
offset += (row >> 4) * 0x800;
|
||||
|
||||
return offset;
|
||||
}
|
||||
|
||||
TILE_GET_INFO_MEMBER(bigstrkb_state::get_tile_info)
|
||||
{
|
||||
int tileno = m_videoram[0][tile_index] & 0x0fff;
|
||||
int col = m_videoram[0][tile_index] & 0xf000;
|
||||
|
||||
tileinfo.set(0, tileno, col >> 12, 0);
|
||||
}
|
||||
|
||||
TILE_GET_INFO_MEMBER(bigstrkb_state::get_tile2_info)
|
||||
{
|
||||
int tileno = m_videoram[1][tile_index] & 0x0fff;
|
||||
int col = m_videoram[1][tile_index] & 0xf000;
|
||||
|
||||
tileinfo.set(1, tileno, col >> 12, 0);
|
||||
}
|
||||
|
||||
TILE_GET_INFO_MEMBER(bigstrkb_state::get_tile3_info)
|
||||
{
|
||||
int tileno = m_videoram[2][tile_index] & 0x0fff;
|
||||
int col = m_videoram[2][tile_index] & 0xf000;
|
||||
|
||||
tileinfo.set(1, tileno + 0x2000, (col >> 12) + (0x100 / 16) ,0);
|
||||
}
|
||||
|
||||
template <uint8_t Which>
|
||||
void bigstrkb_state::videoram_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_videoram[Which][offset] = data;
|
||||
m_tilemap[Which]->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
// Video Start / Update
|
||||
|
||||
void bigstrkb_state::video_start()
|
||||
{
|
||||
m_tilemap[0] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(bigstrkb_state::get_tile_info)), TILEMAP_SCAN_COLS, 8, 8, 64, 32);
|
||||
m_tilemap[1] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(bigstrkb_state::get_tile2_info)), tilemap_mapper_delegate(*this, FUNC(bigstrkb_state::bg_scan)), 16, 16, 128, 64);
|
||||
m_tilemap[2] = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(bigstrkb_state::get_tile3_info)), tilemap_mapper_delegate(*this, FUNC(bigstrkb_state::bg_scan)), 16, 16, 128, 64);
|
||||
|
||||
m_tilemap[0]->set_transparent_pen(15);
|
||||
//m_tilemap[1]->set_transparent_pen(15);
|
||||
m_tilemap[2]->set_transparent_pen(15);
|
||||
}
|
||||
|
||||
uint32_t bigstrkb_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
{
|
||||
// bitmap.fill(m_palette->black_pen(), cliprect);
|
||||
|
||||
m_tilemap[1]->set_scrollx(0, m_vidreg[0][0] + (256 - 14));
|
||||
m_tilemap[1]->set_scrolly(0, m_vidreg[1][0]);
|
||||
|
||||
m_tilemap[2]->set_scrollx(0, m_vidreg[0][1] + (256 - 14));
|
||||
m_tilemap[2]->set_scrolly(0, m_vidreg[1][1]);
|
||||
|
||||
m_tilemap[1]->draw(screen, bitmap, cliprect, 0, 0);
|
||||
m_tilemap[2]->draw(screen, bitmap, cliprect, 0, 0);
|
||||
|
||||
draw_sprites(bitmap, cliprect);
|
||||
m_tilemap[0]->draw(screen, bitmap, cliprect, 0, 0);
|
||||
|
||||
LOGVIDREG("Regs %08x %08x %08x %08x", m_vidreg[1][0], m_vidreg[1][1], m_vidreg[1][2], m_vidreg[1][3]);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
// machine
|
||||
|
||||
/*
|
||||
|
||||
@ -35,35 +209,35 @@ lev 7 : 0x7c : 0000 05be - xxx
|
||||
|
||||
*/
|
||||
|
||||
/* Memory Maps */
|
||||
// Memory maps
|
||||
|
||||
/* some regions might be too large */
|
||||
// some regions might be too large
|
||||
|
||||
void bigstrkb_state::bigstrkb_map(address_map &map)
|
||||
void bigstrkb_state::prg_map(address_map &map)
|
||||
{
|
||||
map(0x000000, 0x07ffff).rom();
|
||||
// map(0x0c0000, 0x0cffff).rw(FUNC(bigstrkb_state::megasys1_vregs_C_r), FUNC(bigstrkb_state::megasys1_vregs_C_w)).share("megasys1_vregs");
|
||||
|
||||
map(0x0C2004, 0x0C2005).nopw();
|
||||
map(0x0C200C, 0x0C200d).nopw();
|
||||
map(0x0C2104, 0x0C2105).nopw();
|
||||
map(0x0C2108, 0x0C2109).nopw();
|
||||
map(0x0C2200, 0x0C2201).nopw();
|
||||
map(0x0C2208, 0x0C2209).nopw();
|
||||
map(0x0c2004, 0x0c2005).nopw();
|
||||
map(0x0c200c, 0x0c200d).nopw();
|
||||
map(0x0c2104, 0x0c2105).nopw();
|
||||
map(0x0c2108, 0x0c2109).nopw();
|
||||
map(0x0c2200, 0x0c2201).nopw();
|
||||
map(0x0c2208, 0x0c2209).nopw();
|
||||
map(0x0c2308, 0x0c2309).nopw(); // bit 0 of DSW1 (flip screen) - use vregs
|
||||
|
||||
map(0x0D0000, 0x0dffff).ram(); // 0xd2000 - 0xd3fff? 0xd8000?
|
||||
map(0x0d0000, 0x0dffff).ram(); // 0xd2000 - 0xd3fff? 0xd8000?
|
||||
|
||||
map(0x0e0000, 0x0e3fff).ram().w(FUNC(bigstrkb_state::videoram2_w)).share("videoram2");
|
||||
map(0x0e8000, 0x0ebfff).ram().w(FUNC(bigstrkb_state::videoram3_w)).share("videoram3");
|
||||
map(0x0ec000, 0x0effff).ram().w(FUNC(bigstrkb_state::videoram_w)).share("videoram");
|
||||
map(0x0e0000, 0x0e3fff).ram().w(FUNC(bigstrkb_state::videoram_w<1>)).share(m_videoram[1]);
|
||||
map(0x0e8000, 0x0ebfff).ram().w(FUNC(bigstrkb_state::videoram_w<2>)).share(m_videoram[2]);
|
||||
map(0x0ec000, 0x0effff).ram().w(FUNC(bigstrkb_state::videoram_w<0>)).share(m_videoram[0]);
|
||||
|
||||
map(0x0f0000, 0x0f7fff).ram();
|
||||
map(0x0f8000, 0x0f87ff).ram().w(m_palette, FUNC(palette_device::write16)).share("palette");
|
||||
map(0x0f8800, 0x0fffff).ram();
|
||||
|
||||
map(0x1f0000, 0x1f7fff).ram();
|
||||
map(0x1f8000, 0x1f87ff).ram().share("spriteram");
|
||||
map(0x1f8000, 0x1f87ff).ram().share(m_spriteram);
|
||||
map(0x1f8800, 0x1fffff).ram();
|
||||
|
||||
map(0x700000, 0x700001).portr("DSW0");
|
||||
@ -71,18 +245,18 @@ void bigstrkb_state::bigstrkb_map(address_map &map)
|
||||
map(0x700004, 0x700005).portr("SYSTEM");
|
||||
map(0x70000a, 0x70000b).portr("P2");
|
||||
map(0x70000c, 0x70000d).portr("P1");
|
||||
map(0x700020, 0x700027).writeonly().share("vidreg1");
|
||||
map(0x700030, 0x700037).writeonly().share("vidreg2");
|
||||
map(0x700020, 0x700027).writeonly().share(m_vidreg[0]);
|
||||
map(0x700030, 0x700037).writeonly().share(m_vidreg[1]);
|
||||
|
||||
map(0xB00000, 0xB00001).nopw();
|
||||
map(0xb00000, 0xb00001).nopw();
|
||||
|
||||
map(0xe00001, 0xe00001).rw("oki1", FUNC(okim6295_device::read), FUNC(okim6295_device::write));
|
||||
map(0xe00003, 0xe00003).rw("oki2", FUNC(okim6295_device::read), FUNC(okim6295_device::write));
|
||||
|
||||
map(0xE00008, 0xE00009).nopw();
|
||||
map(0xE0000c, 0xE0000d).nopw();
|
||||
map(0xe00008, 0xe00009).nopw();
|
||||
map(0xe0000c, 0xe0000d).nopw();
|
||||
|
||||
map(0xF00000, 0xFFFFFF).ram();
|
||||
map(0xf00000, 0xffffff).ram();
|
||||
}
|
||||
|
||||
#define BIGSTRKB_PLAYER_INPUT( player, start ) \
|
||||
@ -96,35 +270,43 @@ void bigstrkb_state::bigstrkb_map(address_map &map)
|
||||
PORT_BIT( 0x80, IP_ACTIVE_LOW, start )
|
||||
|
||||
static INPUT_PORTS_START( bigstrkb )
|
||||
PORT_START("DSW0") /* DSW0 (0x700000.w) */
|
||||
PORT_START("DSW0") // (0x700000.w)
|
||||
PORT_DIPNAME( 0x0f, 0x0f, DEF_STR( Coin_A ) )
|
||||
PORT_DIPSETTING( 0x07, DEF_STR( 4C_1C ) )
|
||||
PORT_DIPSETTING( 0x08, DEF_STR( 3C_1C ) )
|
||||
PORT_DIPSETTING( 0x09, DEF_STR( 2C_1C ) )
|
||||
PORT_DIPSETTING( 0x0f, DEF_STR( 1C_1C ) )
|
||||
PORT_DIPSETTING( 0x06, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x05, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x04, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x03, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x02, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x01, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x0e, DEF_STR( 1C_2C ) )
|
||||
PORT_DIPSETTING( 0x0d, DEF_STR( 1C_3C ) )
|
||||
PORT_DIPSETTING( 0x0c, DEF_STR( 1C_4C ) )
|
||||
PORT_DIPSETTING( 0x0b, DEF_STR( 1C_5C ) )
|
||||
PORT_DIPSETTING( 0x0a, DEF_STR( 1C_6C ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) // also set "Coin B" to "Free Play"
|
||||
/* 0x01 to 0x05 gives 2C_3C */
|
||||
PORT_DIPNAME( 0xf0, 0xf0, DEF_STR( Coin_B ) )
|
||||
PORT_DIPSETTING( 0x70, DEF_STR( 4C_1C ) )
|
||||
PORT_DIPSETTING( 0x80, DEF_STR( 3C_1C ) )
|
||||
PORT_DIPSETTING( 0x90, DEF_STR( 2C_1C ) )
|
||||
PORT_DIPSETTING( 0xf0, DEF_STR( 1C_1C ) )
|
||||
PORT_DIPSETTING( 0x60, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x50, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x40, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x30, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x20, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0x10, DEF_STR( 2C_3C ) )
|
||||
PORT_DIPSETTING( 0xe0, DEF_STR( 1C_2C ) )
|
||||
PORT_DIPSETTING( 0xd0, DEF_STR( 1C_3C ) )
|
||||
PORT_DIPSETTING( 0xc0, DEF_STR( 1C_4C ) )
|
||||
PORT_DIPSETTING( 0xb0, DEF_STR( 1C_5C ) )
|
||||
PORT_DIPSETTING( 0xa0, DEF_STR( 1C_6C ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) // also set "Coin A" to "Free Play"
|
||||
/* 0x10 to 0x50 gives 2C_3C */
|
||||
|
||||
PORT_START("DSW1") /* DSW1 (0x700002.w) */
|
||||
PORT_START("DSW1") // (0x700002.w)
|
||||
PORT_DIPNAME( 0x01, 0x01, DEF_STR( Flip_Screen ) ) // Check code at 0x00097c (flip screen)
|
||||
PORT_DIPSETTING( 0x01, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
|
||||
@ -135,7 +317,7 @@ static INPUT_PORTS_START( bigstrkb )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( Hardest ) )
|
||||
PORT_DIPNAME( 0x18, 0x18, "Timer Speed" )
|
||||
PORT_DIPSETTING( 0x08, "Slow" ) // 65
|
||||
PORT_DIPSETTING( 0x18, DEF_STR( Normal ) ) // 50
|
||||
PORT_DIPSETTING( 0x18, DEF_STR( Normal ) ) // 50
|
||||
PORT_DIPSETTING( 0x10, "Fast" ) // 35
|
||||
PORT_DIPSETTING( 0x00, "Fastest" ) // 25
|
||||
PORT_DIPUNUSED( 0x20, IP_ACTIVE_LOW )
|
||||
@ -146,7 +328,7 @@ static INPUT_PORTS_START( bigstrkb )
|
||||
PORT_DIPSETTING( 0x80, DEF_STR( Off ) )
|
||||
PORT_DIPSETTING( 0x00, DEF_STR( On ) )
|
||||
|
||||
PORT_START("SYSTEM") /* System inputs (0x700004.w) */
|
||||
PORT_START("SYSTEM") // (0x700004.w)
|
||||
PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
|
||||
PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
|
||||
PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
@ -156,14 +338,14 @@ static INPUT_PORTS_START( bigstrkb )
|
||||
PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN )
|
||||
|
||||
PORT_START("P1") /* Player 1 controls (0x70000c.w) */
|
||||
PORT_START("P1") // (0x70000c.w)
|
||||
BIGSTRKB_PLAYER_INPUT( 1, IPT_START1 )
|
||||
|
||||
PORT_START("P2") /* Player 2 controls (0x70000a.w) */
|
||||
PORT_START("P2") // (0x70000a.w)
|
||||
BIGSTRKB_PLAYER_INPUT( 2, IPT_START2 )
|
||||
INPUT_PORTS_END
|
||||
|
||||
/* GFX Decode */
|
||||
// GFX Decode
|
||||
|
||||
static const gfx_layout bigstrkb_charlayout =
|
||||
{
|
||||
@ -192,18 +374,18 @@ static const gfx_layout bigstrkb_char16layout =
|
||||
|
||||
|
||||
static GFXDECODE_START( gfx_bigstrkb )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, bigstrkb_charlayout, 0x200, 16 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, bigstrkb_char16layout, 0, 32 )
|
||||
GFXDECODE_ENTRY( "gfx3", 0, bigstrkb_char16layout, 0x300, 16 )
|
||||
GFXDECODE_ENTRY( "fgtiles", 0, bigstrkb_charlayout, 0x200, 16 )
|
||||
GFXDECODE_ENTRY( "bgtiles", 0, bigstrkb_char16layout, 0, 32 )
|
||||
GFXDECODE_ENTRY( "sprites", 0, bigstrkb_char16layout, 0x300, 16 )
|
||||
GFXDECODE_END
|
||||
|
||||
|
||||
/* Machine Driver */
|
||||
// Machine Driver
|
||||
|
||||
void bigstrkb_state::bigstrkb(machine_config &config)
|
||||
{
|
||||
M68000(config, m_maincpu, 12000000);
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &bigstrkb_state::bigstrkb_map);
|
||||
M68000(config, m_maincpu, 12'000'000);
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &bigstrkb_state::prg_map);
|
||||
m_maincpu->set_vblank_int("screen", FUNC(bigstrkb_state::irq6_line_hold));
|
||||
|
||||
GFXDECODE(config, m_gfxdecode, m_palette, gfx_bigstrkb);
|
||||
@ -220,82 +402,84 @@ void bigstrkb_state::bigstrkb(machine_config &config)
|
||||
|
||||
SPEAKER(config, "lspeaker").front_left();
|
||||
SPEAKER(config, "rspeaker").front_right();
|
||||
// YM2151(config, "ymsnd", 4000000);
|
||||
// YM2151(config, "ymsnd", 4'000'000);
|
||||
|
||||
okim6295_device &oki1(OKIM6295(config, "oki1", 4000000, okim6295_device::PIN7_HIGH));
|
||||
okim6295_device &oki1(OKIM6295(config, "oki1", 4'000'000, okim6295_device::PIN7_HIGH));
|
||||
oki1.add_route(ALL_OUTPUTS, "lspeaker", 0.30);
|
||||
oki1.add_route(ALL_OUTPUTS, "rspeaker", 0.30);
|
||||
|
||||
okim6295_device &oki2(OKIM6295(config, "oki2", 4000000, okim6295_device::PIN7_HIGH));
|
||||
okim6295_device &oki2(OKIM6295(config, "oki2", 4'000'000, okim6295_device::PIN7_HIGH));
|
||||
oki2.add_route(ALL_OUTPUTS, "lspeaker", 0.30);
|
||||
oki2.add_route(ALL_OUTPUTS, "rspeaker", 0.30);
|
||||
}
|
||||
|
||||
/* Rom Loading */
|
||||
// Rom Loading
|
||||
|
||||
ROM_START( bigstrkb )
|
||||
ROM_REGION( 0x80000, "maincpu", 0 ) /* 68000 Code */
|
||||
ROM_REGION( 0x80000, "maincpu", 0 ) // 68000 Code
|
||||
ROM_LOAD16_BYTE( "footgaa.015", 0x00001, 0x40000, CRC(33b1d7f3) SHA1(7a48c3c7f5ed61099d07b3259778ad382b7660a2) )
|
||||
ROM_LOAD16_BYTE( "footgaa.016", 0x00000, 0x40000, CRC(1c6b8709) SHA1(b371cb1421877247d88ffc52ad090b3c6279b78f) )
|
||||
|
||||
ROM_REGION( 0x40000, "gfx1", 0 ) /* 8x8x4 FG Tiles */
|
||||
ROM_REGION( 0x40000, "fgtiles", 0 ) // 8x8x4
|
||||
ROM_LOAD( "footgaa.005", 0x00000, 0x10000, CRC(d97c9bfe) SHA1(03410a6b5348362575b2463ac9968975eeb0bc39) ) // FIRST AND SECOND HALF IDENTICAL
|
||||
ROM_LOAD( "footgaa.006", 0x10000, 0x10000, CRC(1ae56e8b) SHA1(632ef5ca0ba043115d94e925d23a48cc28eeeb40) ) // FIRST AND SECOND HALF IDENTICAL
|
||||
ROM_LOAD( "footgaa.007", 0x20000, 0x10000, CRC(a45fa6b6) SHA1(95ea6cf98b1fb7600c034f4cedda3cc46a51e199) ) // FIRST AND SECOND HALF IDENTICAL
|
||||
ROM_LOAD( "footgaa.008", 0x30000, 0x10000, CRC(2700888c) SHA1(ef3b4393cd36f5bbe7fdb8a78c8d0bc15022d027) )
|
||||
|
||||
ROM_REGION( 0x200000, "gfx2", ROMREGION_INVERT ) /* 16x16x4 BG Tiles */
|
||||
ROM_REGION( 0x200000, "bgtiles", ROMREGION_INVERT ) // 16x16x4
|
||||
ROM_LOAD( "footgaa.001", 0x000000, 0x80000, CRC(0e440841) SHA1(169ce2ba3ace707466fa1138c0841b7a6c90629f) ) // x1xxxxxxxxxxxxxxxxx = 0xFF
|
||||
ROM_LOAD( "footgaa.002", 0x080000, 0x80000, CRC(92a15164) SHA1(31f641a6ab3a6115fbbdf89d65e8316c92bddf2a) ) // x1xxxxxxxxxxxxxxxxx = 0xFF
|
||||
ROM_LOAD( "footgaa.003", 0x100000, 0x80000, CRC(da127b89) SHA1(085c201abcbd7ba3c87e4cf066f7928daebedd5d) ) // x1xxxxxxxxxxxxxxxxx = 0xFF
|
||||
ROM_LOAD( "footgaa.004", 0x180000, 0x80000, CRC(3e6b0d92) SHA1(d8bf2e2d82dc985e8912b23620b19391396bc1af) ) // x1xxxxxxxxxxxxxxxxx = 0xFF
|
||||
|
||||
ROM_REGION( 0x080000, "gfx3", ROMREGION_INVERT ) /* 16x16x4 Sprites */
|
||||
ROM_REGION( 0x080000, "sprites", ROMREGION_INVERT ) // 16x16x4 Sprites
|
||||
ROM_LOAD( "footgaa.011", 0x000000, 0x20000, CRC(c3924fea) SHA1(85b6775b5aa8c518a1e169b97379a210e25e67c9) )
|
||||
ROM_LOAD( "footgaa.012", 0x020000, 0x20000, CRC(a581e9d7) SHA1(b894186f07612f9372e6d3bc037c65696c070d04) )
|
||||
ROM_LOAD( "footgaa.013", 0x040000, 0x20000, CRC(26ce4b7f) SHA1(4bfd1de6d73dc5e720972bba477081dba0b05ab3) )
|
||||
ROM_LOAD( "footgaa.014", 0x060000, 0x20000, CRC(c3cfc500) SHA1(5dc5780b9977b0544601471004c656c2fd738bcd) )
|
||||
|
||||
ROM_REGION( 0x40000, "oki1", 0 ) /* Samples? */
|
||||
ROM_REGION( 0x40000, "oki1", 0 )
|
||||
ROM_LOAD( "footgaa.010", 0x00000, 0x40000, CRC(53014576) SHA1(7f3402b33ef5992a6ae51ce07f0fcdc267c51beb) )
|
||||
|
||||
ROM_REGION( 0x40000, "oki2", 0 ) /* Samples? */
|
||||
ROM_REGION( 0x40000, "oki2", 0 )
|
||||
ROM_LOAD( "footgaa.009", 0x00000, 0x40000, CRC(19bf0896) SHA1(30c8e030d7dbcd38f213010596c8f9c5b8089f62) )
|
||||
ROM_END
|
||||
|
||||
// same as bigstrkb, but less buggy/better presentation, and teams are Italian league instead of international
|
||||
ROM_START( bigstrkba )
|
||||
ROM_REGION( 0x80000, "maincpu", 0 ) /* 68000 Code */
|
||||
ROM_REGION( 0x80000, "maincpu", 0 ) // 68000 Code
|
||||
ROM_LOAD16_BYTE( "15.cpu16", 0x000000, 0x040000, CRC(204551b5) SHA1(bfc8d284801a2c11677431287bc2e5b8ba7737db) )
|
||||
ROM_LOAD16_BYTE( "16.cpu17", 0x000001, 0x040000, CRC(3ba6997b) SHA1(86c0318a48b42b4622f3397c55584e0779e4f626) )
|
||||
|
||||
ROM_REGION( 0x40000, "gfx1", 0 ) /* 8x8x4 FG Tiles */
|
||||
ROM_REGION( 0x40000, "fgtiles", 0 ) // 8x8x4
|
||||
ROM_LOAD( "5.bin", 0x000000, 0x010000, CRC(f51ea151) SHA1(fd80280fa99cd08b9f458a4d4078ce59a926b4bc) )
|
||||
ROM_LOAD( "6.bin", 0x010000, 0x010000, CRC(754d750e) SHA1(d0a6be6d373e95404733c125126bbeeed03e370e) )
|
||||
ROM_LOAD( "7.bin", 0x020000, 0x010000, CRC(fbc52546) SHA1(daae9451629b67d532dfd4825b552944e1c585d8) )
|
||||
ROM_LOAD( "8.bin", 0x030000, 0x010000, CRC(62c63eaa) SHA1(4a408703a3d70159d78b0c213ff52a95a8a07884) )
|
||||
|
||||
ROM_REGION( 0x200000, "gfx2", ROMREGION_INVERT ) /* 16x16x4 BG Tiles */
|
||||
ROM_REGION( 0x200000, "bgtiles", ROMREGION_INVERT ) // 16x16x4 BG Tiles
|
||||
ROM_LOAD( "1.bin", 0x000000, 0x080000, CRC(c4eb9746) SHA1(ed4436e79abdb043349ee20d22c5454590ab5837) )
|
||||
ROM_LOAD( "2.bin", 0x080000, 0x080000, CRC(aa0beb78) SHA1(42cde54203cab4169099172cfce090725102e44c) )
|
||||
ROM_LOAD( "3.bin", 0x100000, 0x080000, CRC(d02298c5) SHA1(d3da72cc4edc8a6c9c8ec76bb566ded6d0b7b453) )
|
||||
ROM_LOAD( "4.bin", 0x180000, 0x080000, CRC(069ac008) SHA1(30b90d80177de744624e9d9618eebe5471042afd) )
|
||||
|
||||
ROM_REGION( 0x080000, "gfx3", ROMREGION_INVERT ) /* 16x16x4 Sprites */
|
||||
ROM_REGION( 0x080000, "sprites", ROMREGION_INVERT ) // 16x16x4 Sprites
|
||||
ROM_LOAD( "footgaa.011", 0x000000, 0x20000, CRC(c3924fea) SHA1(85b6775b5aa8c518a1e169b97379a210e25e67c9) )
|
||||
ROM_LOAD( "12.bin", 0x020000, 0x20000, CRC(8e15ea09) SHA1(e591811bb5ecb1782a77883b3ee27212fb703f22) )
|
||||
ROM_LOAD( "footgaa.013", 0x040000, 0x20000, CRC(26ce4b7f) SHA1(4bfd1de6d73dc5e720972bba477081dba0b05ab3) )
|
||||
ROM_LOAD( "footgaa.014", 0x060000, 0x20000, CRC(c3cfc500) SHA1(5dc5780b9977b0544601471004c656c2fd738bcd) )
|
||||
|
||||
ROM_REGION( 0x40000, "oki1", 0 ) /* Samples? */
|
||||
ROM_REGION( 0x40000, "oki1", 0 )
|
||||
ROM_LOAD( "footgaa.010", 0x00000, 0x40000, CRC(53014576) SHA1(7f3402b33ef5992a6ae51ce07f0fcdc267c51beb) )
|
||||
|
||||
ROM_REGION( 0x40000, "oki2", 0 ) /* Samples? */
|
||||
ROM_REGION( 0x40000, "oki2", 0 )
|
||||
ROM_LOAD( "footgaa.009", 0x00000, 0x40000, CRC(19bf0896) SHA1(30c8e030d7dbcd38f213010596c8f9c5b8089f62) )
|
||||
ROM_END
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
/* GAME drivers */
|
||||
|
||||
// GAME drivers
|
||||
|
||||
GAME( 1992, bigstrkb, bigstrik, bigstrkb, bigstrkb, bigstrkb_state, empty_init, ROT0, "bootleg", "Big Striker (bootleg)", MACHINE_IMPERFECT_SOUND | MACHINE_NO_COCKTAIL | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1992, bigstrkba, bigstrik, bigstrkb, bigstrkb, bigstrkb_state, empty_init, ROT0, "bootleg", "Big Striker (bootleg w/Italian teams)", MACHINE_IMPERFECT_SOUND | MACHINE_NO_COCKTAIL | MACHINE_SUPPORTS_SAVE )
|
||||
|
@ -1,61 +0,0 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood
|
||||
#ifndef MAME_INCLUDES_BIGSTRKB_H
|
||||
#define MAME_INCLUDES_BIGSTRKB_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "emupal.h"
|
||||
#include "tilemap.h"
|
||||
|
||||
class bigstrkb_state : public driver_device
|
||||
{
|
||||
public:
|
||||
bigstrkb_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: driver_device(mconfig, type, tag),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode"),
|
||||
m_palette(*this, "palette"),
|
||||
m_videoram2(*this, "videoram2"),
|
||||
m_videoram3(*this, "videoram3"),
|
||||
m_videoram(*this, "videoram"),
|
||||
m_spriteram(*this, "spriteram"),
|
||||
m_vidreg1(*this, "vidreg1"),
|
||||
m_vidreg2(*this, "vidreg2")
|
||||
{ }
|
||||
|
||||
void bigstrkb(machine_config &config);
|
||||
|
||||
private:
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
required_device<palette_device> m_palette;
|
||||
|
||||
required_shared_ptr<uint16_t> m_videoram2;
|
||||
required_shared_ptr<uint16_t> m_videoram3;
|
||||
required_shared_ptr<uint16_t> m_videoram;
|
||||
required_shared_ptr<uint16_t> m_spriteram;
|
||||
required_shared_ptr<uint16_t> m_vidreg1;
|
||||
required_shared_ptr<uint16_t> m_vidreg2;
|
||||
|
||||
tilemap_t *m_tilemap = nullptr;
|
||||
tilemap_t *m_tilemap2 = nullptr;
|
||||
tilemap_t *m_tilemap3 = nullptr;
|
||||
|
||||
void videoram_w(offs_t offset, uint16_t data);
|
||||
void videoram2_w(offs_t offset, uint16_t data);
|
||||
void videoram3_w(offs_t offset, uint16_t data);
|
||||
|
||||
TILEMAP_MAPPER_MEMBER(bg_scan);
|
||||
TILE_GET_INFO_MEMBER(get_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_tile2_info);
|
||||
TILE_GET_INFO_MEMBER(get_tile3_info);
|
||||
|
||||
virtual void video_start() override;
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
void draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect );
|
||||
void bigstrkb_map(address_map &map);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_BIGSTRKB_H
|
@ -1,143 +0,0 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood
|
||||
/* Big Striker (bootleg) Video Hardware */
|
||||
|
||||
#include "emu.h"
|
||||
#include "bigstrkb.h"
|
||||
|
||||
|
||||
/* Sprites */
|
||||
|
||||
void bigstrkb_state::draw_sprites(bitmap_ind16 &bitmap, const rectangle &cliprect )
|
||||
{
|
||||
/*- SPR RAM Format -**
|
||||
|
||||
16 bytes per sprite
|
||||
|
||||
nnnn nnnn nnnn nnnn aaaa aaaa aaaa aaaa xxxx xxxx xxxx xxxx yyyy yyyy yyyy yyyy
|
||||
( rest unused )
|
||||
**- End of Comments -*/
|
||||
|
||||
gfx_element *gfx = m_gfxdecode->gfx(2);
|
||||
uint16_t *source = m_spriteram;
|
||||
uint16_t *finish = source + 0x800/2;
|
||||
|
||||
while( source<finish )
|
||||
{
|
||||
int xpos, ypos, num, attr;
|
||||
|
||||
int flipx, col;
|
||||
|
||||
xpos = source[2];
|
||||
ypos = source[3];
|
||||
num = source[0];
|
||||
attr = source[1];
|
||||
|
||||
ypos = 0xffff - ypos;
|
||||
|
||||
|
||||
xpos -= 126;
|
||||
ypos -= 16;
|
||||
|
||||
flipx = attr & 0x0100;
|
||||
col = attr & 0x000f;
|
||||
|
||||
gfx->transpen(bitmap,cliprect,num,col,flipx,0,xpos,ypos,15);
|
||||
source+=8;
|
||||
}
|
||||
}
|
||||
|
||||
/* Tilemaps */
|
||||
|
||||
TILEMAP_MAPPER_MEMBER(bigstrkb_state::bg_scan)
|
||||
{
|
||||
int offset;
|
||||
|
||||
offset = ((col&0xf)*16) + (row&0xf);
|
||||
offset += (col >> 4) * 0x100;
|
||||
offset += (row >> 4) * 0x800;
|
||||
|
||||
return offset;
|
||||
}
|
||||
|
||||
TILE_GET_INFO_MEMBER(bigstrkb_state::get_tile_info)
|
||||
{
|
||||
int tileno,col;
|
||||
|
||||
tileno = m_videoram[tile_index] & 0x0fff;
|
||||
col= m_videoram[tile_index] & 0xf000;
|
||||
|
||||
tileinfo.set(0,tileno,col>>12,0);
|
||||
}
|
||||
|
||||
void bigstrkb_state::videoram_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_videoram[offset] = data;
|
||||
m_tilemap->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
TILE_GET_INFO_MEMBER(bigstrkb_state::get_tile2_info)
|
||||
{
|
||||
int tileno,col;
|
||||
|
||||
tileno = m_videoram2[tile_index] & 0x0fff;
|
||||
col= m_videoram2[tile_index] & 0xf000;
|
||||
|
||||
tileinfo.set(1,tileno,col>>12,0);
|
||||
}
|
||||
|
||||
void bigstrkb_state::videoram2_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_videoram2[offset] = data;
|
||||
m_tilemap2->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
|
||||
TILE_GET_INFO_MEMBER(bigstrkb_state::get_tile3_info)
|
||||
{
|
||||
int tileno,col;
|
||||
|
||||
tileno = m_videoram3[tile_index] & 0x0fff;
|
||||
col= m_videoram3[tile_index] & 0xf000;
|
||||
|
||||
tileinfo.set(1,tileno+0x2000,(col>>12)+(0x100/16),0);
|
||||
}
|
||||
|
||||
void bigstrkb_state::videoram3_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_videoram3[offset] = data;
|
||||
m_tilemap3->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
/* Video Start / Update */
|
||||
|
||||
void bigstrkb_state::video_start()
|
||||
{
|
||||
m_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(bigstrkb_state::get_tile_info)), TILEMAP_SCAN_COLS, 8, 8, 64, 32);
|
||||
m_tilemap2 = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(bigstrkb_state::get_tile2_info)), tilemap_mapper_delegate(*this, FUNC(bigstrkb_state::bg_scan)), 16, 16, 128, 64);
|
||||
m_tilemap3 = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(bigstrkb_state::get_tile3_info)), tilemap_mapper_delegate(*this, FUNC(bigstrkb_state::bg_scan)), 16, 16, 128, 64);
|
||||
|
||||
m_tilemap->set_transparent_pen(15);
|
||||
//m_tilemap2->set_transparent_pen(15);
|
||||
m_tilemap3->set_transparent_pen(15);
|
||||
}
|
||||
|
||||
uint32_t bigstrkb_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
{
|
||||
// bitmap.fill(m_palette->black_pen(), cliprect);
|
||||
|
||||
m_tilemap2->set_scrollx(0, m_vidreg1[0]+(256-14));
|
||||
m_tilemap2->set_scrolly(0, m_vidreg2[0]);
|
||||
|
||||
m_tilemap3->set_scrollx(0, m_vidreg1[1]+(256-14));
|
||||
m_tilemap3->set_scrolly(0, m_vidreg2[1]);
|
||||
|
||||
m_tilemap2->draw(screen, bitmap, cliprect, 0,0);
|
||||
m_tilemap3->draw(screen, bitmap, cliprect, 0,0);
|
||||
|
||||
draw_sprites(bitmap,cliprect);
|
||||
m_tilemap->draw(screen, bitmap, cliprect, 0,0);
|
||||
|
||||
// popmessage ("Regs %08x %08x %08x %08x",m_vidreg2[0],m_vidreg2[1],m_vidreg2[2],m_vidreg2[3]);
|
||||
return 0;
|
||||
}
|
@ -186,19 +186,8 @@ INPUT_PORTS_END
|
||||
we cut them in 8x8x8 ones in the init function, in order to
|
||||
support 8x8, 16x16 and 32x32 sprites. */
|
||||
|
||||
static const gfx_layout layout_8x8x8 =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{0,1,2,3,4,5,6,7},
|
||||
{0*8,1*8,2*8,3*8,4*8,5*8,6*8,7*8},
|
||||
{0*64,1*64,2*64,3*64,4*64,5*64,6*64,7*64},
|
||||
8*8*8
|
||||
};
|
||||
|
||||
static GFXDECODE_START( gfx_skyfox )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, layout_8x8x8, 0, 1 ) // [0] Sprites
|
||||
GFXDECODE_ENTRY( "gfx1", 0, gfx_8x8x8_raw, 0, 1 ) // [0] Sprites
|
||||
GFXDECODE_END
|
||||
|
||||
|
||||
|
@ -280,19 +280,8 @@ static INPUT_PORTS_START( cardline )
|
||||
|
||||
INPUT_PORTS_END
|
||||
|
||||
static const gfx_layout charlayout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ 0,1,2,3,4,5,6,7 },
|
||||
{ 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 },
|
||||
{ 0*64, 1*64, 2*64, 3*64, 4*64, 5*64, 6*64, 7*64 },
|
||||
8*8*8
|
||||
};
|
||||
|
||||
static GFXDECODE_START( gfx_cardline )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, charlayout, 0, 2 )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, gfx_8x8x8_raw, 0, 2 )
|
||||
GFXDECODE_END
|
||||
|
||||
void cardline_state::cardline_palette(palette_device &palette) const
|
||||
|
@ -242,20 +242,8 @@ u32 clpoker_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, co
|
||||
}
|
||||
|
||||
|
||||
static const gfx_layout gfx_layout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ 0, 1, 2, 3, 4, 5, 6, 7 },
|
||||
{ 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 },
|
||||
{ 0*64, 1*64, 2*64, 3*64, 4*64, 5*64, 6*64, 7*64 },
|
||||
8*64,
|
||||
};
|
||||
|
||||
|
||||
static GFXDECODE_START( gfx_clpoker )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, gfx_layout, 0x0, 1 )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, gfx_8x8x8_raw, 0x0, 1 )
|
||||
GFXDECODE_END
|
||||
|
||||
|
||||
|
@ -644,17 +644,6 @@ static const gfx_layout hedpanic_sprite_16x16x5 =
|
||||
16*32,
|
||||
};
|
||||
|
||||
static const gfx_layout hedpanic_layout_8x8x8 =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ STEP8(0,1) },
|
||||
{ STEP8(0,8) },
|
||||
{ STEP8(0,8*8) },
|
||||
64*8,
|
||||
};
|
||||
|
||||
static const gfx_layout hedpanic_layout_16x16x8 =
|
||||
{
|
||||
16,16,
|
||||
@ -669,13 +658,13 @@ static const gfx_layout hedpanic_layout_16x16x8 =
|
||||
|
||||
static GFXDECODE_START( gfx_esd16 )
|
||||
GFXDECODE_ENTRY( "spr", 0, hedpanic_sprite_16x16x5, 0x200, 8 ) // [0] Sprites
|
||||
GFXDECODE_ENTRY( "bgs", 0, hedpanic_layout_8x8x8, 0x000, 2 ) // [1] Layers
|
||||
GFXDECODE_ENTRY( "bgs", 0, gfx_8x8x8_raw, 0x000, 2 ) // [1] Layers
|
||||
GFXDECODE_ENTRY( "bgs", 0, hedpanic_layout_16x16x8, 0x000, 2 ) // [1] Layers
|
||||
GFXDECODE_END
|
||||
|
||||
static GFXDECODE_START( gfx_jumppop )
|
||||
GFXDECODE_ENTRY( "spr", 0, jumppop_sprite_16x16x4, 0x000, 0x40 ) // Sprites 16x16 - has 4bpp sprites, unlike the others
|
||||
GFXDECODE_ENTRY( "bgs", 0, hedpanic_layout_8x8x8, 0x000, 4 ) // Characters 8x8
|
||||
GFXDECODE_ENTRY( "bgs", 0, gfx_8x8x8_raw, 0x000, 4 ) // Characters 8x8
|
||||
GFXDECODE_ENTRY( "bgs", 0, hedpanic_layout_16x16x8, 0x000, 4 ) // Tiles 16x16
|
||||
GFXDECODE_END
|
||||
|
||||
|
@ -552,21 +552,9 @@ static INPUT_PORTS_START( fresh )
|
||||
|
||||
INPUT_PORTS_END
|
||||
|
||||
static const gfx_layout tiles8x8_layout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ 0,1, 2,3, 4,5,6,7 },
|
||||
{ 0, 8, 16, 24, 32, 40, 48, 56 },
|
||||
{ 0*64, 1*64, 2*64, 3*64, 4*64, 5*64, 6*64, 7*64 },
|
||||
64*8
|
||||
};
|
||||
|
||||
|
||||
static GFXDECODE_START( gfx_fresh )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, tiles8x8_layout, 0, 16 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, tiles8x8_layout, 0, 16 )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, gfx_8x8x8_raw, 0, 16 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, gfx_8x8x8_raw, 0, 16 )
|
||||
GFXDECODE_END
|
||||
|
||||
|
||||
|
@ -414,17 +414,6 @@ static INPUT_PORTS_START( jungleyo )
|
||||
INPUT_PORTS_END
|
||||
|
||||
|
||||
static const gfx_layout jungleyo_layout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ STEP8(0,1) },
|
||||
{ STEP8(0,8) },
|
||||
{ STEP8(0,8*8) },
|
||||
8*64
|
||||
};
|
||||
|
||||
static const gfx_layout jungleyo16_layout =
|
||||
{
|
||||
8,32,
|
||||
@ -438,8 +427,8 @@ static const gfx_layout jungleyo16_layout =
|
||||
|
||||
static GFXDECODE_START( gfx_jungleyo )
|
||||
GFXDECODE_ENTRY( "reelgfx", 0, jungleyo16_layout, 0x4000, 0x40 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, jungleyo_layout, 0x2000, 0x20 )
|
||||
GFXDECODE_ENTRY( "gfx3", 0, jungleyo_layout, 0x0000, 0x20 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, gfx_8x8x8_raw, 0x2000, 0x20 )
|
||||
GFXDECODE_ENTRY( "gfx3", 0, gfx_8x8x8_raw, 0x0000, 0x20 )
|
||||
GFXDECODE_END
|
||||
|
||||
|
||||
|
@ -91,50 +91,149 @@
|
||||
|
||||
--- Game Notes ---
|
||||
|
||||
Graphical Glitches caused when 2 sprites are close together are NOT bugs, the Sprites are
|
||||
infact constructed from a tilemap made of 4x4 tiles.
|
||||
Graphical glitches caused when 2 sprites are close together are NOT bugs, the sprites are
|
||||
in fact constructed from a tilemap made of 4x4 tiles.
|
||||
|
||||
I imagine flicker on the main character at times is also correct.
|
||||
|
||||
Its rather interesting to see a game this old using 8bpp tiles
|
||||
It's rather interesting to see a game this old using 8bpp tiles
|
||||
|
||||
|
||||
*/
|
||||
|
||||
#include "emu.h"
|
||||
#include "pass.h"
|
||||
|
||||
#include "cpu/m68000/m68000.h"
|
||||
#include "cpu/z80/z80.h"
|
||||
#include "machine/gen_latch.h"
|
||||
#include "sound/okim6295.h"
|
||||
#include "sound/ymopn.h"
|
||||
|
||||
#include "emupal.h"
|
||||
#include "screen.h"
|
||||
#include "speaker.h"
|
||||
#include "tilemap.h"
|
||||
|
||||
|
||||
/* todo: check all memory regions actually readable / read from */
|
||||
void pass_state::pass_map(address_map &map)
|
||||
namespace {
|
||||
|
||||
class pass_state : public driver_device
|
||||
{
|
||||
public:
|
||||
pass_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_bg_tilemap(nullptr),
|
||||
m_fg_tilemap(nullptr),
|
||||
m_bg_videoram(*this, "bg_videoram"),
|
||||
m_fg_videoram(*this, "fg_videoram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode")
|
||||
{
|
||||
}
|
||||
|
||||
void pass(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
void bg_videoram_w(offs_t offset, uint16_t data);
|
||||
void fg_videoram_w(offs_t offset, uint16_t data);
|
||||
TILE_GET_INFO_MEMBER(get_bg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_fg_tile_info);
|
||||
|
||||
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
|
||||
void main_map(address_map &map);
|
||||
void sound_io_map(address_map &map);
|
||||
void sound_map(address_map &map);
|
||||
|
||||
tilemap_t *m_bg_tilemap = nullptr;
|
||||
tilemap_t *m_fg_tilemap = nullptr;
|
||||
|
||||
required_shared_ptr<uint16_t> m_bg_videoram;
|
||||
required_shared_ptr<uint16_t> m_fg_videoram;
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
};
|
||||
|
||||
|
||||
// video
|
||||
|
||||
// background tilemap stuff
|
||||
|
||||
TILE_GET_INFO_MEMBER(pass_state::get_bg_tile_info)
|
||||
{
|
||||
int tileno = m_bg_videoram[tile_index] & 0x1fff;
|
||||
int fx = (m_bg_videoram[tile_index] & 0xc000) >> 14;
|
||||
tileinfo.set(1, tileno, 0, TILE_FLIPYX(fx));
|
||||
|
||||
}
|
||||
|
||||
void pass_state::bg_videoram_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_bg_videoram[offset] = data;
|
||||
m_bg_tilemap->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
// foreground 'sprites' tilemap stuff
|
||||
|
||||
TILE_GET_INFO_MEMBER(pass_state::get_fg_tile_info)
|
||||
{
|
||||
int tileno = m_fg_videoram[tile_index] & 0x3fff;
|
||||
int flip = (m_fg_videoram[tile_index] & 0xc000) >>14;
|
||||
|
||||
tileinfo.set(0, tileno, 0, TILE_FLIPYX(flip));
|
||||
|
||||
}
|
||||
|
||||
void pass_state::fg_videoram_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_fg_videoram[offset] = data;
|
||||
m_fg_tilemap->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
// video update / start
|
||||
|
||||
void pass_state::video_start()
|
||||
{
|
||||
m_bg_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(pass_state::get_bg_tile_info)), TILEMAP_SCAN_ROWS, 8, 8, 64, 32);
|
||||
m_fg_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(pass_state::get_fg_tile_info)), TILEMAP_SCAN_ROWS, 4, 4, 128, 64);
|
||||
|
||||
m_fg_tilemap->set_transparent_pen(255);
|
||||
}
|
||||
|
||||
uint32_t pass_state::screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
{
|
||||
m_bg_tilemap->draw(screen, bitmap, cliprect, 0, 0);
|
||||
m_fg_tilemap->draw(screen, bitmap, cliprect, 0, 0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
// machine
|
||||
|
||||
// TODO: check all memory regions actually readable / read from
|
||||
void pass_state::main_map(address_map &map)
|
||||
{
|
||||
map(0x000000, 0x03ffff).rom();
|
||||
map(0x080000, 0x083fff).ram();
|
||||
map(0x200000, 0x200fff).ram().w(FUNC(pass_state::pass_bg_videoram_w)).share("bg_videoram"); // Background
|
||||
map(0x210000, 0x213fff).ram().w(FUNC(pass_state::pass_fg_videoram_w)).share("fg_videoram"); // Foreground
|
||||
map(0x200000, 0x200fff).ram().w(FUNC(pass_state::bg_videoram_w)).share(m_bg_videoram);
|
||||
map(0x210000, 0x213fff).ram().w(FUNC(pass_state::fg_videoram_w)).share(m_fg_videoram);
|
||||
map(0x220000, 0x2203ff).ram().w("palette", FUNC(palette_device::write16)).share("palette");
|
||||
map(0x230001, 0x230001).w("soundlatch", FUNC(generic_latch_8_device::write));
|
||||
map(0x230100, 0x230101).portr("DSW");
|
||||
map(0x230200, 0x230201).portr("INPUTS");
|
||||
}
|
||||
|
||||
/* sound cpu */
|
||||
void pass_state::pass_sound_map(address_map &map)
|
||||
void pass_state::sound_map(address_map &map)
|
||||
{
|
||||
map(0x0000, 0x7fff).rom();
|
||||
map(0xf800, 0xffff).ram();
|
||||
}
|
||||
|
||||
void pass_state::pass_sound_io_map(address_map &map)
|
||||
void pass_state::sound_io_map(address_map &map)
|
||||
{
|
||||
map.global_mask(0xff);
|
||||
map(0x00, 0x00).r("soundlatch", FUNC(generic_latch_8_device::read));
|
||||
@ -143,7 +242,7 @@ void pass_state::pass_sound_io_map(address_map &map)
|
||||
map(0xc0, 0xc0).w("soundlatch", FUNC(generic_latch_8_device::clear_w));
|
||||
}
|
||||
|
||||
/* todo : work out function of unknown but used dsw */
|
||||
// TODO : work out function of unknown but used dsw
|
||||
static INPUT_PORTS_START( pass )
|
||||
PORT_START("DSW")
|
||||
PORT_DIPNAME( 0x0001, 0x0001, "Unknown SW 0-0" ) // USED ! Check code at 0x0046ea
|
||||
@ -180,11 +279,11 @@ static INPUT_PORTS_START( pass )
|
||||
PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
|
||||
PORT_DIPNAME( 0x1800, 0x0000, DEF_STR( Difficulty ) )
|
||||
PORT_DIPSETTING( 0x0000, DEF_STR( Easy ) ) // Time = 99
|
||||
PORT_DIPSETTING( 0x1800, DEF_STR( Normal ) ) // Time = 88
|
||||
PORT_DIPSETTING( 0x1800, DEF_STR( Normal ) ) // Time = 88
|
||||
PORT_DIPSETTING( 0x0800, DEF_STR( Hard ) ) // Time = 77
|
||||
PORT_DIPSETTING( 0x1000, DEF_STR( Hardest ) ) // Time = 66
|
||||
PORT_DIPSETTING( 0x1000, DEF_STR( Hardest ) ) // Time = 66
|
||||
PORT_DIPNAME( 0xe000, 0xe000, DEF_STR( Coinage ) )
|
||||
// PORT_DIPSETTING( 0x0000, DEF_STR( 4C_1C ) )
|
||||
PORT_DIPSETTING( 0x0000, DEF_STR( 4C_1C ) )
|
||||
PORT_DIPSETTING( 0x8000, DEF_STR( 4C_1C ) )
|
||||
PORT_DIPSETTING( 0x4000, DEF_STR( 3C_1C ) )
|
||||
PORT_DIPSETTING( 0xc000, DEF_STR( 2C_1C ) )
|
||||
@ -212,18 +311,7 @@ static INPUT_PORTS_START( pass )
|
||||
PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_8WAY PORT_PLAYER(2)
|
||||
INPUT_PORTS_END
|
||||
|
||||
static const gfx_layout tiles8x8_layout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ 0,1, 2,3, 4,5,6,7 },
|
||||
{ 0, 8, 16, 24, 32, 40, 48, 56 },
|
||||
{ 0*64, 1*64, 2*64, 3*64, 4*64, 5*64, 6*64, 7*64 },
|
||||
64*8
|
||||
};
|
||||
|
||||
/* for something so simple this took a while to see */
|
||||
// for something so simple this took a while to see
|
||||
static const gfx_layout tiles4x4_fg_layout =
|
||||
{
|
||||
4,4,
|
||||
@ -236,68 +324,70 @@ static const gfx_layout tiles4x4_fg_layout =
|
||||
};
|
||||
|
||||
static GFXDECODE_START( gfx_pass )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, tiles4x4_fg_layout, 256, 2 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, tiles8x8_layout, 0, 2 )
|
||||
GFXDECODE_ENTRY( "fgtiles", 0, tiles4x4_fg_layout, 256, 2 )
|
||||
GFXDECODE_ENTRY( "bgtiles", 0, gfx_8x8x8_raw, 0, 2 )
|
||||
GFXDECODE_END
|
||||
|
||||
/* todo : is this correct? */
|
||||
// TODO : is this correct?
|
||||
void pass_state::pass(machine_config &config)
|
||||
{
|
||||
/* basic machine hardware */
|
||||
M68000(config, m_maincpu, 14318180/2);
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &pass_state::pass_map);
|
||||
m_maincpu->set_vblank_int("screen", FUNC(pass_state::irq1_line_hold)); /* all the same */
|
||||
// basic machine hardware
|
||||
M68000(config, m_maincpu, 14'318'180 / 2);
|
||||
m_maincpu->set_addrmap(AS_PROGRAM, &pass_state::main_map);
|
||||
m_maincpu->set_vblank_int("screen", FUNC(pass_state::irq1_line_hold)); // all the same
|
||||
|
||||
z80_device &audiocpu(Z80(config, "audiocpu", 14318180/4));
|
||||
audiocpu.set_addrmap(AS_PROGRAM, &pass_state::pass_sound_map);
|
||||
audiocpu.set_addrmap(AS_IO, &pass_state::pass_sound_io_map);
|
||||
audiocpu.set_periodic_int(FUNC(pass_state::irq0_line_hold), attotime::from_hz(60)); /* probably not accurate, unknown timing and generation (ym2203 sound chip?). */
|
||||
z80_device &audiocpu(Z80(config, "audiocpu", 14'318'180 / 4));
|
||||
audiocpu.set_addrmap(AS_PROGRAM, &pass_state::sound_map);
|
||||
audiocpu.set_addrmap(AS_IO, &pass_state::sound_io_map);
|
||||
audiocpu.set_periodic_int(FUNC(pass_state::irq0_line_hold), attotime::from_hz(60)); // probably not accurate, unknown timing and generation (ym2203 sound chip?).
|
||||
|
||||
/* video hardware */
|
||||
// video hardware
|
||||
screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
|
||||
screen.set_refresh_hz(60);
|
||||
screen.set_vblank_time(ATTOSECONDS_IN_USEC(0));
|
||||
screen.set_size(64*8, 32*8);
|
||||
screen.set_visarea(8*8, 48*8-1, 2*8, 30*8-1);
|
||||
screen.set_screen_update(FUNC(pass_state::screen_update_pass));
|
||||
screen.set_screen_update(FUNC(pass_state::screen_update));
|
||||
screen.set_palette("palette");
|
||||
|
||||
PALETTE(config, "palette").set_format(palette_device::xRGB_555, 0x200);
|
||||
GFXDECODE(config, m_gfxdecode, "palette", gfx_pass);
|
||||
|
||||
|
||||
/* sound hardware */
|
||||
// sound hardware
|
||||
SPEAKER(config, "mono").front_center();
|
||||
|
||||
GENERIC_LATCH_8(config, "soundlatch");
|
||||
|
||||
YM2203(config, "ymsnd", 14318180/4).add_route(ALL_OUTPUTS, "mono", 0.60);
|
||||
YM2203(config, "ymsnd", 14'318'180 / 4).add_route(ALL_OUTPUTS, "mono", 0.60);
|
||||
|
||||
OKIM6295(config, "oki", 792000, okim6295_device::PIN7_HIGH).add_route(ALL_OUTPUTS, "mono", 0.60); // clock frequency & pin 7 not verified
|
||||
OKIM6295(config, "oki", 792'000, okim6295_device::PIN7_HIGH).add_route(ALL_OUTPUTS, "mono", 0.60); // clock frequency & pin 7 not verified
|
||||
}
|
||||
|
||||
|
||||
ROM_START( pass )
|
||||
ROM_REGION( 0x40000, "maincpu", 0 ) /* 68k */
|
||||
ROM_REGION( 0x40000, "maincpu", 0 ) // 68k
|
||||
ROM_LOAD16_BYTE( "33", 0x00001, 0x20000, CRC(0c5f18f6) SHA1(49b60d46e4149ad1d49b044522a6888737c17e7d) )
|
||||
ROM_LOAD16_BYTE( "34", 0x00000, 0x20000, CRC(7b54573d) SHA1(251e99fa1f045ae4c90676e1953e49e8191440e4) )
|
||||
|
||||
ROM_REGION( 0x10000, "audiocpu", 0 ) /* z80 clone? */
|
||||
ROM_REGION( 0x10000, "audiocpu", 0 ) // z80 clone?
|
||||
ROM_LOAD( "23", 0x00000, 0x10000, CRC(b9a0ccde) SHA1(33e7dda247aa44b1933ae9c033c161c152276ce6) )
|
||||
|
||||
ROM_REGION( 0x40000, "oki", 0 ) /* samples? */
|
||||
ROM_REGION( 0x40000, "oki", 0 )
|
||||
ROM_LOAD( "31", 0x00000, 0x20000, CRC(c7315bbd) SHA1(c0bb392793cafc7b3f76da8fb26c6c16948f87e5) )
|
||||
|
||||
ROM_REGION( 0x40000, "gfx1", 0 ) /* fg layer 'sprites' */
|
||||
ROM_REGION( 0x40000, "fgtiles", 0 )
|
||||
ROM_LOAD16_BYTE( "35", 0x00000, 0x20000, CRC(2ab33f07) SHA1(23f2481450b3f43bbe3856c4cf595af74b1da2e0) )
|
||||
ROM_LOAD16_BYTE( "36", 0x00001, 0x20000, CRC(6677709d) SHA1(0d3df11097855294d606e46c0db0cf801c1dc28a) )
|
||||
|
||||
ROM_REGION( 0x80000, "gfx2", 0 ) /* bg tiles */
|
||||
ROM_LOAD16_BYTE( "37", 0x40000, 0x20000, CRC(296499e7) SHA1(b7727f7942e20a2428df84e99075a572189a0096) )
|
||||
ROM_LOAD16_BYTE( "39", 0x40001, 0x20000, CRC(35c0ad5c) SHA1(78e3ca8b2e382a3c7bc53ede2ef5611c520ab095) )
|
||||
ROM_REGION( 0x80000, "bgtiles", 0 )
|
||||
ROM_LOAD16_BYTE( "38", 0x00000, 0x20000, CRC(7f11b81a) SHA1(50253da7c13f9390fe7afd2faf17b8057f0bee1b) )
|
||||
ROM_LOAD16_BYTE( "40", 0x00001, 0x20000, CRC(80e0a71d) SHA1(e62c855f357e7492a59f8719c62a16d418dfa60b) )
|
||||
ROM_LOAD16_BYTE( "37", 0x40000, 0x20000, CRC(296499e7) SHA1(b7727f7942e20a2428df84e99075a572189a0096) )
|
||||
ROM_LOAD16_BYTE( "39", 0x40001, 0x20000, CRC(35c0ad5c) SHA1(78e3ca8b2e382a3c7bc53ede2ef5611c520ab095) )
|
||||
ROM_END
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
|
||||
GAME( 1992, pass, 0, pass, pass, pass_state, empty_init, ROT0, "Oksan", "Pass", MACHINE_SUPPORTS_SAVE )
|
||||
|
@ -1,50 +0,0 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood
|
||||
#ifndef MAME_INCLUDES_PASS_H
|
||||
#define MAME_INCLUDES_PASS_H
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "tilemap.h"
|
||||
|
||||
class pass_state : public driver_device
|
||||
{
|
||||
public:
|
||||
pass_state(const machine_config &mconfig, device_type type, const char *tag) :
|
||||
driver_device(mconfig, type, tag),
|
||||
m_bg_tilemap(nullptr),
|
||||
m_fg_tilemap(nullptr),
|
||||
m_bg_videoram(*this, "bg_videoram"),
|
||||
m_fg_videoram(*this, "fg_videoram"),
|
||||
m_maincpu(*this, "maincpu"),
|
||||
m_gfxdecode(*this, "gfxdecode")
|
||||
{
|
||||
}
|
||||
|
||||
void pass(machine_config &config);
|
||||
|
||||
protected:
|
||||
virtual void video_start() override;
|
||||
|
||||
private:
|
||||
void pass_bg_videoram_w(offs_t offset, uint16_t data);
|
||||
void pass_fg_videoram_w(offs_t offset, uint16_t data);
|
||||
TILE_GET_INFO_MEMBER(get_pass_bg_tile_info);
|
||||
TILE_GET_INFO_MEMBER(get_pass_fg_tile_info);
|
||||
|
||||
uint32_t screen_update_pass(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
|
||||
void pass_map(address_map &map);
|
||||
void pass_sound_io_map(address_map &map);
|
||||
void pass_sound_map(address_map &map);
|
||||
|
||||
tilemap_t *m_bg_tilemap = nullptr;
|
||||
tilemap_t *m_fg_tilemap = nullptr;
|
||||
|
||||
required_shared_ptr<uint16_t> m_bg_videoram;
|
||||
required_shared_ptr<uint16_t> m_fg_videoram;
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<gfxdecode_device> m_gfxdecode;
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_PASS_H
|
@ -1,61 +0,0 @@
|
||||
// license:BSD-3-Clause
|
||||
// copyright-holders:David Haywood
|
||||
/* video/pass.c - see drivers/pass.c for more info */
|
||||
|
||||
#include "emu.h"
|
||||
#include "pass.h"
|
||||
|
||||
/* background tilemap stuff */
|
||||
|
||||
TILE_GET_INFO_MEMBER(pass_state::get_pass_bg_tile_info)
|
||||
{
|
||||
int tileno, fx;
|
||||
|
||||
tileno = m_bg_videoram[tile_index] & 0x1fff;
|
||||
fx = (m_bg_videoram[tile_index] & 0xc000) >> 14;
|
||||
tileinfo.set(1, tileno, 0, TILE_FLIPYX(fx));
|
||||
|
||||
}
|
||||
|
||||
void pass_state::pass_bg_videoram_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_bg_videoram[offset] = data;
|
||||
m_bg_tilemap->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
/* foreground 'sprites' tilemap stuff */
|
||||
|
||||
TILE_GET_INFO_MEMBER(pass_state::get_pass_fg_tile_info)
|
||||
{
|
||||
int tileno, flip;
|
||||
|
||||
tileno = m_fg_videoram[tile_index] & 0x3fff;
|
||||
flip = (m_fg_videoram[tile_index] & 0xc000) >>14;
|
||||
|
||||
tileinfo.set(0, tileno, 0, TILE_FLIPYX(flip));
|
||||
|
||||
}
|
||||
|
||||
void pass_state::pass_fg_videoram_w(offs_t offset, uint16_t data)
|
||||
{
|
||||
m_fg_videoram[offset] = data;
|
||||
m_fg_tilemap->mark_tile_dirty(offset);
|
||||
}
|
||||
|
||||
/* video update / start */
|
||||
|
||||
void pass_state::video_start()
|
||||
{
|
||||
m_bg_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(pass_state::get_pass_bg_tile_info)), TILEMAP_SCAN_ROWS, 8, 8, 64, 32);
|
||||
m_fg_tilemap = &machine().tilemap().create(*m_gfxdecode, tilemap_get_info_delegate(*this, FUNC(pass_state::get_pass_fg_tile_info)), TILEMAP_SCAN_ROWS, 4, 4, 128, 64);
|
||||
|
||||
m_fg_tilemap->set_transparent_pen(255);
|
||||
}
|
||||
|
||||
uint32_t pass_state::screen_update_pass(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
{
|
||||
m_bg_tilemap->draw(screen, bitmap, cliprect, 0, 0);
|
||||
m_fg_tilemap->draw(screen, bitmap, cliprect, 0, 0);
|
||||
|
||||
return 0;
|
||||
}
|
@ -1246,17 +1246,6 @@ void sfbonus_state::sfbonus_io(address_map &map)
|
||||
}
|
||||
|
||||
|
||||
static const gfx_layout sfbonus_layout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ 0,1,2,3,4,5,6,7 },
|
||||
{ 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 },
|
||||
{ 0*64,1*64,2*64,3*64,4*64,5*64,6*64,7*64 },
|
||||
8*64
|
||||
};
|
||||
|
||||
static const gfx_layout sfbonus32_layout =
|
||||
{
|
||||
8,32,
|
||||
@ -1275,7 +1264,7 @@ static const gfx_layout sfbonus32_layout =
|
||||
|
||||
|
||||
static GFXDECODE_START( gfx_sfbonus )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, sfbonus_layout, 0x0, 2 )
|
||||
GFXDECODE_ENTRY( "gfx1", 0, gfx_8x8x8_raw, 0x0, 2 )
|
||||
GFXDECODE_ENTRY( "gfx2", 0, sfbonus32_layout, 0x0, 2 )
|
||||
GFXDECODE_END
|
||||
|
||||
|
@ -344,16 +344,6 @@ INPUT_PORTS_END
|
||||
|
||||
|
||||
|
||||
static const gfx_layout charlayout =
|
||||
{
|
||||
8,8,
|
||||
RGN_FRAC(1,1),
|
||||
8,
|
||||
{ 0, 1, 2, 3, 4, 5, 6, 7 },
|
||||
{ 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 },
|
||||
{ 0*64, 1*64, 2*64, 3*64, 4*64, 5*64, 6*64, 7*64 },
|
||||
64*8
|
||||
};
|
||||
|
||||
static const gfx_layout tilelayout =
|
||||
{
|
||||
@ -369,7 +359,7 @@ static const gfx_layout tilelayout =
|
||||
};
|
||||
|
||||
static GFXDECODE_START( gfx_crshrace )
|
||||
GFXDECODE_ENTRY( "chars", 0, charlayout, 0, 1 )
|
||||
GFXDECODE_ENTRY( "chars", 0, gfx_8x8x8_raw, 0, 1 )
|
||||
GFXDECODE_ENTRY( "tiles", 0, tilelayout, 256, 16 )
|
||||
GFXDECODE_ENTRY( "sprites", 0, gfx_16x16x4_packed_lsb, 512, 32 )
|
||||
GFXDECODE_END
|
||||
|
Loading…
Reference in New Issue
Block a user