mirror of
https://github.com/holub/mame
synced 2025-04-24 09:20:02 +03:00
spclforc, spcfrcii: Add sound device
This commit is contained in:
parent
f0be18a446
commit
faa0ede657
@ -412,6 +412,8 @@ Donkey Kong Notes
|
||||
#include "cpu/s2650/s2650.h"
|
||||
#include "cpu/m6502/m6502.h"
|
||||
#include "machine/eepromser.h"
|
||||
#include "sound/sn76496.h"
|
||||
#include "speaker.h"
|
||||
|
||||
|
||||
/*************************************
|
||||
@ -912,6 +914,11 @@ void dkong_state::s2650_data_map(address_map &map)
|
||||
map(S2650_DATA_PORT, S2650_DATA_PORT).w(FUNC(dkong_state::s2650_data_w));
|
||||
}
|
||||
|
||||
void spclforc_state::data_map(address_map &map)
|
||||
{
|
||||
map(S2650_DATA_PORT, S2650_DATA_PORT).w("snsnd", FUNC(sn76496_device::write));
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*************************************
|
||||
@ -1870,11 +1877,16 @@ void dkong_state::herbiedk(machine_config &config)
|
||||
downcast<s2650_device &>(*m_maincpu).sense_handler().set(m_screen, FUNC(screen_device::vblank)).invert(); // ???
|
||||
}
|
||||
|
||||
void dkong_state::spclforc(machine_config &config)
|
||||
void spclforc_state::spclforc(machine_config &config)
|
||||
{
|
||||
herbiedk(config);
|
||||
|
||||
downcast<s2650_device &>(*m_maincpu).set_addrmap(AS_DATA, &spclforc_state::data_map);
|
||||
config.device_remove("soundcpu");
|
||||
m_screen->set_screen_update(FUNC(dkong_state::screen_update_spclforc));
|
||||
|
||||
m_screen->set_screen_update(FUNC(spclforc_state::screen_update_spclforc));
|
||||
|
||||
SN76496(config, "snsnd", CLOCK_1H).add_route(ALL_OUTPUTS, "mono", 0.5);
|
||||
}
|
||||
|
||||
/*************************************
|
||||
@ -3791,8 +3803,8 @@ GAME( 1984, herodku, hero, s2650, herodk, dkong_state, empty_init,
|
||||
GAME( 1984, 8ballact, 0, herbiedk, 8ballact, dkong_state, empty_init, ROT270, "Seatongrove Ltd (Magic Electronics USA license)", "Eight Ball Action (DK conversion)", MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1984, 8ballact2, 8ballact, herbiedk, 8ballact, dkong_state, empty_init, ROT270, "Seatongrove Ltd (Magic Electronics USA license)", "Eight Ball Action (DKJr conversion)", MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1984, shootgal, 0, s2650, shootgal, dkong_state, empty_init, ROT0, "Seatongrove Ltd (Zaccaria license)", "Shooting Gallery", MACHINE_IMPERFECT_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1985, spclforc, 0, spclforc, spclforc, dkong_state, empty_init, ROT270, "Senko Industries (Magic Electronics Inc. license)", "Special Forces", MACHINE_NO_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1985, spcfrcii, 0, spclforc, spclforc, dkong_state, empty_init, ROT270, "Senko Industries (Magic Electronics Inc. license)", "Special Forces II", MACHINE_NO_SOUND | MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1985, spclforc, 0, spclforc, spclforc, spclforc_state, empty_init, ROT270, "Senko Industries (Magic Electronics Inc. license)", "Special Forces", MACHINE_SUPPORTS_SAVE )
|
||||
GAME( 1985, spcfrcii, 0, spclforc, spclforc, spclforc_state, empty_init, ROT270, "Senko Industries (Magic Electronics Inc. license)", "Special Forces II", MACHINE_SUPPORTS_SAVE )
|
||||
|
||||
/* EPOS */
|
||||
GAME( 1984, drakton, 0, drakton, drakton, dkong_state, init_drakton, ROT270, "Epos Corporation", "Drakton (DK conversion)", MACHINE_SUPPORTS_SAVE )
|
||||
|
@ -133,7 +133,6 @@ public:
|
||||
void ddk_braze(machine_config &config);
|
||||
void dk3_braze(machine_config &config);
|
||||
void strtheat(machine_config &config);
|
||||
void spclforc(machine_config &config);
|
||||
void s2650(machine_config &config);
|
||||
void dkongjr(machine_config &config);
|
||||
void radarscp1(machine_config &config);
|
||||
@ -162,7 +161,7 @@ public:
|
||||
|
||||
DECLARE_WRITE_LINE_MEMBER(dk_braze_a15);
|
||||
|
||||
private:
|
||||
protected:
|
||||
/* devices */
|
||||
required_device<cpu_device> m_maincpu;
|
||||
optional_device<mcs48_cpu_device> m_soundcpu;
|
||||
@ -255,6 +254,7 @@ private:
|
||||
memory_bank_creator m_bank2;
|
||||
memory_passthrough_handler m_dkong3_tap[2];
|
||||
|
||||
private:
|
||||
uint8_t hb_dma_read_byte(offs_t offset);
|
||||
void hb_dma_write_byte(offs_t offset, uint8_t data);
|
||||
void dkong3_coin_counter_w(offs_t offset, uint8_t data);
|
||||
@ -309,7 +309,6 @@ private:
|
||||
void dkong_p1_w(uint8_t data);
|
||||
uint32_t screen_update_dkong(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
uint32_t screen_update_pestplce(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
uint32_t screen_update_spclforc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
DECLARE_WRITE_LINE_MEMBER(s2650_interrupt);
|
||||
DECLARE_WRITE_LINE_MEMBER(vblank_irq);
|
||||
TIMER_CALLBACK_MEMBER(scanline_callback);
|
||||
@ -337,7 +336,7 @@ private:
|
||||
void s2650_io_map(address_map &map);
|
||||
void s2650_map(address_map &map);
|
||||
|
||||
private:
|
||||
protected:
|
||||
// video/dkong.c
|
||||
void radarscp_step(int line_cnt);
|
||||
void radarscp_scanline(int scanline);
|
||||
@ -346,4 +345,20 @@ private:
|
||||
void radarscp_draw_background(bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
};
|
||||
|
||||
class spclforc_state : public dkong_state
|
||||
{
|
||||
public:
|
||||
spclforc_state(const machine_config &mconfig, device_type type, const char *tag)
|
||||
: dkong_state(mconfig, type, tag)
|
||||
{
|
||||
}
|
||||
|
||||
void spclforc(machine_config &config);
|
||||
|
||||
private:
|
||||
void data_map(address_map &map);
|
||||
|
||||
uint32_t screen_update_spclforc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
|
||||
};
|
||||
|
||||
#endif // MAME_INCLUDES_DKONG_H
|
||||
|
@ -1016,7 +1016,7 @@ uint32_t dkong_state::screen_update_pestplce(screen_device &screen, bitmap_ind16
|
||||
return 0;
|
||||
}
|
||||
|
||||
uint32_t dkong_state::screen_update_spclforc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
uint32_t spclforc_state::screen_update_spclforc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
|
||||
{
|
||||
machine().tilemap().set_flip_all(m_flip ? TILEMAP_FLIPX | TILEMAP_FLIPY : 0);
|
||||
m_bg_tilemap->draw(screen, bitmap, cliprect, 0, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user