mirror of
https://github.com/holub/mame
synced 2025-10-05 08:41:31 +03:00
sms.cpp: Eliminate remaining uses of machine().device (nw)
This commit is contained in:
parent
33383cdaa7
commit
f09d5d3849
@ -68,7 +68,11 @@ public:
|
||||
m_has_bios_2000(false),
|
||||
m_has_bios_full(false),
|
||||
m_has_jpn_sms_cart_slot(false),
|
||||
m_has_pwr_led(false)
|
||||
m_has_pwr_led(false),
|
||||
m_slot(*this, "slot"),
|
||||
m_cardslot(*this, "mycard"),
|
||||
m_smsexpslot(*this, "smsexp"),
|
||||
m_sgexpslot(*this, "sgexp")
|
||||
{ }
|
||||
|
||||
void sms_base(machine_config &config);
|
||||
@ -250,9 +254,10 @@ protected:
|
||||
|
||||
// slot devices
|
||||
sega8_cart_slot_device *m_cartslot;
|
||||
sega8_card_slot_device *m_cardslot;
|
||||
sms_expansion_slot_device *m_smsexpslot;
|
||||
sg1000_expansion_slot_device *m_sgexpslot;
|
||||
optional_device<sega8_cart_slot_device> m_slot;
|
||||
optional_device<sega8_card_slot_device> m_cardslot;
|
||||
optional_device<sms_expansion_slot_device> m_smsexpslot;
|
||||
optional_device<sg1000_expansion_slot_device> m_sgexpslot;
|
||||
};
|
||||
|
||||
class smssdisp_state : public sms_state
|
||||
|
@ -1033,10 +1033,7 @@ void sms_state::machine_start()
|
||||
m_led_pwr = 1;
|
||||
}
|
||||
|
||||
m_cartslot = machine().device<sega8_cart_slot_device>("slot");
|
||||
m_cardslot = machine().device<sega8_card_slot_device>("mycard");
|
||||
m_smsexpslot = machine().device<sms_expansion_slot_device>("smsexp");
|
||||
m_sgexpslot = machine().device<sg1000_expansion_slot_device>("sgexp");
|
||||
m_cartslot = m_slot.target();
|
||||
m_space = &m_maincpu->space(AS_PROGRAM);
|
||||
|
||||
if (m_mainram == nullptr)
|
||||
@ -1158,11 +1155,11 @@ void sms_state::machine_reset()
|
||||
|
||||
void smssdisp_state::machine_reset()
|
||||
{
|
||||
sms_state::machine_reset();
|
||||
|
||||
m_store_control = 0;
|
||||
m_store_cart_selection_data = 0;
|
||||
store_select_cart(m_store_cart_selection_data);
|
||||
|
||||
sms_state::machine_reset();
|
||||
}
|
||||
|
||||
READ8_MEMBER(smssdisp_state::sms_store_cart_select_r)
|
||||
|
Loading…
Reference in New Issue
Block a user