init even more vars (includes)

This commit is contained in:
Robbbert 2022-04-10 23:48:13 +10:00
parent 1871bcfff0
commit 1873823a53
76 changed files with 1000 additions and 1000 deletions

View File

@ -54,7 +54,7 @@ protected:
optional_memory_bank m_mainbank;
/* machine state */
uint8_t m_game_selected; /* 0 = Ms. Pac-Man, 1 = Galaga */
uint8_t m_game_selected = 0; /* 0 = Ms. Pac-Man, 1 = Galaga */
/* devices */
required_device<cpu_device> m_maincpu;
@ -69,9 +69,9 @@ protected:
std::unique_ptr<uint8_t[]> m_ram_48000;
/* 25pacman and 20pacgal store the sprite palette at a different address, this is a hardware difference and confirmed NOT to be a register */
uint8_t m_sprite_pal_base;
uint8_t m_sprite_pal_base = 0;
uint8_t m_irq_mask;
uint8_t m_irq_mask = 0;
void irqack_w(uint8_t data);
void timer_pulse_w(uint8_t data);
void _20pacgal_coin_counter_w(uint8_t data);

View File

@ -130,44 +130,44 @@ public:
DECLARE_WRITE_LINE_MEMBER(a2bus_inh_w);
// these need to be public for now
uint32_t m_flags;
int m_enable_mask;
uint32_t m_flags = 0;
int m_enable_mask = 0;
void apple3(machine_config &config);
void apple3_map(address_map &map);
private:
uint8_t m_via_0_a;
uint8_t m_via_0_b;
uint8_t m_via_1_a;
uint8_t m_via_1_b;
offs_t m_zpa;
uint8_t m_last_n;
uint8_t m_char_mem[0x800];
uint8_t m_via_0_a = 0;
uint8_t m_via_0_b = 0;
uint8_t m_via_1_a = 0;
uint8_t m_via_1_b = 0;
offs_t m_zpa = 0;
uint8_t m_last_n = 0;
uint8_t m_char_mem[0x800]{};
std::unique_ptr<uint32_t[]> m_hgr_map;
bool m_sync;
bool m_rom_has_been_disabled;
int m_cnxx_slot;
uint8_t m_indir_bank;
bool m_sync = false;
bool m_rom_has_been_disabled = false;
int m_cnxx_slot = 0;
uint8_t m_indir_bank = 0;
uint8_t *m_bank2, *m_bank3, *m_bank4, *m_bank5, *m_bank8, *m_bank9;
uint8_t *m_bank10, *m_bank11;
uint8_t *m_bank6, *m_bank7rd, *m_bank7wr;
int m_bell_state;
int m_c040_time;
uint16_t m_lastchar, m_strobe;
uint8_t m_transchar;
bool m_charwrt;
uint8_t *m_bank2 = nullptr, *m_bank3 = nullptr, *m_bank4 = nullptr, *m_bank5 = nullptr, *m_bank8 = nullptr, *m_bank9 = nullptr;
uint8_t *m_bank10 = nullptr, *m_bank11 = nullptr;
uint8_t *m_bank6 = nullptr, *m_bank7rd = nullptr, *m_bank7wr = nullptr;
int m_bell_state = 0;
int m_c040_time = 0;
uint16_t m_lastchar = 0, m_strobe = 0;
uint8_t m_transchar = 0;
bool m_charwrt = false;
emu_timer *m_scanstart, *m_scanend;
emu_timer *m_scanstart = nullptr, *m_scanend = nullptr;
int m_analog_sel;
bool m_ramp_active;
int m_pdl_charge;
int m_va, m_vb, m_vc;
int m_smoothscr;
int m_analog_sel = 0;
bool m_ramp_active = false;
int m_pdl_charge = 0;
int m_va = 0, m_vb = 0, m_vc = 0;
int m_smoothscr = 0;
int m_inh_state;
int m_inh_state = 0;
};
#endif // MAME_INCLUDES_APPLE3_H

View File

@ -50,9 +50,9 @@ private:
required_memory_bank m_audiobank;
/* video-related */
tilemap_t *m_txt_tilemap;
tilemap_t *m_mid_tilemap;
tilemap_t *m_bak_tilemap;
tilemap_t *m_txt_tilemap = nullptr;
tilemap_t *m_mid_tilemap = nullptr;
tilemap_t *m_bak_tilemap = nullptr;
std::unique_ptr<u8[]> m_decoded_gfx[2];
/* devices */

View File

@ -58,17 +58,17 @@ private:
optional_device<adc0808_device> m_adc;
optional_ioport m_in1;
bool m_is_pitfight;
bool m_is_pitfight = false;
required_shared_ptr<uint16_t> m_mo_command;
bool m_bslapstic_primed;
bool m_bslapstic_primed = false;
uint8_t m_pfscroll_xoffset;
uint16_t m_current_control;
uint8_t m_playfield_tile_bank;
uint16_t m_playfield_xscroll;
uint16_t m_playfield_yscroll;
uint8_t m_pfscroll_xoffset = 0;
uint16_t m_current_control = 0;
uint8_t m_playfield_tile_bank = 0;
uint16_t m_playfield_xscroll = 0;
uint16_t m_playfield_yscroll = 0;
void video_int_ack_w(uint16_t data = 0);
TIMER_DEVICE_CALLBACK_MEMBER(scanline_update);

View File

@ -57,23 +57,23 @@ protected:
required_device<asic65_device> m_asic65;
optional_device<adc0808_device> m_adc;
uint16_t m_playfield_base;
uint16_t m_playfield_base = 0;
uint16_t m_current_control;
uint8_t m_playfield_tile_bank;
uint8_t m_playfield_color_bank;
uint16_t m_playfield_xscroll;
uint16_t m_playfield_yscroll;
uint16_t m_current_control = 0;
uint8_t m_playfield_tile_bank = 0;
uint8_t m_playfield_color_bank = 0;
uint16_t m_playfield_xscroll = 0;
uint16_t m_playfield_yscroll = 0;
required_shared_ptr<uint16_t> m_mo_command;
int m_sloop_bank;
int m_sloop_next_bank;
int m_sloop_offset;
int m_sloop_state;
uint16_t * m_sloop_base;
int m_sloop_bank = 0;
int m_sloop_next_bank = 0;
int m_sloop_offset = 0;
int m_sloop_state = 0;
uint16_t * m_sloop_base = nullptr;
uint32_t m_last_accesses[8];
uint32_t m_last_accesses[8]{};
};
class atarig42_0x200_state : public atarig42_state

View File

@ -52,7 +52,7 @@ protected:
private:
bool m_is_primrage;
bool m_is_primrage = false;
required_device<palette_device> m_palette;
memory_share_creator<uint16_t> m_colorram;
@ -66,18 +66,18 @@ private:
optional_ioport m_coin_io;
optional_ioport m_fake_io;
bool m_scanline_int_state;
bool m_video_int_state;
bool m_scanline_int_state = false;
bool m_video_int_state = false;
bitmap_ind16 m_pf_bitmap;
bitmap_ind16 m_an_bitmap;
uint8_t m_playfield_tile_bank;
uint8_t m_playfield_color_bank;
uint16_t m_playfield_xscroll;
uint16_t m_playfield_yscroll;
uint8_t m_playfield_tile_bank = 0;
uint8_t m_playfield_color_bank = 0;
uint16_t m_playfield_xscroll = 0;
uint16_t m_playfield_yscroll = 0;
uint32_t m_tram_checksum;
uint32_t m_tram_checksum = 0;
required_shared_ptr<uint32_t> m_mo_command;
required_device<atari_cage_device> m_cage;
@ -85,10 +85,10 @@ private:
void (atarigt_state::*m_protection_w)(address_space &space, offs_t offset, uint16_t data);
void (atarigt_state::*m_protection_r)(address_space &space, offs_t offset, uint16_t *data);
bool m_ignore_writes;
offs_t m_protaddr[ADDRSEQ_COUNT];
uint8_t m_protmode;
uint16_t m_protresult;
bool m_ignore_writes = false;
offs_t m_protaddr[ADDRSEQ_COUNT]{};
uint8_t m_protmode = 0;
uint16_t m_protresult = 0;
std::unique_ptr<uint8_t[]> m_protdata;
INTERRUPT_GEN_MEMBER(scanline_int_gen);

View File

@ -83,8 +83,8 @@ protected:
required_device<atari_motion_objects_device> m_mob;
required_device<palette_device> m_palette;
uint8_t m_joystick_type;
uint8_t m_trackball_type;
uint8_t m_joystick_type = 0;
uint8_t m_trackball_type = 0;
optional_device<adc0808_device> m_adc;
optional_device<input_merger_device> m_ajsint;
@ -94,16 +94,16 @@ protected:
required_device<tilemap_device> m_alpha_tilemap;
required_shared_ptr<uint16_t> m_xscroll;
required_shared_ptr<uint16_t> m_yscroll;
uint16_t m_playfield_lookup[256];
uint8_t m_playfield_tile_bank;
uint16_t m_playfield_priority_pens;
uint16_t m_playfield_lookup[256]{};
uint8_t m_playfield_tile_bank = 0;
uint16_t m_playfield_priority_pens = 0;
required_device<timer_device> m_yscroll_reset_timer;
// INT3 tracking
int m_next_timer_scanline;
int m_next_timer_scanline = 0;
required_device<timer_device> m_scanline_timer;
required_device<timer_device> m_int3off_timer;
uint8_t m_scanline_int_state;
uint8_t m_scanline_int_state = 0;
// speech
optional_device<tms5220_device> m_tms;
@ -112,11 +112,11 @@ protected:
optional_device<via6522_device> m_via;
// graphics bank tracking
uint8_t m_bank_gfx[3][8];
uint8_t m_bank_color_shift[MAX_GFX_ELEMENTS];
uint8_t m_bankselect;
uint8_t m_bank_gfx[3][8]{};
uint8_t m_bank_color_shift[MAX_GFX_ELEMENTS]{};
uint8_t m_bankselect = 0;
uint8_t m_cur[2][2];
uint8_t m_cur[2][2]{};
void video_int_ack_w(uint8_t data = 0);
template<int Input> uint8_t digital_joystick_r();

View File

@ -116,7 +116,7 @@ private:
void mem_map(address_map &map);
u8 crt8002(u8 ac_ra, u8 ac_chr, u8 ac_attr, u16 ac_cnt, bool ac_curs);
bool m_port15 = 0; // rom switched in (0), out (1)
bool m_port15 = false; // rom switched in (0), out (1)
u8 m_port17 = 0U;
u8 m_port17_rdy = 0U;
u8 m_port19 = 0U;
@ -128,7 +128,7 @@ private:
u16 m_cnt = 0U;
u16 m_alpha_address = 0U;
u16 m_graph_address = 0U;
bool m_centronics_busy = 0;
bool m_centronics_busy = false;
std::unique_ptr<u8[]> m_vram; // video ram, 64k dynamic
std::unique_ptr<u8[]> m_aram; // attribute ram, 2k static
std::unique_ptr<u8[]> m_ram; // main ram, 256k dynamic

View File

@ -159,34 +159,34 @@ private:
/* global data */
uint8_t m_shooter;
uint8_t m_shooter_x;
uint8_t m_shooter_y;
uint8_t m_adc_shift;
uint8_t m_shooter = 0;
uint8_t m_shooter_x = 0;
uint8_t m_shooter_y = 0;
uint8_t m_adc_shift = 0;
/* random number generator states */
uint8_t m_rand17[POLY17_SIZE + 1];
uint8_t m_rand17[POLY17_SIZE + 1]{};
/* ADC I/O states */
int8_t m_analog_input_data[4];
uint8_t m_adc_value;
int8_t m_analog_input_data[4]{};
uint8_t m_adc_value = 0;
/* game-specific states */
uint8_t m_nstocker_bits;
uint8_t m_spiker_expand_color;
uint8_t m_spiker_expand_bgcolor;
uint8_t m_spiker_expand_bits;
uint8_t m_grudge_steering_result;
uint8_t m_grudge_last_steering[3];
uint8_t m_teamht_input;
uint8_t m_nstocker_bits = 0;
uint8_t m_spiker_expand_color = 0;
uint8_t m_spiker_expand_bgcolor = 0;
uint8_t m_spiker_expand_bits = 0;
uint8_t m_grudge_steering_result = 0;
uint8_t m_grudge_last_steering[3]{};
uint8_t m_teamht_input = 0;
/* video data */
uint8_t m_expanded_videoram[256*256];
uint8_t *m_sprite_data;
uint32_t m_sprite_mask;
uint8_t *m_sprite_bank[2];
uint8_t m_expanded_videoram[256*256]{};
uint8_t *m_sprite_data = nullptr;
uint32_t m_sprite_mask = 0;
uint8_t *m_sprite_bank[2]{};
uint8_t m_palettebank_vis;
uint8_t m_palettebank_vis = 0;
required_shared_ptr<uint8_t> m_spriteram;
required_shared_ptr<uint8_t> m_videoram;

View File

@ -122,25 +122,25 @@ protected:
required_memory_bank m_bank;
/* memory state */
int m_curbank;
int m_curbank = 0;
/* PIT state */
int m_pit_out2;
int m_pit_out2 = 0;
/* keyboard state */
int m_key_data[9];
int m_key_sin;
int m_key_stb;
int m_key_shift;
int m_key_data[9]{};
int m_key_sin = 0;
int m_key_stb = 0;
int m_key_shift = 0;
/* floppy state */
int m_motor_on;
int m_motor0;
int m_motor1;
int m_motor_on = 0;
int m_motor0 = 0;
int m_motor1 = 0;
int m_centronics_busy;
int m_centronics_fault;
int m_centronics_perror;
int m_centronics_busy = 0;
int m_centronics_fault = 0;
int m_centronics_perror = 0;
};
#endif

View File

@ -77,14 +77,14 @@ public:
static void floppy_formats(format_registration &fr);
// keyboard state
uint8_t m_kb;
uint8_t m_kb = 0;
// memory state
uint8_t m_bank;
uint8_t m_bank = 0;
// floppy state
int m_mtron;
int m_mfdbk;
int m_mtron = 0;
int m_mfdbk = 0;
// video state
optional_shared_ptr<uint8_t> m_video_ram;

View File

@ -104,41 +104,41 @@ protected:
optional_memory_region m_user5_region;
private:
u32 m_cram_gfxflash_bank;
u32 m_cram_gfxflash_bank = 0;
std::unique_ptr<u32[]> m_char_ram;
std::unique_ptr<u32[]> m_eeprom;
std::unique_ptr<u8[]> m_ss_ram;
std::unique_ptr<u32[]> m_spritelist;
u32 m_ppu_gscroll_buff[0x20/4];
s16 m_ss_hscroll;
s16 m_ss_vscroll;
u8 m_ss_pal_base;
u32 m_screenwidth;
u32 m_ppu_gscroll_buff[0x20/4]{};
s16 m_ss_hscroll = 0;
s16 m_ss_vscroll = 0;
u8 m_ss_pal_base = 0;
u32 m_screenwidth = 0;
std::unique_ptr<u32[]> m_mame_colours;
bitmap_rgb32 m_renderbuffer_bitmap;
rectangle m_renderbuffer_clip;
u8* m_user4;
u8* m_user4 = nullptr;
std::unique_ptr<u8[]> m_user4_allocated;
u32 m_key1;
u32 m_key2;
int m_altEncryption;
u16 m_dma_status;
u16 m_spritelist_dma;
u32 m_cram_bank;
u16 m_current_eeprom_read;
u32 m_paldma_source;
u32 m_paldma_realsource;
u32 m_paldma_dest;
u32 m_paldma_fade;
u32 m_paldma_other2;
u32 m_paldma_length;
u32 m_chardma_source;
u32 m_chardma_other;
int m_rle_length;
int m_last_normal_byte;
u16 m_lastb;
u16 m_lastb2;
u8* m_user5;
u32 m_key1 = 0;
u32 m_key2 = 0;
int m_altEncryption = 0;
u16 m_dma_status = 0;
u16 m_spritelist_dma = 0;
u32 m_cram_bank = 0;
u16 m_current_eeprom_read = 0;
u32 m_paldma_source = 0;
u32 m_paldma_realsource = 0;
u32 m_paldma_dest = 0;
u32 m_paldma_fade = 0;
u32 m_paldma_other2 = 0;
u32 m_paldma_length = 0;
u32 m_chardma_source = 0;
u32 m_chardma_other = 0;
int m_rle_length = 0;
int m_last_normal_byte = 0;
u16 m_lastb = 0;
u16 m_lastb2 = 0;
u8* m_user5 = nullptr;
std::unique_ptr<u8[]> m_user5_allocated;
u8 ssram_r(offs_t offset);

View File

@ -48,13 +48,13 @@ private:
required_memory_bank m_vlmbank;
// video-related
tilemap_t *m_fg_tilemap;
tilemap_t *m_bg_tilemap;
uint8_t m_vregs[2][5];
uint8_t m_charbank[2];
tilemap_t *m_fg_tilemap = nullptr;
tilemap_t *m_bg_tilemap = nullptr;
uint8_t m_vregs[2][5]{};
uint8_t m_charbank[2]{};
// misc
uint8_t m_int_enable[2];
uint8_t m_int_enable[2]{};
// devices
required_device<cpu_device> m_maincpu;

View File

@ -89,14 +89,14 @@ private:
optional_memory_bank m_sndbank;
int m_coin_counter_bit;
int m_coin_counter_bit = 0;
std::unique_ptr<uint16_t[]> m_vram;
int m_buffer;
int m_buffer = 0;
// speedups - see machine/eolithsp.c
int m_speedup_address;
int m_speedup_address2;
int m_speedup_resume_scanline;
int m_speedup_vblank;
int m_speedup_scanline;
int m_speedup_address = 0;
int m_speedup_address2 = 0;
int m_speedup_resume_scanline = 0;
int m_speedup_vblank = 0;
int m_speedup_scanline = 0;
};

View File

@ -40,16 +40,16 @@ private:
required_shared_ptr<uint8_t> m_spriteram;
/* video-related */
tilemap_t *m_freek_tilemap;
tilemap_t *m_freek_tilemap = nullptr;
/* misc */
int m_inval;
int m_outval;
int m_cnt; // used by oigas
int m_romaddr;
int m_spinner;
int m_nmi_en;
int m_ff_data;
int m_inval = 0;
int m_outval = 0;
int m_cnt = 0; // used by oigas
int m_romaddr = 0;
int m_spinner = 0;
int m_nmi_en = 0;
int m_ff_data = 0;
std::unique_ptr<uint8_t[]> m_decrypted_opcodes;
DECLARE_WRITE_LINE_MEMBER(flipscreen_x_w);
DECLARE_WRITE_LINE_MEMBER(flipscreen_y_w);

View File

@ -55,7 +55,7 @@ private:
optional_shared_ptr<uint16_t> m_screenram;
/* video-related */
tilemap_t *m_tilemap[2];
tilemap_t *m_tilemap[2]{};
DECLARE_WRITE_LINE_MEMBER(coin1_lockout_w);
DECLARE_WRITE_LINE_MEMBER(coin2_lockout_w);
@ -87,7 +87,7 @@ private:
void thoop_map(address_map &map);
/* per-game configuration */
uint8_t m_sprite_palette_force_high;
uint8_t m_sprite_palette_force_high = 0;
static constexpr double FRAMERATE_922804 = 57.42;
};

View File

@ -67,11 +67,11 @@ private:
struct gaelco3d_object_data
{
uint32_t tex, color;
float ooz_dx, ooz_dy, ooz_base;
float uoz_dx, uoz_dy, uoz_base;
float voz_dx, voz_dy, voz_base;
float z0;
uint32_t tex = 0, color = 0;
float ooz_dx = 0, ooz_dy = 0, ooz_base = 0;
float uoz_dx = 0, uoz_dy = 0, uoz_base = 0;
float voz_dx = 0, voz_dy = 0, voz_base = 0;
float z0 = 0;
};
class gaelco3d_renderer : public poly_manager<float, gaelco3d_object_data, 1>
@ -91,9 +91,9 @@ private:
private:
bitmap_ind16 m_screenbits;
bitmap_ind16 m_zbuffer;
uint32_t m_polygons;
offs_t m_texture_size;
offs_t m_texmask_size;
uint32_t m_polygons = 0;
offs_t m_texture_size = 0;
offs_t m_texmask_size = 0;
std::unique_ptr<uint8_t[]> m_texture;
std::unique_ptr<uint8_t[]> m_texmask;
@ -124,22 +124,22 @@ private:
optional_ioport_array<4> m_analog;
required_memory_bank m_adsp_bank;
uint8_t m_sound_status;
uint8_t m_analog_ports[4];
uint32_t m_fp_analog_ports[2];
uint32_t m_fp_lenght[2];
uint8_t m_fp_clock;
uint8_t m_fp_state;
uint8_t m_framenum;
uint8_t m_adsp_ireg;
offs_t m_adsp_ireg_base;
offs_t m_adsp_incs;
offs_t m_adsp_size;
uint8_t m_sound_status = 0;
uint8_t m_analog_ports[4]{};
uint32_t m_fp_analog_ports[2]{};
uint32_t m_fp_lenght[2]{};
uint8_t m_fp_clock = 0;
uint8_t m_fp_state = 0;
uint8_t m_framenum = 0;
uint8_t m_adsp_ireg = 0;
offs_t m_adsp_ireg_base = 0;
offs_t m_adsp_incs = 0;
offs_t m_adsp_size = 0;
std::unique_ptr<rgb_t[]> m_palette;
std::unique_ptr<uint32_t[]> m_polydata_buffer;
uint32_t m_polydata_count;
int m_lastscan;
int m_video_changed;
uint32_t m_polydata_count = 0;
int m_lastscan = 0;
int m_video_changed = 0;
std::unique_ptr<gaelco3d_renderer> m_poly;
void irq_ack_w(uint16_t data);

View File

@ -37,33 +37,33 @@ public:
m_cart_high(*this, "carthigh")
{ }
uint8_t m_gb_io[0x10];
uint8_t m_gb_io[0x10]{};
/* Timer related */
uint16_t m_divcount;
uint8_t m_shift;
uint16_t m_shift_cycles;
uint8_t m_triggering_irq;
uint8_t m_reloading;
uint16_t m_divcount = 0;
uint8_t m_shift = 0;
uint16_t m_shift_cycles = 0;
uint8_t m_triggering_irq = 0;
uint8_t m_reloading = 0;
/* Serial I/O related */
uint16_t m_internal_serial_clock;
uint16_t m_internal_serial_frequency;
uint32_t m_sio_count; /* Serial I/O counter */
uint16_t m_internal_serial_clock = 0;
uint16_t m_internal_serial_frequency = 0;
uint32_t m_sio_count = 0; /* Serial I/O counter */
/* SGB variables */
int8_t m_sgb_packets;
uint8_t m_sgb_bitcount;
uint8_t m_sgb_bytecount;
uint8_t m_sgb_start;
uint8_t m_sgb_rest;
uint8_t m_sgb_controller_no;
uint8_t m_sgb_controller_mode;
uint8_t m_sgb_data[0x100];
int8_t m_sgb_packets = 0;
uint8_t m_sgb_bitcount = 0;
uint8_t m_sgb_bytecount = 0;
uint8_t m_sgb_start = 0;
uint8_t m_sgb_rest = 0;
uint8_t m_sgb_controller_no = 0;
uint8_t m_sgb_controller_mode = 0;
uint8_t m_sgb_data[0x100]{};
/* CGB variables */
uint8_t *m_gbc_rammap[8]; /* (CGB) Addresses of internal RAM banks */
uint8_t m_gbc_rambank; /* (CGB) Current CGB RAM bank */
uint8_t *m_gbc_rammap[8]{}; /* (CGB) Addresses of internal RAM banks */
uint8_t m_gbc_rambank = 0; /* (CGB) Current CGB RAM bank */
void gb_io_w(offs_t offset, uint8_t data);
void gb_io2_w(offs_t offset, uint8_t data);

View File

@ -48,26 +48,26 @@ private:
void audio_tick(int ref);
// DMA
emu_timer *m_dma_timer[4];
uint32_t m_dma_src[4];
uint32_t m_dma_dst[4];
uint16_t m_dma_cnt[4];
emu_timer *m_dma_timer[4]{};
uint32_t m_dma_src[4]{};
uint32_t m_dma_dst[4]{};
uint16_t m_dma_cnt[4]{};
// Timers
uint32_t m_timer_regs[4];
uint16_t m_timer_reload[4];
int m_timer_recalc[4];
uint32_t m_timer_regs[4]{};
uint16_t m_timer_reload[4]{};
int m_timer_recalc[4]{};
emu_timer *m_tmr_timer[4], *m_irq_timer;
emu_timer *m_tmr_timer[4]{}, *m_irq_timer = nullptr;
double m_timer_hz[4];
double m_timer_hz[4]{};
int m_fifo_a_ptr;
int m_fifo_b_ptr;
int m_fifo_a_in;
int m_fifo_b_in;
uint8_t m_fifo_a[20];
uint8_t m_fifo_b[20];
int m_fifo_a_ptr = 0;
int m_fifo_b_ptr = 0;
int m_fifo_a_in = 0;
int m_fifo_b_in = 0;
uint8_t m_fifo_a[20]{};
uint8_t m_fifo_b[20]{};
uint32_t gba_io_r(offs_t offset, uint32_t mem_mask = ~0);

View File

@ -45,49 +45,49 @@
struct s3c240x_lcd_t
{
uint32_t vramaddr_cur;
uint32_t vramaddr_max;
uint32_t offsize;
uint32_t pagewidth_cur;
uint32_t pagewidth_max;
uint32_t bppmode;
uint32_t bswp, hwswp;
uint32_t hozval, lineval;
int vpos, hpos;
uint32_t vramaddr_cur = 0;
uint32_t vramaddr_max = 0;
uint32_t offsize = 0;
uint32_t pagewidth_cur = 0;
uint32_t pagewidth_max = 0;
uint32_t bppmode = 0;
uint32_t bswp = 0, hwswp = 0;
uint32_t hozval = 0, lineval = 0;
int vpos = 0, hpos = 0;
};
struct smc_t
{
int add_latch;
int chip;
int cmd_latch;
int do_read;
int do_write;
int read;
int wp;
int busy;
uint8_t datarx;
uint8_t datatx;
int add_latch = 0;
int chip = 0;
int cmd_latch = 0;
int do_read = 0;
int do_write = 0;
int read = 0;
int wp = 0;
int busy = 0;
uint8_t datarx = 0;
uint8_t datatx = 0;
};
struct i2s_t
{
int l3d;
int l3m;
int l3c;
int l3d = 0;
int l3m = 0;
int l3c = 0;
};
struct s3c240x_iic_t
{
uint8_t data[4];
int data_index;
uint16_t address;
uint8_t data[4]{};
int data_index = 0;
uint16_t address = 0;
};
struct s3c240x_iis_t
{
uint16_t fifo[16/2];
int fifo_index;
uint16_t fifo[16/2]{};
int fifo_index = 0;
};
@ -120,34 +120,34 @@ private:
required_shared_ptr<uint32_t> m_s3c240x_ram;
std::unique_ptr<uint8_t[]> m_eeprom_data;
uint32_t m_s3c240x_lcd_regs[0x400/4];
emu_timer *m_s3c240x_lcd_timer;
emu_timer *m_s3c240x_lcd_timer = nullptr;
s3c240x_lcd_t m_s3c240x_lcd;
uint32_t m_s3c240x_lcd_palette[0x400/4];
uint32_t m_s3c240x_clkpow_regs[0x18/4];
uint32_t m_s3c240x_irq_regs[0x18/4];
emu_timer *m_s3c240x_pwm_timer[5];
uint32_t m_s3c240x_pwm_regs[0x44/4];
emu_timer *m_s3c240x_dma_timer[4];
uint32_t m_s3c240x_dma_regs[0x7c/4];
uint32_t m_s3c240x_lcd_palette[0x400/4]{};
uint32_t m_s3c240x_clkpow_regs[0x18/4]{};
uint32_t m_s3c240x_irq_regs[0x18/4]{};
emu_timer *m_s3c240x_pwm_timer[5]{};
uint32_t m_s3c240x_pwm_regs[0x44/4]{};
emu_timer *m_s3c240x_dma_timer[4]{};
uint32_t m_s3c240x_dma_regs[0x7c/4]{};
smc_t m_smc;
i2s_t m_i2s;
uint32_t m_s3c240x_gpio[0x60/4];
uint32_t m_s3c240x_memcon_regs[0x34/4];
uint32_t m_s3c240x_usb_host_regs[0x5C/4];
uint32_t m_s3c240x_gpio[0x60/4]{};
uint32_t m_s3c240x_memcon_regs[0x34/4]{};
uint32_t m_s3c240x_usb_host_regs[0x5C/4]{};
uint32_t m_s3c240x_uart_0_regs[0x2C/4];
uint32_t m_s3c240x_uart_1_regs[0x2C/4];
uint32_t m_s3c240x_usb_device_regs[0xBC/4];
uint32_t m_s3c240x_watchdog_regs[0x0C/4];
uint32_t m_s3c240x_usb_device_regs[0xBC/4]{};
uint32_t m_s3c240x_watchdog_regs[0x0C/4]{};
s3c240x_iic_t m_s3c240x_iic;
emu_timer *m_s3c240x_iic_timer;
uint32_t m_s3c240x_iic_regs[0x10/4];
emu_timer *m_s3c240x_iic_timer = nullptr;
uint32_t m_s3c240x_iic_regs[0x10/4]{};
s3c240x_iis_t m_s3c240x_iis;
emu_timer *m_s3c240x_iis_timer;
uint32_t m_s3c240x_iis_regs[0x14/4];
uint32_t m_s3c240x_rtc_regs[0x4C/4];
uint32_t m_s3c240x_adc_regs[0x08/4];
uint32_t m_s3c240x_spi_regs[0x18/4];
uint32_t m_s3c240x_mmc_regs[0x40/4];
emu_timer *m_s3c240x_iis_timer = nullptr;
uint32_t m_s3c240x_iis_regs[0x14/4]{};
uint32_t m_s3c240x_rtc_regs[0x4C/4]{};
uint32_t m_s3c240x_adc_regs[0x08/4]{};
uint32_t m_s3c240x_spi_regs[0x18/4]{};
uint32_t m_s3c240x_mmc_regs[0x40/4]{};
bitmap_rgb32 m_bitmap;
uint32_t s3c240x_lcd_r(offs_t offset);
void s3c240x_lcd_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0);

View File

@ -306,18 +306,18 @@ protected:
output_finder<4> m_sel;
output_finder<> m_wheel;
uint8_t m_hd34010_host_access;
uint8_t m_hd34010_host_access = 0;
optional_shared_ptr<uint16_t> m_msp_ram;
uint16_t * m_dsk_ram;
uint16_t * m_dsk_rom;
uint16_t * m_dsk_ram = nullptr;
uint16_t * m_dsk_rom = nullptr;
optional_device<eeprom_parallel_28xx_device> m_dsk_10c;
optional_device<eeprom_parallel_28xx_device> m_dsk_30c;
uint8_t m_dsk_pio_access;
uint8_t m_dsk_pio_access = 0;
uint16_t * m_m68k_sloop_base;
uint16_t * m_m68k_sloop_alt_base;
uint16_t * m_m68k_sloop_base = nullptr;
uint16_t * m_m68k_sloop_alt_base = nullptr;
required_device<timekeeper_device> m_200e;
required_device<eeprom_parallel_28xx_device> m_210e;
@ -331,25 +331,25 @@ protected:
optional_shared_ptr<uint32_t> m_dsp32_ram;
uint16_t * m_gsp_protection;
uint16_t * m_gsp_protection = nullptr;
uint16_t * m_gsp_speedup_addr[2];
offs_t m_gsp_speedup_pc;
uint16_t * m_gsp_speedup_addr[2]{};
offs_t m_gsp_speedup_pc = 0;
uint16_t * m_msp_speedup_addr;
offs_t m_msp_speedup_pc;
uint16_t * m_msp_speedup_addr = nullptr;
offs_t m_msp_speedup_pc = 0;
uint16_t * m_ds3_speedup_addr;
offs_t m_ds3_speedup_pc;
offs_t m_ds3_transfer_pc;
uint16_t * m_ds3_speedup_addr = nullptr;
offs_t m_ds3_speedup_pc = 0;
offs_t m_ds3_transfer_pc = 0;
uint32_t * m_rddsp32_sync[2];
uint32_t * m_rddsp32_sync[2]{};
uint32_t m_gsp_speedup_count[4];
uint32_t m_msp_speedup_count[4];
uint32_t m_adsp_speedup_count[4];
uint32_t m_gsp_speedup_count[4]{};
uint32_t m_msp_speedup_count[4]{};
uint32_t m_adsp_speedup_count[4]{};
uint8_t m_gsp_multisync;
uint8_t m_gsp_multisync = 0;
optional_shared_ptr<uint16_t> m_gsp_vram;
optional_shared_ptr<uint16_t> m_gsp_control_lo;
optional_shared_ptr<uint16_t> m_gsp_control_hi;
@ -362,97 +362,97 @@ protected:
optional_ioport_array<4> m_12badc;
/* machine state */
uint8_t m_irq_state;
uint8_t m_gsp_irq_state;
uint8_t m_msp_irq_state;
uint8_t m_adsp_irq_state;
uint8_t m_ds3sdsp_irq_state;
uint8_t m_duart_irq_state;
uint8_t m_irq_state = 0;
uint8_t m_gsp_irq_state = 0;
uint8_t m_msp_irq_state = 0;
uint8_t m_adsp_irq_state = 0;
uint8_t m_ds3sdsp_irq_state = 0;
uint8_t m_duart_irq_state = 0;
uint8_t m_last_gsp_shiftreg;
uint8_t m_last_gsp_shiftreg = 0;
uint8_t m_m68k_zp1;
uint8_t m_m68k_zp2;
uint8_t m_m68k_adsp_buffer_bank;
uint8_t m_m68k_zp1 = 0;
uint8_t m_m68k_zp2 = 0;
uint8_t m_m68k_adsp_buffer_bank = 0;
uint8_t m_adsp_halt;
uint8_t m_adsp_br;
uint8_t m_adsp_xflag;
uint16_t m_adsp_sim_address;
uint16_t m_adsp_som_address;
uint32_t m_adsp_eprom_base;
uint8_t m_adsp_halt = 0;
uint8_t m_adsp_br = 0;
uint8_t m_adsp_xflag = 0;
uint16_t m_adsp_sim_address = 0;
uint16_t m_adsp_som_address = 0;
uint32_t m_adsp_eprom_base = 0;
required_region_ptr<uint16_t> m_sim_memory;
uint16_t m_som_memory[0x8000/2];
uint16_t * m_adsp_pgm_memory_word;
uint16_t m_som_memory[0x8000/2]{};
uint16_t * m_adsp_pgm_memory_word = 0;
uint16_t * m_ds3_sdata_memory;
uint32_t m_ds3_sdata_memory_size;
uint16_t * m_ds3_sdata_memory = 0;
uint32_t m_ds3_sdata_memory_size = 0;
uint8_t m_ds3_gcmd;
uint8_t m_ds3_gflag;
uint8_t m_ds3_g68irqs;
uint8_t m_ds3_gfirqs;
uint8_t m_ds3_g68flag;
uint8_t m_ds3_send;
uint8_t m_ds3_reset;
uint16_t m_ds3_gdata;
uint16_t m_ds3_g68data;
uint32_t m_ds3_sim_address;
uint8_t m_ds3_gcmd = 0;
uint8_t m_ds3_gflag = 0;
uint8_t m_ds3_g68irqs = 0;
uint8_t m_ds3_gfirqs = 0;
uint8_t m_ds3_g68flag = 0;
uint8_t m_ds3_send = 0;
uint8_t m_ds3_reset = 0;
uint16_t m_ds3_gdata = 0;
uint16_t m_ds3_g68data = 0;
uint32_t m_ds3_sim_address = 0;
uint8_t m_ds3_scmd;
uint8_t m_ds3_sflag;
uint8_t m_ds3_s68irqs;
uint8_t m_ds3_sfirqs;
uint8_t m_ds3_s68flag;
uint8_t m_ds3_sreset;
uint16_t m_ds3_sdata;
uint16_t m_ds3_s68data;
uint32_t m_ds3_sdata_address;
uint16_t m_ds3sdsp_regs[32];
uint16_t m_ds3sdsp_timer_en;
uint16_t m_ds3sdsp_sdata;
uint8_t m_ds3_scmd = 0;
uint8_t m_ds3_sflag = 0;
uint8_t m_ds3_s68irqs = 0;
uint8_t m_ds3_sfirqs = 0;
uint8_t m_ds3_s68flag = 0;
uint8_t m_ds3_sreset = 0;
uint16_t m_ds3_sdata = 0;
uint16_t m_ds3_s68data = 0;
uint32_t m_ds3_sdata_address = 0;
uint16_t m_ds3sdsp_regs[32]{};
uint16_t m_ds3sdsp_timer_en = 0;
uint16_t m_ds3sdsp_sdata = 0;
optional_device<timer_device> m_ds3sdsp_internal_timer;
uint16_t m_ds3xdsp_regs[32];
uint16_t m_ds3xdsp_timer_en;
uint16_t m_ds3xdsp_sdata;
uint16_t m_ds3xdsp_regs[32]{};
uint16_t m_ds3xdsp_timer_en = 0;
uint16_t m_ds3xdsp_sdata = 0;
optional_device<timer_device> m_ds3xdsp_internal_timer;
uint16_t m_adc_control;
uint8_t m_adc12_select;
uint8_t m_adc12_byte;
uint16_t m_adc12_data;
uint16_t m_adc_control = 0;
uint8_t m_adc12_select = 0;
uint8_t m_adc12_byte = 0;
uint16_t m_adc12_data = 0;
uint16_t m_hdc68k_last_wheel;
uint16_t m_hdc68k_last_port1;
uint8_t m_hdc68k_wheel_edge;
uint8_t m_hdc68k_shifter_state;
uint16_t m_hdc68k_last_wheel = 0;
uint16_t m_hdc68k_last_port1 = 0;
uint8_t m_hdc68k_wheel_edge = 0;
uint8_t m_hdc68k_shifter_state = 0;
uint8_t m_st68k_sloop_bank;
offs_t m_st68k_last_alt_sloop_offset;
uint8_t m_st68k_sloop_bank = 0;
offs_t m_st68k_last_alt_sloop_offset = 0;
uint8_t m_sel_select;
uint8_t m_sel1_data;
uint8_t m_sel2_data;
uint8_t m_sel3_data;
uint8_t m_sel4_data;
uint8_t m_sel_select = 0;
uint8_t m_sel1_data = 0;
uint8_t m_sel2_data = 0;
uint8_t m_sel3_data = 0;
uint8_t m_sel4_data = 0;
#define MAX_MSP_SYNC 16
uint32_t * m_dataptr[MAX_MSP_SYNC];
uint32_t m_dataval[MAX_MSP_SYNC];
int m_next_msp_sync;
uint32_t * m_dataptr[MAX_MSP_SYNC]{};
uint32_t m_dataval[MAX_MSP_SYNC]{};
int m_next_msp_sync = 0;
/* video state */
offs_t m_vram_mask;
offs_t m_vram_mask = 0;
uint8_t m_shiftreg_enable;
uint8_t m_shiftreg_enable = 0;
uint32_t m_mask_table[65536 * 4];
uint16_t * m_gsp_shiftreg_source;
uint32_t m_mask_table[65536 * 4]{};
uint16_t * m_gsp_shiftreg_source = 0;
int8_t m_gfx_finescroll;
uint8_t m_gfx_palettebank;
int8_t m_gfx_finescroll = 0;
uint8_t m_gfx_palettebank = 0;
virtual void update_interrupts();
void init_driver();
void init_multisync(int compact_inputs);
@ -485,8 +485,8 @@ protected:
inline void gsp_palette_change(int offset);
uint8_t m_sound_int_state;
uint8_t m_video_int_state;
uint8_t m_sound_int_state = 0;
uint8_t m_video_int_state = 0;
optional_device<palette_device> m_palette;
int get_hblank(screen_device &screen) const { return (screen.hpos() > (screen.width() * 9 / 10)); }
@ -557,18 +557,18 @@ private:
required_shared_ptr<uint16_t> m_sounddsp_ram;
required_region_ptr<uint8_t> m_sound_rom;
uint8_t m_soundflag;
uint8_t m_mainflag;
uint16_t m_sounddata;
uint16_t m_maindata;
uint8_t m_soundflag = 0;
uint8_t m_mainflag = 0;
uint16_t m_sounddata = 0;
uint16_t m_maindata = 0;
uint8_t m_cramen;
uint8_t m_irq68k;
uint8_t m_cramen = 0;
uint8_t m_irq68k = 0;
offs_t m_sound_rom_offs;
offs_t m_sound_rom_offs = 0;
uint16_t m_comram[0x400/2];
uint64_t m_last_bio_cycles;
uint16_t m_comram[0x400/2]{};
uint64_t m_last_bio_cycles = 0;
void update_68k_interrupts();
TIMER_CALLBACK_MEMBER( delayed_68k_w );

View File

@ -127,38 +127,38 @@ private:
static void minidisc_formats(format_registration &fr);
bool m_hector_flag_hr;
bool m_hector_flag_80c;
uint8_t m_hector_color[4];
uint8_t m_hector_disc2_data_r_ready;
uint8_t m_hector_disc2_data_w_ready;
uint8_t m_hector_disc2_data_read;
uint8_t m_hector_disc2_data_write;
bool m_hector_disc2_rnmi;
uint8_t m_state3000;
bool m_write_cassette;
emu_timer *m_cassette_timer;
uint8_t m_ck_signal;
bool m_flag_clk;
double m_pin_value[29][2];
u8 m_au[17];
u8 m_val_mixer;
u8 m_oldstate3000;
u8 m_oldstate1000;
uint8_t m_pot0;
uint8_t m_pot1;
uint8_t m_actions;
uint8_t m_hector_port_a;
uint8_t m_hector_port_b;
uint8_t m_hector_port_c_h;
uint8_t m_hector_port_c_l;
uint8_t m_hector_port_cmd;
bool m_cassette_bit;
bool m_cassette_bit_mem;
uint8_t m_data_k7;
int m_counter_write;
bool m_irq_current_state;
bool m_nmi_current_state;
bool m_hector_flag_hr = 0;
bool m_hector_flag_80c = 0;
uint8_t m_hector_color[4]{};
uint8_t m_hector_disc2_data_r_ready = 0;
uint8_t m_hector_disc2_data_w_ready = 0;
uint8_t m_hector_disc2_data_read = 0;
uint8_t m_hector_disc2_data_write = 0;
bool m_hector_disc2_rnmi = false;
uint8_t m_state3000 = 0;
bool m_write_cassette = false;
emu_timer *m_cassette_timer = nullptr;
uint8_t m_ck_signal = 0;
bool m_flag_clk = false;
double m_pin_value[29][2]{};
u8 m_au[17]{};
u8 m_val_mixer = 0;
u8 m_oldstate3000 = 0;
u8 m_oldstate1000 = 0;
uint8_t m_pot0 = 0;
uint8_t m_pot1 = 0;
uint8_t m_actions = 0;
uint8_t m_hector_port_a = 0;
uint8_t m_hector_port_b = 0;
uint8_t m_hector_port_c_h = 0;
uint8_t m_hector_port_c_l = 0;
uint8_t m_hector_port_cmd = 0;
bool m_cassette_bit = false;
bool m_cassette_bit_mem = false;
uint8_t m_data_k7 = 0;
int m_counter_write = 0;
bool m_irq_current_state = false;
bool m_nmi_current_state = false;
DECLARE_MACHINE_RESET(interact);
DECLARE_MACHINE_START(hec2hrp);

View File

@ -59,22 +59,22 @@ private:
optional_memory_bank m_audiobank;
/* video-related */
tilemap_t *m_bg_tilemap[2][4];
int m_visible_page;
int m_priority;
uint8_t m_reikaids_which;
int m_flipscreen;
uint8_t m_gfx_bank[2]; // pteacher only uses the first one
uint8_t m_blitter_bank;
int m_blitter_param_count;
uint8_t m_blitter_param[4]; /* buffers last 4 writes to 0x8006 */
tilemap_t *m_bg_tilemap[2][4]{};
int m_visible_page = 0;
int m_priority = 0;
uint8_t m_reikaids_which = 0;
int m_flipscreen = 0;
uint8_t m_gfx_bank[2]{}; // pteacher only uses the first one
uint8_t m_blitter_bank = 0;
int m_blitter_param_count = 0;
uint8_t m_blitter_param[4]{}; /* buffers last 4 writes to 0x8006 */
/* misc */
int m_vblank;
int m_keyb;
int m_upd7807_porta;
int m_upd7807_portc;
int m_vblank = 0;
int m_keyb = 0;
int m_upd7807_porta = 0;
int m_upd7807_portc = 0;
/* device */
required_device<cpu_device> m_maincpu;
@ -89,7 +89,7 @@ private:
optional_ioport_array<12> m_keys;
uint8_t m_prot_data;
uint8_t m_prot_data = 0;
uint8_t mrokumei_keyboard_r(offs_t offset);
void mrokumei_keyboard_select_w(uint8_t data);
void mrokumei_sound_bank_w(uint8_t data);

View File

@ -49,10 +49,10 @@ private:
required_memory_bank m_scrollbank;
// video-related
tilemap_t *m_bg_tilemap;
tilemap_t *m_bg_tilemap = nullptr;
// misc
uint8_t m_irq_enable;
uint8_t m_irq_enable = 0;
optional_ioport_array<2> m_dials;
// devices

View File

@ -93,7 +93,7 @@ private:
void main_map(address_map &map);
/* machine state */
emu_timer *m_interrupt_timer;
emu_timer *m_interrupt_timer = nullptr;
/* video state */
required_shared_ptr<u8> m_backgroundram;
@ -104,10 +104,10 @@ private:
required_region_ptr<u8> m_bg_gfx;
required_region_ptr<u8> m_spr_gfx;
required_region_ptr<u8> m_proms;
u32 m_vscroll;
u32 m_hscroll;
bool m_foreground_bank;
bool m_video_off;
u32 m_vscroll = 0;
u32 m_hscroll = 0;
bool m_foreground_bank = false;
bool m_video_off = false;
required_device<cpu_device> m_maincpu;
required_device<cpu_device> m_audiocpu;

View File

@ -115,8 +115,8 @@ private:
uint16_t reellamps_4567_r(offs_t offset, uint16_t mem_mask = ~0);
void reellamps_4567_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0);
uint16_t m_reellamps_0123;
uint16_t m_reellamps_5678;
uint16_t m_reellamps_0123 = 0;
uint16_t m_reellamps_5678 = 0;
void mux_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0);
uint16_t mux_r(offs_t offset, uint16_t mem_mask = ~0);
@ -134,14 +134,14 @@ private:
output_finder<32> m_reellamp_out;
optional_device_array<stepper_device, 8> m_reel;
int m_lamp_strobe;
int m_mpxclk;
uint16_t m_muxram[0x100];
uint16_t m_optic_pattern;
int m_chop;
uint8_t m_a0_data_out;
uint8_t m_a1_data_out;
uint8_t m_a2_data_out;
int m_lamp_strobe = 0;
int m_mpxclk = 0;
uint16_t m_muxram[0x100]{};
uint16_t m_optic_pattern = 0;
int m_chop = 0;
uint8_t m_a0_data_out = 0;
uint8_t m_a1_data_out = 0;
uint8_t m_a2_data_out = 0;
};
@ -182,14 +182,14 @@ private:
required_memory_bank m_rombank;
required_ioport_array<2> m_touch_axes;
uint8_t m_palette_val[16][3];
int m_pal_addr;
int m_pal_idx;
int m_touch_state;
emu_timer *m_touch_timer;
int m_touch_data_count;
int m_touch_data[3];
int m_touch_shift_cnt;
uint8_t m_palette_val[16][3]{};
int m_pal_addr = 0;
int m_pal_idx = 0;
int m_touch_state = 0;
emu_timer *m_touch_timer = nullptr;
int m_touch_data_count = 0;
int m_touch_data[3]{};
int m_touch_shift_cnt = 0;
};
#endif // MAME_INCLUDES_JPMSYS5_H

View File

@ -97,12 +97,12 @@ private:
std::unique_ptr<u8[]> m_ram;
std::unique_ptr<u8[]> m_vram; // video ram
std::unique_ptr<u8[]> m_dummy; // black hole for write to rom
int m_centronics_busy;
bool m_is_motor_off = 0;
int m_centronics_busy = 0;
bool m_is_motor_off = false;
u8 m_fdc_rq = 0U;
u8 m_system_port = 0U;
u16 m_mc6845_video_address = 0U;
floppy_image_device *m_floppy;
floppy_image_device *m_floppy = nullptr;
required_device<palette_device> m_palette;
required_device<screen_device> m_screen;

View File

@ -121,7 +121,7 @@ public:
K055673_CB_MEMBER(salmndr2_sprite_callback);
K055673_CB_MEMBER(le2_sprite_callback);
struct GX_OBJ { int order, offs, code, color; };
struct GX_OBJ { int order = 0, offs = 0, code = 0, color = 0; };
void common_init();
uint32_t k_6bpp_rom_long_r(offs_t offset, uint32_t mem_mask = ~0);
@ -225,55 +225,55 @@ protected:
optional_ioport m_an0, m_an1, m_light0_x, m_light0_y, m_light1_x, m_light1_y, m_eepromout;
uint8_t m_sound_ctrl;
uint8_t m_sound_intck;
uint32_t m_fantjour_dma[8];
int m_konamigx_current_frame;
int m_gx_objdma, m_gx_primode;
emu_timer *m_dmadelay_timer;
emu_timer *m_boothack_timer;
int m_gx_rdport1_3, m_gx_syncen;
int m_gx_cfgport;
int m_suspension_active, m_resume_trigger;
int m_last_prot_op, m_last_prot_clk;
u16 m_last_prot_param;
uint8_t m_prev_pixel_clock;
uint8_t m_sound_ctrl = 0;
uint8_t m_sound_intck = 0;
uint32_t m_fantjour_dma[8]{};
int m_konamigx_current_frame = 0;
int m_gx_objdma = 0, m_gx_primode = 0;
emu_timer *m_dmadelay_timer = nullptr;
emu_timer *m_boothack_timer = nullptr;
int m_gx_rdport1_3 = 0, m_gx_syncen = 0;
int m_gx_cfgport = 0;
int m_suspension_active = 0, m_resume_trigger = 0;
int m_last_prot_op = 0, m_last_prot_clk = 0;
u16 m_last_prot_param = 0;
uint8_t m_prev_pixel_clock = 0;
uint8_t m_esc_program[4096];
uint8_t m_esc_program[4096]{};
esc_cb m_esc_cb;
uint16_t m_prot_data[0x20];
uint16_t m_prot_data[0x20]{};
uint16_t *m_gx_spriteram;
uint16_t *m_gx_spriteram = nullptr;
std::unique_ptr<uint16_t[]> m_gx_spriteram_alloc;
// mirrored K054338 settings
int *m_K054338_shdRGB;
int *m_K054338_shdRGB = nullptr;
// 1st-Tier GX/MW Variables
// frequently used registers
int m_k053247_vrcbk[4];
int m_k053247_coreg, m_k053247_coregshift, m_k053247_opset;
int m_opri, m_oinprion;
int m_vcblk[6], m_ocblk;
int m_vinmix, m_vmixon, m_osinmix, m_osmixon;
uint8_t m_gx_wrport1_0, m_gx_wrport1_1;
uint16_t m_gx_wrport2;
int m_k053247_vrcbk[4]{};
int m_k053247_coreg = 0, m_k053247_coregshift = 0, m_k053247_opset = 0;
int m_opri = 0, m_oinprion = 0;
int m_vcblk[6]{}, m_ocblk = 0;
int m_vinmix = 0, m_vmixon = 0, m_osinmix = 0, m_osmixon = 0;
uint8_t m_gx_wrport1_0 = 0, m_gx_wrport1_1 = 0;
uint16_t m_gx_wrport2 = 0;
// 2nd-Tier GX/MW Graphics Variables
uint8_t *m_gx_objzbuf;
uint8_t *m_gx_objzbuf = nullptr;
std::unique_ptr<uint8_t[]> m_gx_shdzbuf;
int m_layer_colorbase[4];
int32_t m_gx_tilebanks[8], m_gx_oldbanks[8];
int m_gx_tilemode, m_gx_rozenable, m_psac_colorbase, m_last_psac_colorbase;
int m_gx_specialrozenable; // type 1 roz, with voxel height-map, rendered from 2 source tilemaps (which include height data) to temp bitmap for further processing
int m_gx_rushingheroes_hack;
int m_layer_colorbase[4]{};
int32_t m_gx_tilebanks[8]{}, m_gx_oldbanks[8]{};
int m_gx_tilemode = 0, m_gx_rozenable = 0, m_psac_colorbase = 0, m_last_psac_colorbase = 0;
int m_gx_specialrozenable = 0; // type 1 roz, with voxel height-map, rendered from 2 source tilemaps (which include height data) to temp bitmap for further processing
int m_gx_rushingheroes_hack = 0;
tilemap_t *m_gx_psac_tilemap, *m_gx_psac_tilemap2;
tilemap_t *m_gx_psac_tilemap = nullptr, *m_gx_psac_tilemap2 = nullptr;
std::unique_ptr<bitmap_ind16> m_type3_roz_temp_bitmap;
tilemap_t *m_gx_psac_tilemap_alt;
int m_konamigx_has_dual_screen;
int m_konamigx_palformat;
tilemap_t *m_gx_psac_tilemap_alt = nullptr;
int m_konamigx_has_dual_screen = 0;
int m_konamigx_palformat = 0;
std::unique_ptr<bitmap_rgb32> m_dualscreen_left_tempbitmap;
std::unique_ptr<bitmap_rgb32> m_dualscreen_right_tempbitmap;
@ -299,10 +299,10 @@ protected:
std::unique_ptr<GX_OBJ[]> m_gx_objpool;
u8 m_type3_psac2_bank;
u8 m_type3_spriteram_bank;
u8 m_type3_psac2_bank = 0;
u8 m_type3_spriteram_bank = 0;
//int m_konamigx_type3_psac2_actual_last_bank = 0;
int m_use_68020_post_clock_hack;
int m_use_68020_post_clock_hack = 0;
output_finder<> m_lamp;
};

View File

@ -129,28 +129,28 @@ private:
optional_ioport m_io_dsw;
std::unique_ptr<u16[]> m_protection_ram;
emu_timer *m_scanline_timer;
const u8 *m_protection_code;
const u8 *m_protection_crc;
u32 m_raster_irq_position;
tilemap_t *m_fg_tilemap;
tilemap_t *m_bg_tilemap;
tilemap_t *m_bg_tilemap_large;
s32 m_scrollx[2];
s32 m_scrolly[2];
s32 m_video_off;
emu_timer *m_scanline_timer = nullptr;
const u8 *m_protection_code = nullptr;
const u8 *m_protection_crc = nullptr;
u32 m_raster_irq_position = 0;
tilemap_t *m_fg_tilemap = nullptr;
tilemap_t *m_bg_tilemap = nullptr;
tilemap_t *m_bg_tilemap_large = nullptr;
s32 m_scrollx[2]{};
s32 m_scrolly[2]{};
s32 m_video_off = 0;
int m_fg_source;
int m_bg_source;
int m_fg_source = 0;
int m_bg_source = 0;
optional_ioport m_m81_b_b_j3;
// majtitle specific
int m_m82_rowscroll;
u16 m_m82_tmcontrol;
int m_m82_rowscroll = 0;
u16 m_m82_tmcontrol = 0;
// m72_i8751 specific
u8 m_mcu_sample_latch;
u32 m_mcu_sample_addr;
u8 m_mcu_sample_latch = 0;
u32 m_mcu_sample_addr = 0;
// common
template<unsigned N> u16 palette_r(offs_t offset);

View File

@ -47,8 +47,8 @@ private:
output_finder<> m_self_test;
/* misc */
uint8_t m_lut_gun1[0x100];
uint8_t m_lut_gun2[0x100];
uint8_t m_lut_gun1[0x100]{};
uint8_t m_lut_gun2[0x100]{};
};
/*----------- defined in audio/m79amb.c -----------*/

View File

@ -42,12 +42,12 @@ private:
required_ioport m_system;
/* video-related */
tilemap_t *m_bg_tilemap;
tilemap_t *m_fg_tilemap;
uint8_t m_palette_bank;
uint8_t m_column_scroll;
uint8_t m_flipscreen_x;
uint8_t m_flipscreen_y;
tilemap_t *m_bg_tilemap = nullptr;
tilemap_t *m_fg_tilemap = nullptr;
uint8_t m_palette_bank = 0;
uint8_t m_column_scroll = 0;
uint8_t m_flipscreen_x = 0;
uint8_t m_flipscreen_y = 0;
/* devices */
required_device<cpu_device> m_maincpu;
@ -57,7 +57,7 @@ private:
required_device<ls259_device> m_outlatch;
required_device<watchdog_timer_device> m_watchdog;
bool m_irq_mask;
bool m_irq_mask = false;
DECLARE_WRITE_LINE_MEMBER(irq_mask_w);
DECLARE_WRITE_LINE_MEMBER(nmi_mask_w);
void marineb_videoram_w(offs_t offset, uint8_t data);

View File

@ -77,21 +77,21 @@ private:
output_finder<256> m_lamps;
output_finder<8> m_triacs;
uint8_t m_lamppos;
int m_lamp_strobe;
int m_old_lamp_strobe;
int m_lamp_strobe2;
int m_old_lamp_strobe2;
int m_RAMEN;
int m_ALARMEN;
int m_PSUrelay;
bool m_Vmm;
int m_WDOG;
int m_NMIENABLE;
int m_meter;
uint8_t m_lamppos = 0;
int m_lamp_strobe = 0;
int m_old_lamp_strobe = 0;
int m_lamp_strobe2 = 0;
int m_old_lamp_strobe2 = 0;
int m_RAMEN = 0;
int m_ALARMEN = 0;
int m_PSUrelay = 0;
bool m_Vmm = false;
int m_WDOG = 0;
int m_NMIENABLE = 0;
int m_meter = 0;
TIMER_DEVICE_CALLBACK_MEMBER( maygay1b_nmitimer_callback );
uint8_t m_Lamps[256];
int m_optic_pattern;
uint8_t m_Lamps[256]{};
int m_optic_pattern = 0;
template <unsigned N> DECLARE_WRITE_LINE_MEMBER(reel_optic_cb) { if (state) m_optic_pattern |= (1 << N); else m_optic_pattern &= ~(1 << N); }
void scanlines_w(uint8_t data);
void scanlines_2_w(uint8_t data);

View File

@ -115,38 +115,38 @@ private:
optional_ioport m_io_dsw2;
// configuration
u16 m_ip_select_values[7]; // System B and C
int m_hardware_type_z; // System Z
int m_layers_order[16];
u8 m_ignore_oki_status;
u16 m_ip_select_values[7]{}; // System B and C
int m_hardware_type_z = 0; // System Z
int m_layers_order[16]{};
u8 m_ignore_oki_status = 0;
// all
bitmap_ind16 m_sprite_buffer_bitmap;
u16 m_screen_flag;
u16 m_screen_flag = 0;
std::unique_ptr<u16[]> m_buffer_objectram;
std::unique_ptr<u16[]> m_buffer2_objectram;
std::unique_ptr<u16[]> m_buffer_spriteram16;
std::unique_ptr<u16[]> m_buffer2_spriteram16;
// all but System Z
u16 m_active_layers;
u16 m_sprite_flag;
u16 m_active_layers = 0;
u16 m_sprite_flag = 0;
// System B and C
u16 m_ip_latched;
u16 m_ip_latched = 0;
// System C
u16 m_sprite_bank;
u16 m_sprite_bank = 0;
// System A only
int m_mcu_hs;
u16 m_mcu_hs_ram[0x10];
int m_mcu_hs = 0;
u16 m_mcu_hs_ram[0x10]{};
// peekaboo
u16 m_protection_val;
u16 m_protection_val = 0;
// soldam
u16 *m_spriteram;
u16 *m_spriteram = nullptr;
DECLARE_WRITE_LINE_MEMBER(sound_irq);
u16 ip_select_r();

View File

@ -24,18 +24,18 @@ struct mz_poly_extra_data
{
const void * palbase;
const void * texbase;
uint16_t solidcolor;
uint16_t voffset;
int16_t zoffset;
uint16_t transcolor;
uint16_t texwidth;
uint16_t color;
uint32_t alpha;
uint32_t ctrl_word;
bool blend_enable;
bool depth_test_enable;
bool depth_write_enable;
uint32_t blend;
uint16_t solidcolor = 0;
uint16_t voffset = 0;
int16_t zoffset = 0;
uint16_t transcolor = 0;
uint16_t texwidth = 0;
uint16_t color = 0;
uint32_t alpha = 0;
uint32_t ctrl_word = 0;
bool blend_enable = false;
bool depth_test_enable = false;
bool depth_write_enable = false;
uint32_t blend = 0;
uint8_t (*get_texel)(const void *, int, int, int);
};
@ -152,20 +152,20 @@ protected:
optional_ioport m_io_keypad;
output_finder<7> m_digits;
emu_timer * m_display_irq_off_timer;
uint8_t m_crusnexo_leds_select;
uint32_t m_disk_asic_jr[0x10];
emu_timer * m_display_irq_off_timer = nullptr;
uint8_t m_crusnexo_leds_select = 0;
uint32_t m_disk_asic_jr[0x10]{};
uint8_t m_cmos_protected;
uint8_t m_cmos_protected = 0;
emu_timer * m_timer[2];
emu_timer * m_timer[2]{};
private:
uint32_t m_gun_control;
uint8_t m_gun_irq_state;
emu_timer * m_gun_timer[2];
int32_t m_gun_x[2], m_gun_y[2];
uint8_t m_keypad_select;
uint32_t m_gun_control = 0;
uint8_t m_gun_irq_state = 0;
emu_timer * m_gun_timer[2]{};
int32_t m_gun_x[2]{}, m_gun_y[2]{};
uint8_t m_keypad_select = 0;
void exit_handler();
void zeus_pointer_w(uint32_t which, uint32_t data, bool logit);
@ -189,22 +189,22 @@ private:
void waveram_plot_check_depth_nowrite(int y, int x, uint16_t color, uint16_t depth);
std::unique_ptr<midzeus_renderer> m_poly;
uint8_t m_log_fifo;
uint8_t m_log_fifo = 0;
uint32_t m_zeus_fifo[20];
uint8_t m_zeus_fifo_words;
int16_t m_zeus_matrix[3][3];
int32_t m_zeus_point[3];
int16_t m_zeus_light[3];
void * m_zeus_renderbase;
uint32_t m_zeus_palbase;
uint32_t m_zeus_unkbase;
int m_zeus_enable_logging;
uint32_t m_zeus_objdata;
uint32_t m_zeus_fifo[20]{};
uint8_t m_zeus_fifo_words = 0;
int16_t m_zeus_matrix[3][3]{};
int32_t m_zeus_point[3]{};
int16_t m_zeus_light[3]{};
void * m_zeus_renderbase = 0;
uint32_t m_zeus_palbase = 0;
uint32_t m_zeus_unkbase = 0;
int m_zeus_enable_logging = 0;
uint32_t m_zeus_objdata = 0;
rectangle m_zeus_cliprect;
std::unique_ptr<uint32_t[]> m_waveram[2];
int m_yoffs;
int m_texel_width;
int m_is_mk4b;
int m_yoffs = 0;
int m_texel_width = 0;
int m_is_mk4b = 0;
};

View File

@ -48,12 +48,12 @@ private:
required_ioport_array<12> m_row;
int m_adpcm_pos;
int m_adpcm_end;
int m_keyb;
bool m_nmi_enable;
bool m_display_enable;
tilemap_t *m_bg_tilemap;
int m_adpcm_pos = 0;
int m_adpcm_end = 0;
int m_keyb = 0;
bool m_nmi_enable = false;
bool m_display_enable = false;
tilemap_t *m_bg_tilemap = nullptr;
void keyboard_select_lo_w(uint8_t data);
void keyboard_select_hi_w(uint8_t data);

View File

@ -50,16 +50,16 @@ private:
required_ioport m_io_fake;
/* video-related */
u8 m_fg_scrollx;
u8 m_fg_scrolly;
u8 m_fg_select;
u8 m_text_scrolly;
u8 m_text_mode;
u8 m_bg_select;
u8 m_bg_priority;
u8 m_bg_mask;
u8 m_fg_mask;
u8 m_flipscreen;
u8 m_fg_scrollx = 0;
u8 m_fg_scrolly = 0;
u8 m_fg_select = 0;
u8 m_text_scrolly = 0;
u8 m_text_mode = 0;
u8 m_bg_select = 0;
u8 m_bg_priority = 0;
u8 m_bg_mask = 0;
u8 m_fg_mask = 0;
u8 m_flipscreen = 0;
void bg_read_bank_w(u8 data);
void fg_scrollx_w(u8 data);
void fg_scrolly_w(u8 data);

View File

@ -73,9 +73,9 @@ private:
DECLARE_WRITE_LINE_MEMBER( s100_nmi_w );
// memory state
uint32_t m_addr;
uint8_t m_task;
uint8_t m_mask;
uint32_t m_addr = 0;
uint8_t m_task = 0;
uint8_t m_mask = 0;
// interrupt state
int m_nmi;

View File

@ -330,21 +330,21 @@ protected:
private:
/* PSG */
int m_psg_b;
int m_psg_b = 0;
/* mouse */
uint16_t m_mouse[2];
int m_mouse_stat[2];
uint16_t m_mouse[2]{};
int m_mouse_stat[2]{};
/* kanji */
int m_kanji_latch;
int m_kanji_latch = 0;
/* memory */
msx_internal_slot_interface m_empty_slot;
msx_internal_slot_interface *m_all_slots[4][4][4];
msx_internal_slot_interface *m_current_page[4];
bool m_slot_expanded[4];
uint8_t m_primary_slot;
uint8_t m_secondary_slot[4];
int m_port_c_old;
int m_keylatch;
msx_internal_slot_interface *m_all_slots[4][4][4]{};
msx_internal_slot_interface *m_current_page[4]{};
bool m_slot_expanded[4]{};
uint8_t m_primary_slot = 0;
uint8_t m_secondary_slot[4]{};
int m_port_c_old = 0;
int m_keylatch = 0;
};
@ -509,7 +509,7 @@ private:
required_device<rp5c01_device> m_rtc;
/* rtc */
int m_rtc_latch;
int m_rtc_latch = 0;
};

View File

@ -53,9 +53,9 @@ private:
required_ioport m_dsw1;
// video state
tilemap_t *m_fg_tilemap;
tilemap_t *m_bg_tilemap;
emu_timer *m_interrupt_timer;
tilemap_t *m_fg_tilemap = nullptr;
tilemap_t *m_bg_tilemap = nullptr;
emu_timer *m_interrupt_timer = nullptr;
required_shared_ptr<uint8_t> m_bg_videoram;
required_shared_ptr<uint8_t> m_fg_videoram;
required_shared_ptr<uint8_t> m_spriteram;

View File

@ -63,11 +63,11 @@ private:
optional_ioport m_brake;
optional_ioport m_wheel;
emu_timer *m_raster_interrupt_timer;
emu_timer *m_vblank_interrupt_timer;
emu_timer *m_network_interrupt_timer;
uint8_t m_mcu_port6;
uint32_t m_sprbank;
emu_timer *m_raster_interrupt_timer = nullptr;
emu_timer *m_vblank_interrupt_timer = nullptr;
emu_timer *m_network_interrupt_timer = nullptr;
uint8_t m_mcu_port6 = 0;
uint32_t m_sprbank = 0;
uint32_t unk1_r();
uint8_t network_r(offs_t offset);

View File

@ -72,7 +72,7 @@ protected:
virtual void video_start() override;
private:
int m_gametype;
int m_gametype = 0;
enum
{
/* Namco NB1 */
@ -112,12 +112,12 @@ private:
optional_shared_ptr<u32> m_rozbank32;
required_shared_ptr<u16> m_namconb_shareram;
u8 m_vbl_irq_level;
u8 m_pos_irq_level;
u8 m_unk_irq_level;
u16 m_count;
u8 m_port6;
u32 m_tilemap_tile_bank[4];
u8 m_vbl_irq_level = 0;
u8 m_pos_irq_level = 0;
u8 m_unk_irq_level = 0;
u16 m_count = 0;
u8 m_port6 = 0;
u32 m_tilemap_tile_bank[4]{};
std::unique_ptr<u32[]> m_spritebank32_delayed;
bool m_update_to_line_before_posirq;

View File

@ -173,8 +173,8 @@ enum
NAMCOS2_KYUUKAI_DOUCHUUKI,
};
int m_gametype;
bool m_update_to_line_before_posirq;
int m_gametype = 0;
bool m_update_to_line_before_posirq = false;
required_device<cpu_device> m_maincpu;
required_device<cpu_device> m_slave;
@ -234,9 +234,9 @@ enum
required_shared_ptr<uint8_t> m_dpram; /* 2Kx8 */
optional_shared_ptr<uint16_t> m_spriteram;
uint16_t m_gfx_ctrl;
unsigned m_finallap_prot_count;
int m_sendval;
uint16_t m_gfx_ctrl = 0;
unsigned m_finallap_prot_count = 0;
int m_sendval = 0;
optional_device<namco_c45_road_device> m_c45_road;
optional_device<namcos2_sprite_device> m_ns2sprite;

View File

@ -153,12 +153,12 @@ protected:
virtual void video_start() override;
virtual void video_reset() override;
const pen_t *m_bg_pen;
uint8_t m_vblank_level;
uint8_t m_raster_level;
const pen_t *m_bg_pen = nullptr;
uint8_t m_vblank_level = 0;
uint8_t m_raster_level = 0;
int m_use_cart_vectors;
int m_use_cart_audio;
int m_use_cart_vectors = 0;
int m_use_cart_audio = 0;
void set_slot_idx(int slot);
@ -168,11 +168,11 @@ protected:
void init_ym();
void init_sprites();
// temporary helper to restore memory banking while bankswitch is handled in the driver...
uint32_t m_bank_base;
uint32_t m_bank_base = 0;
optional_device_array<neogeo_cart_slot_device, 6> m_slots;
int m_curr_slot;
int m_curr_slot = 0;
private:
void update_interrupts();
@ -190,16 +190,16 @@ private:
void set_pens();
// internal state
bool m_recurse;
bool m_recurse = false;
emu_timer *m_display_position_interrupt_timer;
emu_timer *m_display_position_vblank_timer;
emu_timer *m_vblank_interrupt_timer;
uint32_t m_display_counter;
uint8_t m_vblank_interrupt_pending;
uint8_t m_display_position_interrupt_pending;
uint8_t m_irq3_pending;
uint8_t m_display_position_interrupt_control;
emu_timer *m_display_position_interrupt_timer = nullptr;
emu_timer *m_display_position_vblank_timer = nullptr;
emu_timer *m_vblank_interrupt_timer = nullptr;
uint32_t m_display_counter = 0;
uint8_t m_vblank_interrupt_pending = 0;
uint8_t m_display_position_interrupt_pending = 0;
uint8_t m_irq3_pending = 0;
uint8_t m_display_position_interrupt_control = 0;
uint16_t get_video_control();
@ -207,9 +207,9 @@ private:
// color/palette related
std::vector<uint16_t> m_paletteram;
uint8_t m_palette_lookup[32][4];
int m_screen_shadow;
int m_palette_bank;
uint8_t m_palette_lookup[32][4]{};
int m_screen_shadow = 0;
int m_palette_bank = 0;
};
@ -248,7 +248,7 @@ private:
required_device<upd4990a_device> m_upd4990a;
required_ioport m_dsw;
uint8_t m_save_ram_unlocked;
uint8_t m_save_ram_unlocked = 0;
};

View File

@ -75,15 +75,15 @@ private:
required_shared_ptr<uint8_t> m_hvc;
// input
uint8_t m_gear;
uint8_t m_track;
int32_t m_steering_buf;
int32_t m_steering_val;
uint8_t m_crash_en;
uint8_t m_crash_data;
uint8_t m_crash_data_en; // IC D8
uint8_t m_ac_line;
int32_t m_last_steering_val;
uint8_t m_gear = 0;
uint8_t m_track = 0;
int32_t m_steering_buf = 0;
int32_t m_steering_val = 0;
uint8_t m_crash_en = 0;
uint8_t m_crash_data = 0;
uint8_t m_crash_data_en = 0; // IC D8
uint8_t m_ac_line = 0;
int32_t m_last_steering_val = 0;
required_ioport m_steer, m_gears, m_in0;
required_ioport_array<3> m_dsw;

View File

@ -57,20 +57,20 @@ protected:
required_memory_bank m_mainbank;
// video-related
tilemap_t *m_tilemap;
tilemap_t *m_tilemap = nullptr;
bitmap_ind16 m_tmpbitmap;
uint8_t m_gfxreg;
uint8_t m_flipscreen;
uint8_t m_flipscreen_old;
int16_t m_scrollx;
int16_t m_scrolly;
uint8_t m_screen_refresh;
uint8_t m_gfxreg = 0;
uint8_t m_flipscreen = 0;
uint8_t m_flipscreen_old = 0;
int16_t m_scrollx = 0;
int16_t m_scrolly = 0;
uint8_t m_screen_refresh = 0;
// misc
uint8_t m_port_select;
uint8_t m_adpcm_reset;
int m_adpcm_data;
uint8_t m_vclk_left;
uint8_t m_port_select = 0;
uint8_t m_adpcm_reset = 0;
int m_adpcm_data = 0;
uint8_t m_vclk_left = 0;
// devices
required_device<cpu_device> m_maincpu;

View File

@ -88,24 +88,24 @@ protected:
static void orion_floppy_formats(format_registration &fr);
void machine_start() override;
uint8_t m_orion128_video_mode;
uint8_t m_orion128_video_page;
uint8_t m_orion128_video_width;
uint8_t m_video_mode_mask;
uint8_t m_orionpro_pseudo_color;
uint8_t m_romdisk_lsb;
uint8_t m_romdisk_msb;
uint8_t m_orion128_memory_page;
uint8_t m_orionz80_memory_page;
uint8_t m_orionz80_dispatcher;
uint8_t m_speaker_data;
uint8_t m_orionpro_ram0_segment;
uint8_t m_orionpro_ram1_segment;
uint8_t m_orionpro_ram2_segment;
uint8_t m_orionpro_page;
uint8_t m_orionpro_128_page;
uint8_t m_orionpro_rom2_segment;
uint8_t m_orionpro_dispatcher;
uint8_t m_orion128_video_mode = 0;
uint8_t m_orion128_video_page = 0;
uint8_t m_orion128_video_width = 0;
uint8_t m_video_mode_mask = 0;
uint8_t m_orionpro_pseudo_color = 0;
uint8_t m_romdisk_lsb = 0;
uint8_t m_romdisk_msb = 0;
uint8_t m_orion128_memory_page = 0;
uint8_t m_orionz80_memory_page = 0;
uint8_t m_orionz80_dispatcher = 0;
uint8_t m_speaker_data = 0;
uint8_t m_orionpro_ram0_segment = 0;
uint8_t m_orionpro_ram1_segment = 0;
uint8_t m_orionpro_ram2_segment = 0;
uint8_t m_orionpro_page = 0;
uint8_t m_orionpro_128_page = 0;
uint8_t m_orionpro_rom2_segment = 0;
uint8_t m_orionpro_dispatcher = 0;
required_device<fd1793_device> m_fdc;

View File

@ -68,8 +68,8 @@ protected:
void osi600_mem(address_map &map);
uint8_t m_cass_data[4]{};
bool m_cassbit = 0;
bool m_cassold = 0;
bool m_cassbit = false;
bool m_cassold = false;
required_device<cpu_device> m_maincpu;
required_device<acia6850_device> m_acia;
required_device<cassette_image_device> m_cass;

View File

@ -54,7 +54,7 @@ private:
required_ioport_array<10> m_keys;
required_ioport m_mode;
uint8_t m_reg[0x100];
uint8_t m_reg[0x100]{};
static const char *const s_def[5];
static const char *const s_shift[5];

View File

@ -47,7 +47,7 @@ private:
required_device<ram_device> m_ram;
required_ioport_array<12> m_keys;
uint8_t m_reg[0x1000];
uint8_t m_reg[0x1000]{};
static const char* const s_def[5];
static const char* const s_shift[5];

View File

@ -156,20 +156,20 @@ public:
int m_nmi_enable;
// keyboard state
uint8_t m_kbd;
uint8_t m_kbd = 0;
int m_kb_bits;
int m_kbclk;
int m_kbdata;
// mouse state
uint8_t m_mouse_x_old;
uint8_t m_mouse_y_old;
uint8_t m_mouse_x;
uint8_t m_mouse_y;
uint8_t m_mouse_x_old = 0;
uint8_t m_mouse_y_old = 0;
uint8_t m_mouse_x = 0;
uint8_t m_mouse_y = 0;
// DMA state
uint8_t m_dma_page[4];
int m_dma_channel;
uint8_t m_dma_page[4]{};
int m_dma_channel = 0;
int m_dreq0;
// floppy state
@ -182,12 +182,12 @@ public:
// printer state
int m_ack_int_enable;
int m_centronics_ack;
int m_centronics_busy;
int m_centronics_perror;
int m_centronics_select;
int m_centronics_fault;
uint8_t m_printer_data;
uint8_t m_printer_control;
int m_centronics_busy = 0;
int m_centronics_perror = 0;
int m_centronics_select = 0;
int m_centronics_fault = 0;
uint8_t m_printer_data = 0;
uint8_t m_printer_control = 0;
// sound state
int m_speaker_drive;

View File

@ -57,13 +57,13 @@ private:
u8 fdc_ctrl_r(offs_t offset);
void fdc_ctrl_w(offs_t offset, u8 data);
u8 m_romdrv_bank_reg;
u8 m_bram_banks;
u8 m_bram_bank_reg;
u8 m_dict_bank_reg;
u8 m_romdrv_bank_reg = 0;
u8 m_bram_banks = 0;
u8 m_bram_bank_reg = 0;
u8 m_dict_bank_reg = 0;
u8 m_floppy_mode;
u8 m_fdc_ctrl;
u8 m_floppy_mode = 0;
u8 m_fdc_ctrl = 0;
};
class pc98ha_state : public pc98lt_state
@ -98,7 +98,7 @@ private:
void ems_bank_w(offs_t offset, u8 data);
u8 memcard_status_1_r(offs_t offset);
u8 memcard_status_2_r(offs_t offset);
u8 m_ext_view_sel;
u8 m_ext_view_sel = 0;
};
#endif // MAME_INCLUDES_PC9801_EPSON_H

View File

@ -66,9 +66,9 @@ private:
required_device<pce_control_port_device> m_port_ctrl;
required_ioport m_a_card;
u8 m_io_port_options;
u8 m_sys3_card;
u8 m_acard;
u8 m_io_port_options = 0;
u8 m_sys3_card = 0;
u8 m_acard = 0;
void controller_w(u8 data);
u8 controller_r();
void cd_intf_w(offs_t offset, u8 data);

View File

@ -127,30 +127,30 @@ private:
required_memory_region m_region_rom;
required_ioport m_io_extra;
unsigned long m_interrupt_counter;
int m_banks[4];
int m_4_bit_port;
int m_fdc_int_code;
int m_system_status;
char *m_mem_ptr[4];
unsigned char m_keyboard_data_shift;
int m_keyboard_parity_table[256];
int m_keyboard_bits;
int m_keyboard_bits_output;
int m_keyboard_state;
int m_keyboard_previous_state;
unsigned char m_rtc_seconds;
unsigned char m_rtc_minutes;
unsigned char m_rtc_hours;
unsigned char m_rtc_days_max;
unsigned char m_rtc_days;
unsigned char m_rtc_months;
unsigned char m_rtc_years;
unsigned char m_rtc_control;
unsigned char m_rtc_256ths_seconds;
int m_previous_fdc_int_state;
int m_colour_palette[16];
int m_video_control;
unsigned long m_interrupt_counter = 0;
int m_banks[4]{};
int m_4_bit_port = 0;
int m_fdc_int_code = 0;
int m_system_status = 0;
char *m_mem_ptr[4]{};
unsigned char m_keyboard_data_shift = 0;
int m_keyboard_parity_table[256]{};
int m_keyboard_bits = 0;
int m_keyboard_bits_output = 0;
int m_keyboard_state = 0;
int m_keyboard_previous_state = 0;
unsigned char m_rtc_seconds = 0;
unsigned char m_rtc_minutes = 0;
unsigned char m_rtc_hours = 0;
unsigned char m_rtc_days_max = 0;
unsigned char m_rtc_days = 0;
unsigned char m_rtc_months = 0;
unsigned char m_rtc_years = 0;
unsigned char m_rtc_control = 0;
unsigned char m_rtc_256ths_seconds = 0;
int m_previous_fdc_int_state = 0;
int m_colour_palette[16]{};
int m_video_control = 0;
};
#endif // MAME_INCLUDES_PCW16_H

View File

@ -83,17 +83,17 @@ private:
void pk8020_mem(address_map &map);
void devices_map(address_map &map);
uint8_t m_bank_select;
uint8_t m_color;
uint8_t m_video_page;
uint8_t m_wide;
uint8_t m_font;
uint8_t m_attr;
uint8_t m_text_attr;
uint8_t m_takt;
uint8_t m_video_page_access;
uint8_t m_sound_gate;
uint8_t m_sound_level;
uint8_t m_bank_select = 0;
uint8_t m_color = 0;
uint8_t m_video_page = 0;
uint8_t m_wide = 0;
uint8_t m_font = 0;
uint8_t m_attr = 0;
uint8_t m_text_attr = 0;
uint8_t m_takt = 0;
uint8_t m_video_page_access = 0;
uint8_t m_sound_gate = 0;
uint8_t m_sound_level = 0;
required_device<cpu_device> m_maincpu;
required_device<pls100_device> m_decplm;

View File

@ -49,12 +49,12 @@ private:
required_memory_bank m_gfxbank;
required_memory_bank_array<4> m_ymf_bank;
uint16_t m_gfx_max_bank;
uint8_t m_ymf_max_bank;
uint8_t m_io_select;
uint16_t m_gfx_max_bank = 0;
uint8_t m_ymf_max_bank = 0;
uint8_t m_io_select = 0;
/* video-related */
double m_oldbrt[2];
double m_oldbrt[2]{};
/* devices */
required_device<sh2_device> m_maincpu;

View File

@ -56,9 +56,9 @@ private:
required_device<ym2413_device> m_ym2413;
required_memory_bank m_okibank;
uint8_t m_ym2413_volume;
uint8_t m_overall_volume;
uint8_t m_adpcm_bank;
uint8_t m_ym2413_volume = 0;
uint8_t m_overall_volume = 0;
uint8_t m_adpcm_bank = 0;
static const atari_motion_objects_config s_mob_config;
};

View File

@ -54,7 +54,7 @@ protected:
bool m_lcd_ready = false;
u8 m_lcd_count = 0;
u8 m_lcd_command = 0;
u8 m_lcd_data[0x40];
u8 m_lcd_data[0x40]{};
};
INPUT_PORTS_EXTERN( saitek_stratos );

View File

@ -83,37 +83,37 @@ protected:
optional_region_ptr<u8> m_soundflash1_region;
int m_z80_prg_transfer_pos;
int m_z80_lastbank;
u8 m_sb_coin_latch;
u8 m_ejsakura_input_port;
tilemap_t *m_text_layer;
tilemap_t *m_back_layer;
tilemap_t *m_midl_layer;
tilemap_t *m_fore_layer;
u32 m_video_dma_length;
u32 m_video_dma_address;
u16 m_layer_enable;
u16 m_layer_bank;
u8 m_rf2_layer_bank;
u16 m_scrollram[6];
bool m_rowscroll_enable;
int m_midl_layer_offset;
int m_fore_layer_offset;
int m_text_layer_offset;
int m_fore_layer_d13;
int m_back_layer_d14;
int m_midl_layer_d14;
int m_fore_layer_d14;
int m_z80_prg_transfer_pos = 0;
int m_z80_lastbank = 0;
u8 m_sb_coin_latch = 0;
u8 m_ejsakura_input_port = 0;
tilemap_t *m_text_layer = nullptr;
tilemap_t *m_back_layer = nullptr;
tilemap_t *m_midl_layer = nullptr;
tilemap_t *m_fore_layer = nullptr;
u32 m_video_dma_length = 0;
u32 m_video_dma_address = 0;
u16 m_layer_enable = 0;
u16 m_layer_bank = 0;
u8 m_rf2_layer_bank = 0;
u16 m_scrollram[6]{};
bool m_rowscroll_enable = false;
int m_midl_layer_offset = 0;
int m_fore_layer_offset = 0;
int m_text_layer_offset = 0;
int m_fore_layer_d13 = 0;
int m_back_layer_d14 = 0;
int m_midl_layer_d14 = 0;
int m_fore_layer_d14 = 0;
std::unique_ptr<u32[]> m_tilemap_ram;
std::unique_ptr<u32[]> m_palette_ram;
std::unique_ptr<u32[]> m_sprite_ram;
u32 m_tilemap_ram_size;
u32 m_palette_ram_size;
u32 m_sprite_ram_size;
u32 m_bg_fore_layer_position;
u8 m_alpha_table[0x2000];
int m_sprite_bpp;
u32 m_tilemap_ram_size = 0;
u32 m_palette_ram_size = 0;
u32 m_sprite_ram_size = 0;
u32 m_bg_fore_layer_position = 0;
u8 m_alpha_table[0x2000]{};
int m_sprite_bpp = 0;
void tile_decrypt_key_w(u16 data);
void spi_layer_bank_w(offs_t offset, u16 data, u16 mem_mask = ~0);

View File

@ -110,16 +110,16 @@ private:
void specimx_mem(address_map &map);
std::unique_ptr<uint8_t[]> m_specimx_colorram;
uint8_t m_erik_color_1;
uint8_t m_erik_color_2;
uint8_t m_erik_background;
uint8_t m_specimx_color;
u8 m_porta;
u8 m_portb;
u8 m_portc;
uint8_t m_RR_register;
uint8_t m_RC_register;
u8 m_drive;
uint8_t m_erik_color_1 = 0;
uint8_t m_erik_color_2 = 0;
uint8_t m_erik_background = 0;
uint8_t m_specimx_color = 0;
u8 m_porta = 0;
u8 m_portb = 0;
u8 m_portc = 0;
uint8_t m_RR_register = 0;
uint8_t m_RC_register = 0;
u8 m_drive = 0;
required_device<cpu_device> m_maincpu;
optional_device<i8255_device> m_ppi;
optional_device<fd1793_device> m_fdc;

View File

@ -80,13 +80,13 @@ private:
required_ioport m_dsw;
output_finder<2> m_gear_sel;
uint8_t m_steering[2];
uint8_t m_gear[2];
uint8_t m_game;
uint8_t m_dial[2];
tilemap_t* m_bg_tilemap;
uint8_t m_steering[2]{};
uint8_t m_gear[2]{};
uint8_t m_game = 0;
uint8_t m_dial[2]{};
tilemap_t* m_bg_tilemap = nullptr;
bitmap_ind16 m_helper;
uint8_t m_collision[2];
uint8_t m_collision[2]{};
uint8_t wram_r(offs_t offset);
uint8_t dip_r(offs_t offset);

View File

@ -14,10 +14,10 @@ class srmp2_state : public driver_device
public:
struct iox_t
{
int reset,ff_event,ff_1,protcheck[4],protlatch[4];
uint8_t data;
uint8_t mux;
uint8_t ff;
int reset = 0, ff_event,ff_1 = 0, protcheck[4]{}, protlatch[4]{};
uint8_t data = 0;
uint8_t mux = 0;
uint8_t ff = 0;
};
srmp2_state(const machine_config &mconfig, device_type type, const char *tag) :
@ -41,12 +41,12 @@ private:
required_region_ptr<uint8_t> m_adpcm_rom;
optional_memory_bank m_mainbank;
uint8_t m_color_bank;
uint8_t m_gfx_bank;
uint8_t m_adpcm_bank;
int16_t m_adpcm_data;
uint32_t m_adpcm_sptr;
uint32_t m_adpcm_eptr;
uint8_t m_color_bank = 0;
uint8_t m_gfx_bank = 0;
uint8_t m_adpcm_bank = 0;
int16_t m_adpcm_data = 0;
uint32_t m_adpcm_sptr = 0;
uint32_t m_adpcm_eptr = 0;
iox_t m_iox;
// common

View File

@ -57,21 +57,21 @@ private:
optional_device<atari_slapstic_device> m_slapstic;
optional_memory_bank m_slapstic_bank;
int m_MPA;
int m_BIC;
uint16_t m_dvd_shift;
uint16_t m_quotient_shift;
uint16_t m_divisor;
uint16_t m_dividend;
int m_MPA = 0;
int m_BIC = 0;
uint16_t m_dvd_shift = 0;
uint16_t m_quotient_shift = 0;
uint16_t m_divisor = 0;
uint16_t m_dividend = 0;
std::unique_ptr<uint8_t[]> m_PROM_STR;
std::unique_ptr<uint8_t[]> m_PROM_MAS;
std::unique_ptr<uint8_t[]> m_PROM_AM;
int m_math_run;
emu_timer *m_math_timer;
int16_t m_A;
int16_t m_B;
int16_t m_C;
int32_t m_ACC;
int m_math_run = 0;
emu_timer *m_math_timer = nullptr;
int16_t m_A = 0;
int16_t m_B = 0;
int16_t m_C = 0;
int32_t m_ACC = 0;
void irq_ack_w(uint8_t data);
void starwars_nstore_w(uint8_t data);
DECLARE_WRITE_LINE_MEMBER(recall_w);

View File

@ -126,16 +126,16 @@ private:
void batmanfr_sound_comms_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0);
optional_device<acclaim_rax_device> m_rax;
uint8_t m_port_sel,m_mux_data;
uint8_t m_system_output;
uint8_t m_ioga_mode;
uint8_t m_ioga_portg;
uint16_t m_ioga_count[4];
uint16_t m_serial_tx;
uint8_t m_port_sel,m_mux_data = 0;
uint8_t m_system_output = 0;
uint8_t m_ioga_mode = 0;
uint8_t m_ioga_portg = 0;
uint16_t m_ioga_count[4]{};
uint16_t m_serial_tx = 0;
// protection specific variables and functions
uint32_t m_abus_protenable;
uint32_t m_abus_protkey;
uint32_t m_abus_protenable = 0;
uint32_t m_abus_protkey = 0;
uint32_t decathlt_prot_r(offs_t offset, uint32_t mem_mask = ~0);
void sega5838_map(address_map &map);
@ -144,7 +144,7 @@ private:
int m_protbankval; // debug helper only, doesn't need saving
void decathlt_prot_srcaddr_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0);
uint32_t m_a_bus[4];
uint32_t m_a_bus[4]{};
uint32_t common_prot_r(offs_t offset);
void common_prot_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0);
@ -169,7 +169,7 @@ private:
void pdr1_output_w(uint8_t data);
void pdr2_output_w(uint8_t data);
void stv_select_game(int gameno);
uint8_t m_prev_gamebank_select;
uint8_t m_prev_gamebank_select = 0;
void sound_mem(address_map &map);
void scsp_mem(address_map &map);

View File

@ -195,29 +195,29 @@ private:
std::unique_ptr<uint8_t[]> m_decrypt;
uint8_t m_rombank; // all
uint8_t m_rombank_latch; // sparkman and starfigh
uint8_t m_spritebank; // all
uint8_t m_palettebank; // all brickzn sets
uint8_t m_paletteram_enab; // only brickzn newer sets (no 1.1)
uint8_t m_prot2; // only brickzn newer sets (no 1.1)
uint8_t m_prot2_prev; // only brickzn newer sets (no 1.1)
uint8_t m_rombank = 0; // all
uint8_t m_rombank_latch = 0; // sparkman and starfigh
uint8_t m_spritebank = 0; // all
uint8_t m_palettebank = 0; // all brickzn sets
uint8_t m_paletteram_enab = 0; // only brickzn newer sets (no 1.1)
uint8_t m_prot2 = 0; // only brickzn newer sets (no 1.1)
uint8_t m_prot2_prev = 0; // only brickzn newer sets (no 1.1)
uint8_t m_protection_val; // hardhead and brickzn newer sets (no 1.1)
uint8_t m_nmi_enable; // hardhea2, sparkman and starfigh
uint8_t m_spritebank_latch; // sparkman and starfigh
uint8_t m_write_disable; // only sparkman
uint8_t m_prot_opcode_toggle; // only brickzn newer sets (no 1.1)
uint8_t m_remap_sound; // only brickzn newer sets (no 1.1)
uint8_t m_protection_val = 0; // hardhead and brickzn newer sets (no 1.1)
uint8_t m_nmi_enable = 0; // hardhea2, sparkman and starfigh
uint8_t m_spritebank_latch = 0; // sparkman and starfigh
uint8_t m_write_disable = 0; // only sparkman
uint8_t m_prot_opcode_toggle = 0; // only brickzn newer sets (no 1.1)
uint8_t m_remap_sound = 0; // only brickzn newer sets (no 1.1)
uint8_t m_gfxbank; // only starfigh
uint8_t m_gfxbank = 0; // only starfigh
bool m_has_text; // has text sprites (older games)
bool m_has_text = false; // has text sprites (older games)
// samples
std::unique_ptr<int16_t[]> m_samplebuf;
uint8_t m_sample, m_play;
int m_numsamples;
uint8_t m_sample = 0, m_play = 0;
int m_numsamples = 0;
};
#endif // MAME_INCLUDES_SUNA8_H

View File

@ -176,33 +176,33 @@ private:
required_ioport m_sbug_double_density;
required_ioport m_piaide_flex_boot_cd00;
uint8_t m_pia_counter; // this is the counter on pia porta
uint8_t m_pia_counter = 0; // this is the counter on pia porta
uint8_t m_dmaf_high_address[4]; // dmaf2 or dmaf3 dma extended address reg
uint8_t m_dmaf2_interrupt_enable;
uint8_t m_dmaf_high_address[4]{}; // dmaf2 or dmaf3 dma extended address reg
uint8_t m_dmaf2_interrupt_enable = 0;
uint8_t m_system_type; // flag to indicate hw and rom combination
uint8_t m_fdc_status; // for floppy controller
int m_floppy_motor_on;
emu_timer *m_floppy_motor_timer;
floppy_image_device *m_fdc_floppy; // Current selected floppy.
uint8_t m_fdc_side; // Current floppy side.
uint8_t m_fdc_dden; // Current dden state.
uint8_t m_dmaf3_via_porta;
uint8_t m_dmaf3_via_portb;
uint8_t m_active_interrupt;
uint8_t m_interrupt;
uint8_t m_system_type = 0; // flag to indicate hw and rom combination
uint8_t m_fdc_status = 0; // for floppy controller
int m_floppy_motor_on = 0;
emu_timer *m_floppy_motor_timer = nullptr;
floppy_image_device *m_fdc_floppy = nullptr; // Current selected floppy.
uint8_t m_fdc_side = 0; // Current floppy side.
uint8_t m_fdc_dden = 0; // Current dden state.
uint8_t m_dmaf3_via_porta = 0;
uint8_t m_dmaf3_via_portb = 0;
uint8_t m_active_interrupt = 0;
uint8_t m_interrupt = 0;
address_space *m_banked_space;
address_space *m_banked_space = nullptr;
// TODO: move this in proper device
/* channel_data structure holds info about each 6844 DMA channel */
struct m6844_channel_data
{
int active;
int address;
int counter;
int active = 0;
int address = 0;
int counter = 0;
// Channel control register.
// bit 0: Read / Write mode
// bit 1: Mode control B
@ -217,22 +217,22 @@ private:
// read. Sets IRQ.
// Mode control A,B: 0,0 Mode2; 0,1 Mode 3; 1,0 Mode 0;
// 1,1 Undefined.
uint8_t control;
int start_address;
int start_counter;
uint8_t control = 0;
int start_address = 0;
int start_counter = 0;
};
/* 6844 description */
m6844_channel_data m_m6844_channel[4];
uint8_t m_m6844_priority;
uint8_t m_m6844_priority = 0;
// Interrupt control register.
// Bit 0-3: channel interrupt enable, 1 enabled, 0 masked.
// Bit 4-6: unused
// Bit 7: Read only. Set to 1 when IRQ asserted. Clear when the
// control register associated with the channel that caused the
// interrut is read.
uint8_t m_m6844_interrupt;
uint8_t m_m6844_chain;
uint8_t m_m6844_interrupt = 0;
uint8_t m_m6844_chain = 0;
void m6844_update_interrupt();
void m6844_fdc_dma_transfer(uint8_t channel);
void m6844_hdc_dma_transfer(uint8_t channel);

View File

@ -121,25 +121,25 @@ private:
// video related
std::unique_ptr<u8[]> m_videoram;
void (system1_state::*m_videomode_custom)(u8 data, u8 prevdata);
u8 m_videomode_prev;
u8 m_videomode_prev = 0;
std::unique_ptr<u8[]> m_mix_collide;
u8 m_mix_collide_summary;
u8 m_mix_collide_summary = 0;
std::unique_ptr<u8[]> m_sprite_collide;
u8 m_sprite_collide_summary;
u8 m_sprite_collide_summary = 0;
bitmap_ind16 m_sprite_bitmap;
u8 m_video_mode;
u8 m_videoram_bank;
tilemap_t *m_tilemap_page[8];
u8 m_tilemap_pages;
u8 m_video_mode = 0;
u8 m_videoram_bank = 0;
tilemap_t *m_tilemap_page[8]{};
u8 m_tilemap_pages = 0;
// protection, miscs
u8 m_mute_xor;
u8 m_dakkochn_mux_data;
u8 m_mcu_control;
u8 m_nob_maincpu_latch;
u8 m_nob_mcu_latch;
u8 m_nob_mcu_status;
int m_nobb_inport23_step;
u8 m_mute_xor = 0;
u8 m_dakkochn_mux_data = 0;
u8 m_mcu_control = 0;
u8 m_nob_maincpu_latch = 0;
u8 m_nob_mcu_latch = 0;
u8 m_nob_mcu_status = 0;
int m_nobb_inport23_step = 0;
// video handlers
void common_videomode_w(u8 data);

View File

@ -227,76 +227,76 @@ private:
required_device<screen_device> m_screen;
optional_device<sega_16bit_sprite_device> m_sprites;
uint16_t m_coinctrl;
uint16_t m_coinctrl = 0;
/* game specific */
int m_passht4b_io1_val;
int m_passht4b_io2_val;
int m_passht4b_io3_val;
int m_passht4b_io1_val = 0;
int m_passht4b_io2_val = 0;
int m_passht4b_io3_val = 0;
int m_beautyb_unkx;
int m_beautyb_unkx = 0;
int m_shinobl_kludge; // TODO: this never gets set, causing unreachable code in get_text_tile_info
int m_shinobl_kludge = 0; // TODO: this never gets set, causing unreachable code in get_text_tile_info
int m_eswat_tilebank0;
int m_eswat_tilebank0 = 0;
/* video-related */
tilemap_t *m_background[2];
tilemap_t *m_foreground[2];
tilemap_t *m_text_layer;
tilemap_t *m_bg_tilemaps[2];
tilemap_t *m_text_tilemap;
double m_weights[2][3][6];
tilemap_t *m_background[2]{};
tilemap_t *m_foreground[2]{};
tilemap_t *m_text_layer = nullptr;
tilemap_t *m_bg_tilemaps[2]{};
tilemap_t *m_text_tilemap = nullptr;
double m_weights[2][3][6]{};
int m_spritebank_type;
int m_back_yscroll;
int m_fore_yscroll;
int m_text_yscroll;
int m_spritebank_type = 0;
int m_back_yscroll = 0;
int m_fore_yscroll = 0;
int m_text_yscroll = 0;
int m_bg1_trans; // alien syn + sys18
int m_bg1_trans = 0; // alien syn + sys18
int m_tile_bank[2];
int m_bg_page[2][4];
int m_fg_page[2][4];
int m_tile_bank[2]{};
int m_bg_page[2][4]{};
int m_fg_page[2][4]{};
uint16_t m_datsu_page[4];
uint16_t m_datsu_page[4]{};
int m_old_bg_page[2][4];
int m_old_fg_page[2][4];
int m_old_tile_bank[2];
int m_old_bg_page[2][4]{};
int m_old_fg_page[2][4]{};
int m_old_tile_bank[2]{};
int m_bg_scrollx;
int m_bg_scrolly;
int m_fg_scrollx;
int m_fg_scrolly;
uint16_t m_tilemapselect;
int m_bg_scrollx = 0;
int m_bg_scrolly = 0;
int m_fg_scrollx = 0;
int m_fg_scrolly = 0;
uint16_t m_tilemapselect = 0;
int m_textlayer_lo_min;
int m_textlayer_lo_max;
int m_textlayer_hi_min;
int m_textlayer_hi_max;
int m_textlayer_lo_min = 0;
int m_textlayer_lo_max = 0;
int m_textlayer_hi_min = 0;
int m_textlayer_hi_max = 0;
int m_tilebank_switch;
int m_tilebank_switch = 0;
/* sound-related */
int m_sample_buffer;
int m_sample_select;
int m_sample_buffer = 0;
int m_sample_select = 0;
uint8_t *m_soundbank_ptr; /* Pointer to currently selected portion of ROM */
uint8_t *m_soundbank_ptr = nullptr; /* Pointer to currently selected portion of ROM */
/* sys18 */
uint8_t *m_sound_bank;
uint16_t *m_splittab_bg_x;
uint16_t *m_splittab_bg_y;
uint16_t *m_splittab_fg_x;
uint16_t *m_splittab_fg_y;
int m_sound_info[4*2];
int m_refreshenable;
int m_system18;
uint8_t *m_sound_bank = nullptr;
uint16_t *m_splittab_bg_x = nullptr;
uint16_t *m_splittab_bg_y = nullptr;
uint16_t *m_splittab_fg_x = nullptr;
uint16_t *m_splittab_fg_y = nullptr;
int m_sound_info[4*2]{};
int m_refreshenable = 0;
int m_system18 = 0;
uint8_t *m_decrypted_region; // goldnaxeb1 & bayrouteb1
uint8_t *m_decrypted_region = nullptr; // goldnaxeb1 & bayrouteb1
/* devices */
required_device<cpu_device> m_maincpu;

View File

@ -96,21 +96,21 @@ private:
typedef void (taitosj_state::*copy_layer_func_t)(bitmap_ind16 &,
const rectangle &, int, int *, rectangle *);
uint8_t m_input_port_4_f0;
uint8_t m_kikstart_gears[2];
uint8_t m_input_port_4_f0 = 0;
uint8_t m_kikstart_gears[2]{};
uint8_t m_spacecr_prot_value;
uint8_t m_protection_value;
uint32_t m_address;
uint8_t m_soundlatch_data;
bool m_soundlatch_flag; // 74ls74 1/2 @ GAME BOARD IC42
bool m_sound_semaphore2; // 74ls74 2/2 @ GAME BOARD IC42
uint8_t m_spacecr_prot_value = 0;
uint8_t m_protection_value = 0;
uint32_t m_address = 0;
uint8_t m_soundlatch_data = 0;
bool m_soundlatch_flag = false; // 74ls74 1/2 @ GAME BOARD IC42
bool m_sound_semaphore2 = false; // 74ls74 2/2 @ GAME BOARD IC42
bitmap_ind16 m_layer_bitmap[3];
bitmap_ind16 m_sprite_sprite_collbitmap1;
bitmap_ind16 m_sprite_sprite_collbitmap2;
bitmap_ind16 m_sprite_layer_collbitmap1;
bitmap_ind16 m_sprite_layer_collbitmap2[3];
int m_draw_order[32][4];
int m_draw_order[32][4]{};
void soundlatch_w(uint8_t data);
void sound_semaphore2_w(uint8_t data);
TIMER_CALLBACK_MEMBER(soundlatch_w_cb);

View File

@ -52,7 +52,7 @@ private:
void draw_sprites(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
tilemap_t *m_pant[2];
tilemap_t *m_pant[2]{};
required_device<cpu_device> m_maincpu;
required_device<ls259_device> m_outlatch;

View File

@ -140,25 +140,25 @@ private:
};
// memory state
bool m_rome;
bool m_vire;
bool m_rome = false;
bool m_vire = false;
// video state
uint8_t m_scroll;
uint8_t m_mode;
uint8_t m_palette_val;
uint8_t m_current_pixel;
uint8_t m_scroll = 0;
uint8_t m_mode = 0;
uint8_t m_palette_val = 0;
uint8_t m_current_pixel = 0;
// keyboard state
int m_keylatch;
int m_keylatch = 0;
// printer state
int m_centronics_ack;
int m_centronics_busy;
int m_centronics_perror;
int m_centronics_ack = 0;
int m_centronics_busy = 0;
int m_centronics_perror = 0;
// serial state
bool m_st;
bool m_st = false;
};

View File

@ -74,16 +74,16 @@ private:
required_ioport m_steer;
// Misc
u16 m_cpua_ctrl;
s32 m_ioc220_port;
u16 m_cpua_ctrl = 0;
s32 m_ioc220_port = 0;
// ADPCM
required_region_ptr_array<u8, 2> m_msm_rom;
u16 m_msm_pos[2];
u8 m_msm_reset[2];
u8 m_msm_nibble[2];
u8 m_msm2_vck;
u8 m_msm2_vck2;
u16 m_msm_pos[2]{};
u8 m_msm_reset[2]{};
u8 m_msm_nibble[2]{};
u8 m_msm2_vck = 0;
u8 m_msm2_vck2 = 0;
#ifdef MAME_DEBUG
u8 m_dislayer[5] = { 0, 0, 0, 0, 0 };

View File

@ -116,20 +116,20 @@ private:
uint8_t m_mask = 0U;
uint8_t m_nmi_mask = 0U;
uint8_t m_port_ec = 0U;
bool m_reg_load = 0;
bool m_reg_load = false;
uint8_t m_nmi_data = 0U;
uint8_t m_cassette_data = 0U;
emu_timer *m_cassette_data_timer;
emu_timer *m_cassette_data_timer = nullptr;
double m_old_cassette_val = 0;
uint16_t m_start_address = 0U;
uint8_t m_crtc_reg = 0U;
uint8_t m_size_store = 0U;
bool m_a11_flipflop = 0;
bool m_a11_flipflop = false;
uint16_t m_timeout = 0U;
bool m_wait = 0;
bool m_drq_off = 0;
bool m_intrq_off = 0;
floppy_image_device *m_fdd;
bool m_wait = false;
bool m_drq_off = false;
bool m_intrq_off = false;
floppy_image_device *m_fdd = nullptr;
required_device<cpu_device> m_maincpu;
required_memory_region m_region_maincpu;
required_region_ptr<u8> m_p_chargen;

View File

@ -47,9 +47,9 @@ private:
required_memory_bank m_rombank;
tilemap_t *m_fg_tilemap;
tilemap_t *m_bg_tilemap;
uint8_t m_vram_bank;
tilemap_t *m_fg_tilemap = nullptr;
tilemap_t *m_bg_tilemap = nullptr;
uint8_t m_vram_bank = 0;
void nmi_ack_w(uint8_t data);
void sound_irq_ack_w(uint8_t data);

View File

@ -67,13 +67,13 @@ protected:
required_memory_bank m_mainbank;
/* video-related */
tilemap_t *m_bg_tilemap;
uint8_t m_flipscreen_x;
uint8_t m_flipscreen_y;
tilemap_t *m_bg_tilemap = nullptr;
uint8_t m_flipscreen_x = 0;
uint8_t m_flipscreen_y = 0;
/* misc */
uint8_t m_irq_toggle;
uint8_t m_irq_enable;
uint8_t m_irq_toggle = 0;
uint8_t m_irq_enable = 0;
/* devices */
required_device<cpu_device> m_maincpu;
@ -91,11 +91,11 @@ protected:
void scramble_draw_stars(bitmap_rgb32 &bitmap, const rectangle &cliprect, int maxx);
void scramble_draw_background(bitmap_rgb32 &bitmap, const rectangle &cliprect);
uint8_t m_star_mode;
uint8_t m_star_mode = 0;
rgb_t m_star_color[64];
std::unique_ptr<uint8_t[]> m_stars;
uint8_t m_stars_enabled;
uint8_t m_stars_blink_state;
uint8_t m_stars_enabled = 0;
uint8_t m_stars_blink_state = 0;
};
#endif // MAME_INCLUDES_TUTANKHM_H

View File

@ -68,44 +68,44 @@ public:
/* tape reader registers */
struct tx0_tape_reader_t
{
device_image_interface *fd; /* file descriptor of tape image */
device_image_interface *fd = nullptr; /* file descriptor of tape image */
int motor_on; /* 1-bit reader motor on */
int motor_on = 0; /* 1-bit reader motor on */
int rcl; /* 1-bit reader clutch */
int rc; /* 2-bit reader counter */
int rcl = 0; /* 1-bit reader clutch */
int rc = 0; /* 2-bit reader counter */
emu_timer *timer; /* timer to simulate reader timing */
emu_timer *timer = nullptr; /* timer to simulate reader timing */
};
/* tape puncher registers */
struct tape_puncher_t
{
device_image_interface *fd; /* file descriptor of tape image */
device_image_interface *fd = nullptr; /* file descriptor of tape image */
emu_timer *timer; /* timer to generate completion pulses */
emu_timer *timer = nullptr; /* timer to generate completion pulses */
};
/* typewriter registers */
struct tx0_typewriter_t
{
device_image_interface *fd; /* file descriptor of output image */
device_image_interface *fd = nullptr; /* file descriptor of output image */
emu_timer *prt_timer;/* timer to generate completion pulses */
emu_timer *prt_timer = nullptr;/* timer to generate completion pulses */
};
/* magnetic tape unit registers */
struct magtape_t
{
device_image_interface *img; /* image descriptor */
device_image_interface *img = nullptr; /* image descriptor */
state_t state;
int command;
int binary_flag;
int command = 0;
int binary_flag = 0;
union
{
@ -122,14 +122,14 @@ public:
} write;
} u;
int sel_pending;
int cpy_pending;
int sel_pending = 0;
int cpy_pending = 0;
irg_pos_t irg_pos; /* position relative to inter-record gap */
int long_parity;
int long_parity = 0;
emu_timer *timer; /* timer to simulate reader timing */
emu_timer *timer = nullptr; /* timer to simulate reader timing */
};
@ -160,15 +160,15 @@ public:
void schedule_unselect();
protected:
int m_old_typewriter_keys[4];
int m_old_control_keys;
int m_old_tsr_keys;
int m_tsr_index;
int m_typewriter_color;
int m_old_typewriter_keys[4]{};
int m_old_control_keys = 0;
int m_old_tsr_keys = 0;
int m_tsr_index = 0;
int m_typewriter_color = 0;
bitmap_ind16 m_panel_bitmap;
bitmap_ind16 m_typewriter_bitmap;
int m_pos;
int m_case_shift;
int m_pos = 0;
int m_case_shift = 0;
virtual void machine_start() override;
virtual void machine_reset() override;
virtual void video_start() override;

View File

@ -48,12 +48,12 @@ protected:
private:
struct uf_tempsprite
{
u8 gfx;
u32 code,color;
bool flipx,flipy;
int x,y;
int zoomx,zoomy;
u32 primask;
u8 gfx = 0;
u32 code = 0, color = 0;
bool flipx = 0, flipy = 0;
int x = 0, y = 0;
int zoomx = 0, zoomy = 0;
u32 primask = 0;
};
required_device<cpu_device> m_maincpu;
@ -64,10 +64,10 @@ private:
required_device<eeprom_serial_93cxx_device> m_eeprom;
optional_shared_ptr<u32> m_ram;
optional_shared_ptr<u16> m_shared_ram;
u16 m_port_sel;
int m_frame_counter;
u16 m_port_sel = 0;
int m_frame_counter = 0;
std::unique_ptr<uf_tempsprite[]> m_spritelist;
u16 m_rotate_ctrl[8];
u16 m_rotate_ctrl[8]{};
#ifdef MAME_DEBUG
u8 m_dislayer[6] = { 0, 0, 0, 0, 0, 0 };
#endif