public static WriteHandlerPtr bankedram_w = new WriteHandlerPtr() { public void handler(int offset, int data)
	{
		if ((videobank & 0x02)!=0)
		{
			if ((videobank & 0x04)!=0)
				paletteram_xBBBBBGGGGGRRRRR_swap_w.handler(offset + 0x0800,data);
			else
				paletteram_xBBBBBGGGGGRRRRR_swap_w.handler(offset,data);
		}
		else if ((videobank & 0x01)!=0)
			K053245_w.handler(offset,data);
		else
			ram.write(offset,data);
	} }