summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/includes/hyperspt.h
blob: f9260d05736e8f78322990b6266b689aaca71b60 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#include "sound/sn76496.h"

class hyperspt_state : public driver_device
{
public:
	hyperspt_state(const machine_config &mconfig, device_type type, const char *tag)
		: driver_device(mconfig, type, tag) ,
		m_spriteram(*this, "spriteram"),
		m_scroll(*this, "scroll"),
		m_videoram(*this, "videoram"),
		m_colorram(*this, "colorram"),
		m_sn(*this, "snsnd")
	{ }

	/* memory pointers */
	required_shared_ptr<UINT8> m_spriteram;
	required_shared_ptr<UINT8> m_scroll;
	required_shared_ptr<UINT8> m_videoram;
	required_shared_ptr<UINT8> m_colorram;
	optional_device<sn76496_new_device> m_sn;
	UINT8 *  m_scroll2;
	UINT8 *  m_spriteram2;

	/* video-related */
	tilemap_t  *m_bg_tilemap;
	int		 m_sprites_gfx_banked;

	UINT8    m_irq_mask;
	DECLARE_WRITE8_MEMBER(hyperspt_coin_counter_w);
	DECLARE_WRITE8_MEMBER(irq_mask_w);
	DECLARE_WRITE8_MEMBER(hyperspt_videoram_w);
	DECLARE_WRITE8_MEMBER(hyperspt_colorram_w);
	DECLARE_WRITE8_MEMBER(hyperspt_flipscreen_w);
	DECLARE_DRIVER_INIT(hyperspt);

	UINT8 m_SN76496_latch;
	DECLARE_WRITE8_MEMBER( konami_SN76496_latch_w ) { m_SN76496_latch = data; };
	DECLARE_WRITE8_MEMBER( konami_SN76496_w ) { m_sn->write(space, offset, m_SN76496_latch); };
	TILE_GET_INFO_MEMBER(get_bg_tile_info);
	TILE_GET_INFO_MEMBER(roadf_get_bg_tile_info);
	virtual void video_start();
	virtual void palette_init();
	DECLARE_VIDEO_START(roadf);
};

/*----------- defined in video/hyperspt.c -----------*/




SCREEN_UPDATE_IND16( hyperspt );