public void handler(int offset, int data) {
            /* I think this is more than just a trigger */
            cpu_cause_interrupt(1, 0xff);
        }
    };
    /*TODO*///
/*TODO*///static struct MemoryReadAddress detatwin_readmem[] =
/*TODO*///{
/*TODO*///	{ 0x000000, 0x07ffff, MRA_ROM },
/*TODO*///	{ 0x180000, 0x183fff, K052109_word_r },
/*TODO*///	{ 0x204000, 0x207fff, MRA_BANK1 },	/* main RAM */
/*TODO*///	{ 0x300000, 0x303fff, K053245_scattered_word_r },
/*TODO*///	{ 0x400000, 0x400fff, paletteram_word_r },
/*TODO*///	{ 0x500000, 0x50003f, K054000_halfword_r },
/*TODO*///	{ 0x680000, 0x68001f, K053244_word_noA1_r },
/*TODO*///	{ 0x700000, 0x700001, input_port_0_r },
/*TODO*///	{ 0x700002, 0x700003, input_port_1_r },
/*TODO*///	{ 0x700004, 0x700005, detatwin_coin_r },
/*TODO*///	{ 0x700006, 0x700007, detatwin_eeprom_r },
/*TODO*///	{ 0x780600, 0x780603, detatwin_sound_r },	/* K053260 */
/*TODO*///	{ -1 }	/* end of table */
/*TODO*///};
/*TODO*///
/*TODO*///static struct MemoryWriteAddress detatwin_writemem[] =
/*TODO*///{
/*TODO*///	{ 0x000000, 0x07ffff, MWA_ROM },
/*TODO*///	{ 0x180000, 0x183fff, K052109_word_w },
/*TODO*///	{ 0x204000, 0x207fff, MWA_BANK1 },	/* main RAM */
/*TODO*///	{ 0x300000, 0x303fff, K053245_scattered_word_w, &spriteram },
/*TODO*///	{ 0x500000, 0x50003f, K054000_halfword_w },
/*TODO*///	{ 0x400000, 0x400fff, paletteram_xBBBBBGGGGGRRRRR_word_w, &paletteram },
/*TODO*///	{ 0x680000, 0x68001f, K053244_word_noA1_w },
/*TODO*///	{ 0x700200, 0x700201, ssriders_eeprom_w },
/*TODO*///	{ 0x700400, 0x700401, watchdog_reset_w },
/*TODO*///	{ 0x700300, 0x700301, detatwin_700300_w },
/*TODO*///	{ 0x780600, 0x780601, K053260_WriteReg },
/*TODO*///	{ 0x780604, 0x780605, ssriders_soundkludge_w },
/*TODO*///	{ 0x780700, 0x78071f, K053251_halfword_w },
/*TODO*///	{ -1 }	/* end of table */
/*TODO*///};
/*TODO*///
/*TODO*///
/*TODO*///static int ball(int offset)
/*TODO*///{
/*TODO*///	return 0x11;
/*TODO*///}
/*TODO*///
/*TODO*///static struct MemoryReadAddress glfgreat_readmem[] =
/*TODO*///{
/*TODO*///	{ 0x000000, 0x03ffff, MRA_ROM },
/*TODO*///	{ 0x100000, 0x103fff, MRA_BANK1 },	/* main RAM */
/*TODO*///	{ 0x104000, 0x107fff, K053245_scattered_word_r },
/*TODO*///	{ 0x108000, 0x108fff, paletteram_word_r },
/*TODO*///	{ 0x10c000, 0x10cfff, MRA_BANK2 },	/* 053936? */
/*TODO*///	{ 0x114000, 0x11401f, K053244_halfword_r },
/*TODO*///	{ 0x120000, 0x120001, input_port_0_r },
/*TODO*///	{ 0x120002, 0x120003, input_port_1_r },
/*TODO*///	{ 0x120004, 0x120005, input_port_3_r },
/*TODO*///	{ 0x120006, 0x120007, input_port_2_r },
/*TODO*///	{ 0x121000, 0x121001, ball },	/* protection? returning 0, every shot is a "water" */
/*TODO*///	{ 0x125000, 0x125003, glfgreat_sound_r },	/* K053260 */
/*TODO*///	{ 0x200000, 0x207fff, K052109_word_noA12_r },
/*TODO*///	{ -1 }	/* end of table */
/*TODO*///};
/*TODO*///
/*TODO*///static struct MemoryWriteAddress glfgreat_writemem[] =
/*TODO*///{
/*TODO*///	{ 0x000000, 0x03ffff, MWA_ROM },
/*TODO*///	{ 0x100000, 0x103fff, MWA_BANK1 },	/* main RAM */
/*TODO*///	{ 0x104000, 0x107fff, K053245_scattered_word_w, &spriteram },
/*TODO*///	{ 0x108000, 0x108fff, paletteram_xBBBBBGGGGGRRRRR_word_w, &paletteram },
/*TODO*///	{ 0x10c000, 0x10cfff, MWA_BANK2 },	/* 053936? */
/*TODO*///	{ 0x110000, 0x11001f, K053244_word_noA1_w },	/* duplicate! */
/*TODO*///	{ 0x114000, 0x11401f, K053244_halfword_w },		/* duplicate! */
/*TODO*///	{ 0x118000, 0x11801f, MWA_NOP },	/* 053936 control? */
/*TODO*///	{ 0x11c000, 0x11c01f, K053251_halfword_swap_w },
/*TODO*///	{ 0x122000, 0x122001, glfgreat_122000_w },
/*TODO*///	{ 0x124000, 0x124001, watchdog_reset_w },
/*TODO*///	{ 0x125000, 0x125003, glfgreat_sound_w },	/* K053260 */
/*TODO*///	{ 0x200000, 0x207fff, K052109_word_noA12_w },
/*TODO*///	{ -1 }	/* end of table */
/*TODO*///};
/*TODO*///
/*TODO*///
/*TODO*///static struct MemoryReadAddress tmnt2_readmem[] =
/*TODO*///{
/*TODO*///	{ 0x000000, 0x07ffff, MRA_ROM },
/*TODO*///	{ 0x104000, 0x107fff, MRA_BANK1 },	/* main RAM */
/*TODO*///	{ 0x140000, 0x140fff, paletteram_word_r },
/*TODO*///	{ 0x180000, 0x183fff, K053245_scattered_word_r },
/*TODO*///	{ 0x1c0000, 0x1c0001, input_port_0_r },
/*TODO*///	{ 0x1c0002, 0x1c0003, input_port_1_r },
/*TODO*///	{ 0x1c0004, 0x1c0005, input_port_4_r },
/*TODO*///	{ 0x1c0006, 0x1c0007, input_port_5_r },
/*TODO*///	{ 0x1c0100, 0x1c0101, input_port_2_r },
/*TODO*///	{ 0x1c0102, 0x1c0103, ssriders_eeprom_r },
/*TODO*///	{ 0x1c0400, 0x1c0401, watchdog_reset_r },
/*TODO*///	{ 0x1c0500, 0x1c057f, MRA_BANK3 },	/* TMNT2 only (1J); unknown */
/*TODO*/////	{ 0x1c0800, 0x1c0801, ssriders_kludge },	/* protection device */
/*TODO*///	{ 0x5a0000, 0x5a001f, K053244_word_noA1_r },
/*TODO*///	{ 0x5c0600, 0x5c0603, tmnt2_sound_r },	/* K053260 */
/*TODO*///	{ 0x600000, 0x603fff, K052109_word_r },
/*TODO*///	{ -1 }	/* end of table */
/*TODO*///};
/*TODO*///
/*TODO*///static unsigned char *tmnt2_1c0800,*sunset_104000;
/*TODO*///
/*TODO*///void tmnt2_1c0800_w( int offset, int data )
/*TODO*///{
/*TODO*///    COMBINE_WORD_MEM( &tmnt2_1c0800[offset], data );
/*TODO*///    if ( offset == 0x0010 && ( ( READ_WORD( &tmnt2_1c0800[0x10] ) & 0xff00 ) == 0x8200 ) )
/*TODO*///	{
/*TODO*///		unsigned int CellSrc;
/*TODO*///		unsigned int CellVar;
/*TODO*///		unsigned char *src;
/*TODO*///		int dst;
/*TODO*///		int x,y;
/*TODO*///
/*TODO*///		CellVar = ( READ_WORD( &tmnt2_1c0800[0x08] ) | ( READ_WORD( &tmnt2_1c0800[0x0A] ) << 16 ) );
/*TODO*///		dst = ( READ_WORD( &tmnt2_1c0800[0x04] ) | ( READ_WORD( &tmnt2_1c0800[0x06] ) << 16 ) );
/*TODO*///		CellSrc = ( READ_WORD( &tmnt2_1c0800[0x00] ) | ( READ_WORD( &tmnt2_1c0800[0x02] ) << 16 ) );
/*TODO*/////        if ( CellDest >= 0x180000 && CellDest < 0x183fe0 ) {
/*TODO*///        CellVar -= 0x104000;
/*TODO*///		src = &memory_region(REGION_CPU1)[CellSrc];
/*TODO*///
/*TODO*///		cpu_writemem24_word(dst+0x00,0x8000 | ((READ_WORD(src+2) & 0xfc00) >> 2));	/* size, flip xy */
/*TODO*///        cpu_writemem24_word(dst+0x04,READ_WORD(src+0));	/* code */
/*TODO*///        cpu_writemem24_word(dst+0x18,(READ_WORD(src+2) & 0x3ff) ^		/* color, mirror, priority */
/*TODO*///				(READ_WORD( &sunset_104000[CellVar + 0x00] ) & 0x0060));
/*TODO*///
/*TODO*///		/* base color modifier */
/*TODO*///		/* TODO: this is wrong, e.g. it breaks the explosions when you kill an */
/*TODO*///		/* enemy, or surfs in the sewer level (must be blue for all enemies). */
/*TODO*///		/* It fixes the enemies, though, they are not all purple when you throw them around. */
/*TODO*///		/* Also, the bosses don't blink when they are about to die - don't know */
/*TODO*///		/* if this is correct or not. */
/*TODO*/////		if (READ_WORD( &sunset_104000[CellVar + 0x2a] ) & 0x001f)
/*TODO*/////			cpu_writemem24_word(dst+0x18,(cpu_readmem24_word(dst+0x18) & 0xffe0) |
/*TODO*/////					(READ_WORD( &sunset_104000[CellVar + 0x2a] ) & 0x001f));
/*TODO*///
/*TODO*///		x = READ_WORD(src+4);
/*TODO*///		if (READ_WORD( &sunset_104000[CellVar + 0x00] ) & 0x4000)
/*TODO*///		{
/*TODO*///			/* flip x */
/*TODO*///			cpu_writemem24_word(dst+0x00,cpu_readmem24_word(dst+0x00) ^ 0x1000);
/*TODO*///			x = -x;
/*TODO*///		}
/*TODO*///		x += READ_WORD( &sunset_104000[CellVar + 0x0C] );
/*TODO*///		cpu_writemem24_word(dst+0x0c,x);
/*TODO*///		y = READ_WORD(src+6);
/*TODO*///		y += READ_WORD( &sunset_104000[CellVar + 0x0E] );
/*TODO*///		/* don't do second offset for shadows */
/*TODO*///		if ((READ_WORD(&tmnt2_1c0800[0x10]) & 0x00ff) != 0x01)
/*TODO*///			y += READ_WORD( &sunset_104000[CellVar + 0x10] );
/*TODO*///		cpu_writemem24_word(dst+0x08,y);
/*TODO*///#if 0
/*TODO*///if (errorlog) fprintf(errorlog,"copy command %04x sprite %08x data %08x: %04x%04x %04x%04x  modifiers %08x:%04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x %04x%04x\n",
/*TODO*///	READ_WORD( &tmnt2_1c0800[0x10] ),
/*TODO*///	CellDest,CellSrc,
/*TODO*///	READ_WORD(src+0),READ_WORD(src+2),READ_WORD(src+4),READ_WORD(src+6),
/*TODO*///	CellVar,
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x00]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x02]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x04]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x06]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x08]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x0a]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x0c]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x0e]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x10]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x12]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x14]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x16]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x18]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x1a]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x1c]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x1e]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x20]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x22]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x24]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x26]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x28]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x2a]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x2c]),
/*TODO*///	READ_WORD( &sunset_104000[CellVar + 0x2e])
/*TODO*///	);
/*TODO*///#endif
/*TODO*/////        }
/*TODO*///    }
/*TODO*///}
/*TODO*///
/*TODO*///static struct MemoryWriteAddress tmnt2_writemem[] =
/*TODO*///{
/*TODO*///	{ 0x000000, 0x07ffff, MWA_ROM },
/*TODO*///	{ 0x104000, 0x107fff, MWA_BANK1, &sunset_104000 },	/* main RAM */
/*TODO*///	{ 0x140000, 0x140fff, paletteram_xBBBBBGGGGGRRRRR_word_w, &paletteram },
/*TODO*///	{ 0x180000, 0x183fff, K053245_scattered_word_w, &spriteram },
/*TODO*///	{ 0x1c0200, 0x1c0201, ssriders_eeprom_w },
/*TODO*///	{ 0x1c0300, 0x1c0301, ssriders_1c0300_w },
/*TODO*///	{ 0x1c0400, 0x1c0401, watchdog_reset_w },
/*TODO*///	{ 0x1c0500, 0x1c057f, MWA_BANK3 },	/* unknown: TMNT2 only (1J) */
/*TODO*///	{ 0x1c0800, 0x1c081f, tmnt2_1c0800_w, &tmnt2_1c0800 },	/* protection device */
/*TODO*///	{ 0x5a0000, 0x5a001f, K053244_word_noA1_w },
/*TODO*///	{ 0x5c0600, 0x5c0601, K053260_WriteReg },
/*TODO*///	{ 0x5c0604, 0x5c0605, ssriders_soundkludge_w },
/*TODO*///	{ 0x5c0700, 0x5c071f, K053251_halfword_w },
/*TODO*///	{ 0x600000, 0x603fff, K052109_word_w },
/*TODO*///	{ -1 }