Fixes cuebrckj0102u5gre using a horrible hack. konamiic.c calls the tilemap callback for reading the ROM!?!? This is detected by reading the current PC and the proper value is returned.

This commit is contained in:
Zsolt Vasvari 2008-01-12 04:38:47 +00:00
parent c590cd8a56
commit d6166834f2

View File

@ -62,6 +62,13 @@ static void mia_tile_callback(int layer,int bank,int *code,int *color,int *flags
}
static void cuebrick_tile_callback(int layer,int bank,int *code,int *color,int *flags,int *priority)
{
/* HACK! - since konamiic.c calls here with layer=0 when reading the ROM, detect this
and return the proper value in 'code' */
if ((cpu_getactivecpu() == 0) && ((activecpu_get_pc() & 0xffff0) == 0x002630))
*code |= ((*color & 0xf) << 8);
/* normal access via the tilemap code */
else
{
if (layer == 0)
{
@ -74,6 +81,7 @@ static void cuebrick_tile_callback(int layer,int bank,int *code,int *color,int *
*color = layer_colorbase[layer] + ((*color & 0xe0) >> 5);
}
}
}
static void tmnt_tile_callback(int layer,int bank,int *code,int *color,int *flags,int *priority)
{