Previous 199869 Revisions Next

r23948 Wednesday 26th June, 2013 at 01:39:12 UTC by David Haywood
tcn100scn - let's actually initialize things to 0. 

Having uninitialized stuff anywhere is bad.  Old 'C' devices would clear everything automatically, new 'C++' ones will not, you must do it manually.

This appears to help with the missing layers issue.
[src/mame/video]taitoic.c

trunk/src/mame/video/taitoic.c
r23947r23948
18121812tc0100scn_device::tc0100scn_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock)
18131813   : device_t(mconfig, TC0100SCN, "Taito TC0100SCN", tag, owner, clock, "tc0100scn", __FILE__)
18141814{
1815   // device stuff
1816   for (int i=0;i<8;i++)
1817      m_ctrl[i] = 0;
1818
1819   m_ram = 0;
1820   m_bg_ram = 0;
1821   m_fg_ram = 0;
1822   m_tx_ram = 0;
1823   m_char_ram = 0;
1824   m_bgscroll_ram = 0;
1825   m_fgscroll_ram = 0;
1826   m_colscroll_ram = 0;
1827
1828   m_bgscrollx = 0;   
1829   m_bgscrolly = 0;
1830   m_fgscrollx = 0;
1831   m_fgscrolly = 0;
1832
1833   m_bg_col_mult = 0;
1834   m_bg_tilemask = 0;
1835   m_tx_col_mult = 0;
1836   m_gfxbank = 0;
1837   m_colbank = 0;
1838   m_bg0_colbank = 0;
1839   m_bg1_colbank = 0;
1840   m_tx_colbank = 0;
1841   m_dblwidth = 0;
1842
1843   //m_tilemap[3][2];
1844   //m_cliprect;
1845
1846   m_screen = 0;
1847
1848   // interface stuff
1849   m_screen_tag = 0;
1850
1851   m_gfxnum = 0;
1852   m_txnum = 0;
1853
1854   m_x_offset = 0;
1855   m_y_offset = 0;
1856   m_flip_xoffs = 0;
1857   m_flip_yoffs = 0;
1858   m_flip_text_xoffs = 0;
1859   m_flip_text_yoffs = 0;
1860
1861   m_multiscrn_xoffs = 0;
1862   m_multiscrn_hack = 0;
1863
18151864}
18161865
18171866//-------------------------------------------------

Previous 199869 Revisions Next


© 1997-2024 The MAME Team